//Sets: // 1: Creatures at end // 2: Pen Guards 4: Freeplay ledge people state Base { Conditions { if FreePlay == 0 goto NormalInit if Message "TatooineA_Init" == 0 goto InitOnce if Message "TatooineA_Init" == 1 goto Update } Actions { AddLocatorGroup "name=graze" //for the dewbacks to graze on AddLocatorGroup "name=Ledge" CnxController "from=jump1_a" "to=jump1_b" "off_flag=BLOCK" "obj=rock_plat01a" "checkvisible" "on_frames=lastframeTOlastframe" "bXothways" CnxController "from=jump1_b" "to=jump1_c" "off_flag=BLOCK" "obj=rock_plat01a" "checkvisible" "on_frames=lastframeTOlastframe" "bXothways" //want people to be able to jump down CnxController "from=bridge1_a" "to=bridge1_b" "off_flag=BLOCK" "obj=speeder_bridge" "checkvisible" "on_frames=1TOlastframe" "bothways" CnxController "from=rock_bridge_a " "to=rock_bridge_b" "off_flag=BLOCK" "obj=rock_plat01a" "checkvisible" "on_frames=lastframeTOlastframe" "bothways" CnxController "from=door1_a" "to=door1_b" "on_flag=BLOCK" "obj=DF_door_01" "checkvisible" "on_frames=1TOlastframe" "bothways" CnxController "from=ramp_a" "to=ramp_b" "off_flag=BLOCK" "obj=landspeederb" "checkvisible" "on_frames=lastframeTOlastframe" "bothways" CnxController "from=free_a" "to=free_b" "on_flag=BLOCK" "obj=bhblock_01" "checkvisible" "on_frames=lastframeTOlastframe" "bothways" CnxController "from=rockplat1_a" "to=rockplat1_b" "off_flag=BLOCK" "obj=rock_plat_01" "checkvisible" "on_frames=lastframeTOlastframe" "bothways" CnxController "from=rockplat1_b" "to=rockplat1_c" "off_flag=BLOCK" "obj=rock_plat_01" "checkvisible" "on_frames=lastframeTOlastframe" "bothways" SetPathCnxFlag "from=bantha_a" "to=bantha_b" "BLOCK" "bothways" ObstacleTriggerSet "trigger=pad1" "trigger=pad2" oXbstacle="allpadfinish" SetMessage "name=Place_C3PO_By_Gap" "value=1" SetMessage "name=Place_R2D2_By_Gap" "value=1" } } state NormalInit { Conditions { if Message "TatooineA_Init" == 0 goto InitOnce if Message "TatooineA_Init" == 1 goto Update } Actions { Activate "character=LukeSkywalker_tatooine" Activate "character=benKenobi" SetTaggable "character=C3PO" "FALSE" SetTaggable "character=R2D2" "FALSE" } } state InitOnce { Conditions { } Actions { SetMessage "name=TatooineA_Init" "value=4" SetMessage "name=freeplay_guard" "value=2" SetState "Update" } } state Update { Conditions { if EitherPlayerInTriggerArea "Pen" == 1 and if NumInSetAlive "2" < 4 goto ReinforceTusken if NumInSetAlive "4" == 0 and if Message "LedgeSpawns" < 3 and if EitherPlayerInTriggerArea "Spawn_2" == 1 goto ReinforceLedge if Message "BanthaLedgeEnabled" == 0 and if EitherPlayerInTriggerArea "BanthaLedge" == 1 goto EnableBanthaCnx } Actions { } } state EnableBanthaCnx { Conditions { } Actions { SetPathCnxFlag "from=bantha_a" "to=bantha_b" "BLOCK" "FALSE" "bothways" SetMessage "name=BanthaLedgeEnabled" "value=1" SetState Update } } state ReinforceTusken { Conditions { } Actions { CreateCreatures "locator=start_spawn" "type=TuskenRaider" "script=PenGuard" "addtoset=2" CreateCreatures "locator=start_spawn_0" "type=TuskenRaider" "script=PenGuard" "addtoset=2" SetState Update } } state ReinforceLedge { Conditions { } Actions { CreateCreatures "locator=freeplay_ledge" "type=TuskenRaider" "groupsize=3" "script=tusken_ledge" "addtoset=4" SetMessage "name=LedgeSpawns" "increment=1" SetState Update } }