//This script controls the door at the end of the prison corridor state Base { Conditions { if MissionMode == 0 goto Update } Actions { SetPathCnxFlag "from=lift_6_b" "to=lift_6_a" "BLOCK" CnxController "from=lift_6_a" "to=lift_6_b" "off_flag=BLOCK" "obj=lift_6_door_a" "checkvisible" "on_frames=lastframeTOlastframe" } } state Update { Conditions { if ObstacleFinished "cell_main_door" == 1 and if PartyUnderCover == 0 and if NumBaddiesThatCanSeePlayers < 2 goto CallLift } Actions { LockDoor "lift_door_6" ResetTimer } } state CallLift { Conditions { if ObstacleFinished "lift_lights_6" == 1 goto OpenLift } Actions { PlayObstacle "name=lift_lights_6" } } state OpenLift { Conditions { if DoorClosed "lift_door_6" == 1 goto LiftDeparting } Actions { CreateCreatures "locator=lift_6" "type=deathstartrooper" "script=SpawnAttack" "mingroupsize=2" "maxgroupsize=3" "nacross=2" "xspacing=0.1" "zspacing=0.1" AlertCreatures "character=player" UnLockDoor "lift_door_6" OpenDoor "lift_door_6" } } state LiftDeparting { Conditions { if ObstacleAtStart "lift_lights_6" == 1 goto Update } Actions { LockDoor "lift_door_6" PlayObstacle "name=lift_lights_6" "backwards" } }