Advanced-Equipment icon indicating copy to clipboard operation
Advanced-Equipment copied to clipboard

Eden attribute for PowerOn on mission start

Open GermanHydrogen opened this issue 1 year ago • 3 comments

Added an eden attribute to power devices to power them on, on mission start.

GermanHydrogen avatar Mar 14 '23 08:03 GermanHydrogen

Perhaps we should add some logic that guarantees that all power producing devices are turned on before power consuming devices are turned on.

Also we should check that the devices are turned on after all Eden Editor power connections are established.

At this point an init diagram could be useful, to keep track of what happens when on startup (Init Devices, Add Connections, Turn on Generators, Turn on Consumers)

My simple setup was a generator, a quad lamp and a power connection defined in Eden Editor. The sound played, but the generator was off. If the connection was not present on start, the generator was on. The lamp was always off.

y0014984 avatar Mar 14 '23 13:03 y0014984

The previously described bug appeared in singleplayer. In hosted multiplayer it worked and also the lamp was on.

Despite that we should be able to guarantee the order of execution.

y0014984 avatar Mar 14 '23 13:03 y0014984

If the lamp is created in Editor before the generator, the lamp will be turned on before the generator is turned on. At this moment there is no power source and the lamp stays off.

y0014984 avatar Mar 14 '23 13:03 y0014984