Resource Spawner Overhaul

by orzelek

Makes resources more sparse than base game. You will need to use trains much earlier to get resources. Game will be more difficult especially with higher enemy settings.

Tweaks
5 days ago
0.14 - 2.1
153K
Environment

g disable crude oil

13 days ago

hello, ty for your work and great mod, always play with it and enjoy very much :)

on recent save tho i cant disable crude oil and on previous saves i could do that but unless something changed i really forgot how i did it (so far tried - changing probability to 0 in vanila.lua then change everything to 0 and then even delete all stuff related to crude oil)

would be cool if you point me to right direction with it, on PY there is none crude oil and on map im gonna play there spawn a lot of it ( milions richness and 10+ holes of it - each) would be cool if something else spawned instead
ty in advance

13 days ago

Did you remove the crude by hand or PY was disabling it by itself?
Removing crude entry from vanilla.lua should remove it's generation on new chunks - it won't remove already generated patches.

13 days ago

it is disabled with Py cos there is diffrent stuff in ground that you process and eventually get to crude oil, generally just getting it from ground is big cheat

i did remove both crude oil entry and still got it generated far away

cargo ships generate crude oil too but should be only on sea , mayby something messing up from there, gonna try generate map once more much bigger this time but pretty sure it was too far away laready to be spawned before i changed this or even better gonna try on new map

13 days ago

I checked the files and I don't see PY disabling crude in any way. And AFAIK cargo ships oil is a differently named resource so it shouldn't interfere. Do youi know which part of PY disables crude normally?

13 days ago

in your files there are pyconfigs and there is setting for "bitumen seep" and thats stuff that spawn instead crude oil in PY , i got no clue how he disables it tho

on new game all working as it should, there in no crude oil and there is bitumen seep

but on my save there is both and really far far away in places it could not generate before - i use 4096 in that command that generate map and my explored area is tiny in mid and then in corners a lot of crude oil, like really lot :( any idea hows that possible ?

13 days ago
(updated 13 days ago)

So it's a map you had before and it started to generate crude oil?
Can you try to run /rso-regenerate and see what it does?
Also if you could set debug_enabled and config_log_enabled to true in config.lua and then paste the resulting log (it will be in script_output in subfolder) to pastebin or similar service.
It will have info what configuration was detected on the map.

13 days ago

just generate 8000 map and still crude oil far away ...

gonna do that debug now then

13 days ago

i did as you ask
ores are diffrent and in little diffrent spot and there is still crude oil
but in those logs is only this -
46:57:18: Building config for minime_dummy_dungeon index 2
46:57:18: Starting area 0 for surface 2

nothing else , tried start game and load save and run this /rso-regenerate twice

13 days ago
(updated 13 days ago)

i was trying to get you that log but seems only one i got is after starting new game https://pastebin.com/r4zUMUKx

other than that when i use rso-regenerate on save there is something wierd cos all ores moves a bit but not crude oil , even in yarm crude oil exist while other ores and stuff are not in yarm
i did drive to that crude oil and did exist in real too, in that little window on right that shows what mod and in what order changes things there was rso there 2nd last , last was alien biomes

ill try all this again tommorow

13 days ago
(updated 13 days ago)

after that log was so short and mention some unrelated mod i gave it some more tries without it and it is it - no idea why and how but that mod https://mods.factorio.com/mod/minime/discussion brings this bug even as it isnt mod that generate ore or something
tested many times, with it - lots crude oil on map spawn, without it not even one
and to make it even more wierd it happen only on my save but when start new game there is no crude oil
if thats not enough wierd there is more, when i get debug stuff enabled and try start new game now it wont start and bring me this instead

The mod miniMAXIme: Character scaler and selector (2.0.19) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event minime::on_init()
Error when running interface function RSO.ignoreSurface: rso-mod/control.lua:2160: attempt to index field '?' (a nil value)
stack traceback:
rso-mod/control.lua:2160: in function <rso-mod/control.lua:2155>
stack traceback:
[C]: in function 'call'
Pi-C_lib/common.lua:384: in function 'remote_call'
minime/scripts/surfaces.lua:449: in function 'blacklist_surface'
minime/scripts/surfaces.lua:124: in function 'create_surface'
minime/control.lua:275: in function 'init'
minime/control.lua:383: in function <minime/control.lua:379>

gonna post this on that mod page too

13 days ago

That error is caused by mistake in debug code - it assumes that player exists and it seems that there is no player when this init runs.
You can change game.players[1].print in that line to game.print and it should get rid of the error.
I think that you would need to provide the save through some sharing service so that I could take a look and try to log some things in game to check why crude is being spawned.
One more thing - when you are using command that reveals map or when you explore with debug enabled there should be a log file written.
You can take a look here: https://wiki.factorio.com/Application_directory#User_data_directory to find out where that folder is located for you.

12 days ago

https://www.mediafire.com/file/qc0cbg5g7lbuf5j/4.zip/file

there is save if you wanna look, but tbh for me its enough to know that disabling that other mod will stop crude oil from spawn so i can play

12 days ago

Good to know that you can easily unblock yourself. I will grab the save to take a look at some point to figure out what is actually wrong/why that particular mod breaks it.

6 days ago
(updated 6 days ago)

@orzelek: My mod (minime) creates surfaces to store previews of the available characters (one surface for each character prototype) when the game is initialized or the configuration has changed. Directly after creating a surface, my mod will call your remote function. This will work as expected when a new surface is created in response to on_configuration_changed. But when you start a new game, the remote function is called before the first player has joined the game, so game.players[1].print() will fail.

Changing line 2160 of your control.lua to

if debug_enabled and game.players[1] then

should fix the crash.

6 days ago
(updated 6 days ago)

Thanks for the note - I am aware of that and might fix it at some point but it's under debug flag so only for special occasions like tricky bugs.
Edit:
I also meant to ask - are you aware how presence of your mod can somehow enable generation of crude oil over the RSO resource disabling?

New response