Page 1 of 1

Add surface_conditions on items - desintegrate if not met on surface change

Posted: Fri Aug 15, 2025 11:36 am
by snouz
Hi,

Feature
My suggestion is to add surface_conditions on items, structured the same as recipes or entities, but the effect would be that the item gets destroyed when changing surface.
Another possibility, maybe more optimized, would be to add "forbidden_items" in the planet properties. That way, the check doesn't even happen if the new surface doesn't have that property. This would even be easier for modders, who don't have to change vanilla items properties (potentially breaking compatibility)

Use case examples
- ice melting over a given temperature
- organic material being poisoned
- electric stuff being fried...

Why?
This would allow modders to put restrictions on imports, and thus allow for more restrictive challenges. It solves the fact that at a certain point, every additional planet becomes somewhat trivial when you can import everything.

Re: Add surface_conditions on items - desintegrate if not met on surface change

Posted: Fri Aug 15, 2025 11:51 am
by Rseding91
This is simply not something the engine supports. Items have no idea when they are moved between surfaces and some items aren’t even on any surface.

Re: Add surface_conditions on items - desintegrate if not met on surface change

Posted: Sun Aug 17, 2025 10:01 pm
by meifray
snouz wrote: Fri Aug 15, 2025 11:36 am Hi,

Feature
My suggestion is to add surface_conditions on items, structured the same as recipes or entities, but the effect would be that the item gets destroyed when changing surface.
Another possibility, maybe more optimized, would be to add "forbidden_items" in the planet properties. That way, the check doesn't even happen if the new surface doesn't have that property. This would even be easier for modders, who don't have to change vanilla items properties (potentially breaking compatibility)

Use case examples
- ice melting over a given temperature
- organic material being poisoned
- electric stuff being fried...

Why?
This would allow modders to put restrictions on imports, and thus allow for more restrictive challenges. It solves the fact that at a certain point, every additional planet becomes somewhat trivial when you can import everything.
I think you can make it a spoilable item and turn into a temporary item with a spoil trigger, them use event to catch where it happen and turn it into correct item

Re: Add surface_conditions on items - desintegrate if not met on surface change

Posted: Mon Aug 18, 2025 3:56 pm
by Quorken
For items produced on planets, you could also set the item's weight so high that it cannot be sent into space, which would for at least some cases (esp. where the item can only be produced on one planet).