[2.0.15] swaping oretype under a placed miner result into empty miner

Bugs that are actually features.
Blacky007
Fast Inserter
Fast Inserter
Posts: 180
Joined: Fri Dec 29, 2017 8:05 pm
Contact:

[2.0.15] swaping oretype under a placed miner result into empty miner

Post by Blacky007 »

I use the Mod "ore-swapper 0.2.0" in a free play for a huge max sience base
I placed many miner on an stone field - then I used the mod to switch from stone to coal - (maybe if the miner has no power during the switching makes a difference)
after this swapping all miner are in empty orefield mode?
I expect that the miner start to mine the coal.

Greetings Blacky
My color birthday was May 2nd 2020 - Thank you Enchroma
Honktown
Smart Inserter
Smart Inserter
Posts: 1041
Joined: Thu Oct 03, 2019 7:10 am
Contact:

Re: [2.0.15] swaping oretype under a placed miner result into empty miner

Post by Honktown »

In the mod, the author can look for miners (though they have different reach), and do "update_connections()" https://lua-api.factorio.com/latest/cla ... onnections

Quoting:

Code: Select all

update_connections()

Reconnect loader, beacon, cliff and mining drill connections to entities that might have been teleported out or in by the script. The game doesn't do this automatically as we don't want to lose performance by checking this in normal games.
I have mods! I guess!
Link
User avatar
boskid
Factorio Staff
Factorio Staff
Posts: 2972
Joined: Thu Dec 14, 2017 6:56 pm
Contact:

Re: [2.0.15] swaping oretype under a placed miner result into empty miner

Post by boskid »

Not a bug. As mentioned by Honktown, use LuaEntity::update_connections() on a drill to request a rescan of resources in range.
Post Reply

Return to “Not a bug”