//MosEisley_B //Handles opening gate and door between a and b state Base { Conditions { if MissionMode == 1 goto MissionMode if AlwaysTrue == 1 goto Update } Actions { } } state Update { Conditions { if Message "storm_door1" == 1 and if ObstacleAtStart "storm_door1b" == 1 goto OpenStormDoor1 if Message "storm_door1" == 0 and if ObstacleAtStart "storm_door1b" == 0 goto OpenedStormDoor1 if Message "gate1" == 1 and if ObstacleAtStart "gate1b" == 1 goto OpenGate1 if Message "gate1" == 0 and if ObstacleAtStart "gate1b" == 0 goto OpenedGate1 if PlayerInTriggerArea "Cantina_Door" == 1 and if BaddyInTriggerArea "Cantina_Door" == 0 and if ObstacleAtStart "cantina_door" == 1 goto OpenCantinaDoor ;if BaddyInTriggerArea "Cantina_Door" == 1 and ;if ObstacleFinished "cantina_door" == 1 goto CloseCantinaDoor } Actions { } } state OpenStormDoor1 { Conditions { } Actions { SetObstacleToEnd "name=storm_door1b" SetState "Update" } } state OpenedStormDoor1 { Conditions { } Actions { SetMessage "name=storm_door1" "value=1" SetState "Update" } } state OpenGate1 { Conditions { } Actions { SetObstacleToEnd "name=gate1b" SetState "Update" } } state OpenedGate1 { Conditions { } Actions { SetMessage "name=gate1" "value=1" SetState "Update" } } state OpenCantinaDoor { Conditions { } Actions { PlayObstacle "name=cantina_door" SetState "Update" } } state CloseCantinaDoor { Conditions { } Actions { PlayObstacle "name=cantina_door" "backwards" SetState "Update" } } state MissionMode { Conditions { } Actions { } }