Geothermal?

Started by Slowtapus, July 18, 2015, 08:30:21 PM

Previous topic - Next topic

Slowtapus

Hey all. So I'm having a weird issue. When making a different type of geothermal, using the whole PlaceWorker_OnSteamGeyser, etc. it will always say the space is already occupied. Thus refusing to let you place it anywhere. This includes if I simply make a duplicate of the vanilla Geothermal and rename it.

This makes me think that there's somewhere in the code that is telling everything that it's fine that it's already occupied space (because it will be despawning the geyser when it places anyway) for the vanilla Geothermal but not for modded ones. Does anyone know where this might be or what the problem actually is?

1000101

Alpha 11b changed how steam geysers/geothermals check their restrictions.

PlaceWorker_OnSteamGeyser is never actually is called because the engine is now hard-coded to check for the geothermal plant earlier than when it checks the place worker restrictions.

However, Community Core Library has a place worker which allows proper placement on steam geysers.
(2*b)||!(2*b) - That is the question.
There are 10 kinds of people in this world - those that understand binary and those that don't.

Powered By

Slowtapus

Quote from: 1000101 on July 18, 2015, 08:46:20 PM
Alpha 11b changed how steam geysers/geothermals check their restrictions.

PlaceWorker_OnSteamGeyser is never actually is called because the engine is now hard-coded to check for the geothermal plant earlier than when it checks the place worker restrictions.

However, Community Core Library has a place worker which allows proper placement on steam geysers.

What namespace/class is that check under? Thanks a bunch by the way!

1000101

#3
See the geothermal plant in the CCL download.  It will show how to use it.


/Mods/Community Core Library/Defs/ThingDefs/Buildings_Power.xml


In the game engine, it gets checked in:
Verse.GenSpawn.CanPlaceBlueprintOver(BuildableDef newDef, ThingDef oldDef)
(2*b)||!(2*b) - That is the question.
There are 10 kinds of people in this world - those that understand binary and those that don't.

Powered By

Tynan

Quote from: 1000101 on July 18, 2015, 08:46:20 PM
Alpha 11b changed how steam geysers/geothermals check their restrictions.

PlaceWorker_OnSteamGeyser is never actually is called because the engine is now hard-coded to check for the geothermal plant earlier than when it checks the place worker restrictions.

However, Community Core Library has a place worker which allows proper placement on steam geysers.

Really? I need to check on that!
Tynan Sylvester - @TynanSylvester - Tynan's Blog