This is going to be lengthy because I've gotten myself into a corner with a few things for an upcoming mod... I'll try and keep this organized, brief, and terse.
I have the following items already set in place.
- a container EFTH_PZ1_Container, with this script. Currently this is intended to open everything up and set the light green when food is placed, but for now I'm allowing for any placed item.
Scriptname EFTH_Puzzle01Control extends ObjectReference ObjectReference property DoorController auto ObjectReference property LightController auto Event OnItemAdded(Form akBaseItem, int aiItemCount, ObjectReference akItemReference, ObjectReference akSourceContainer) if (aiItemCount > 0) DoorController.activate(game.getplayer()) LightController.activate(game.getplayer()) endIf endEvent
- marker EFTH_PZ1_DoorController, with script:
Scriptname EFTH_DoorControlActivator extends ObjectReference objectReference property ControlledDoor auto Event onActivate(ObjectReference akActionRef) ControlledDoor.Activate(game.getplayer()) endEvent
- marker EFTH_PZ1_LightController, with script:
Scriptname EFTH_IndicatorLightScript extends ObjectReference ObjectReference property IndicatorLight auto event onActivate(objectReference akActionRef) IndicatorLight.PlayAnimation("Green") endEvent
- door EFTH_PZ1_ExitDoor, with vanilla script DefaultUnlockLinkonActivate, and bShouldOpenDoor set true. Activate parent linked to EFTH_PZ1_DoorController
- activator EmergencyLightAnim01, activate parent EFTH_PZ1_LightController.
Behavior: When the door reference is set to inaccessible, this all works as intended when the two markers have the container set as an activate parent. However, this means the door isn't closeable, and since I want parts of this setup portable (40 more doors to do later), I want user control afterwards. But, with the reference accessible and locked to any tier, and the unlock function added to the doorcontroller script, everything fires on accessing the container, and fires repeatedly. Removing the activate parent links from the markers to the container just result in getting the door lock warning when accessing the container, and no activations. I'm obviously not doing something right here....
I'm going to put the other two in responses to keep this organized