//deathstar2battle_b state Base { Conditions { //Think about spawning general spline followers. if Timer > 8 and if NumInSetAlive "1" < 10 goto SpawnOnSpline } Actions { ResetTimer "mintime=0" "maxtime=2" } } state SpawnOnSpline { Conditions { if Random < 0.333 goto Spawn_1 if PreviousResult < 0.666 goto Spawn_2 if AlwaysTrue == 1 goto Spawn_3 } Actions { } } state Spawn_1 { Conditions { } Actions { CreateSplineCreatures "type=tiefighter" "type=tieinterceptor" "splines=tie_ai_a" "script=spline_tie" SetState "Base" } } state Spawn_2 { Conditions { } Actions { SelectRandomSpline "splines=tie_ai_a" CreateSplineCreatures "type=tiefighter" "use_selected_spline" "script=spline_tie" "x_offset=-1.5f" CreateSplineCreatures "type=tiefighter" "use_selected_spline" "script=spline_tie" "x_offset=1.5f" SetState "Base" } } state Spawn_3 { Conditions { } Actions { SelectRandomSpline "splines=tie_ai_a" CreateSplineCreatures "type=tiefighter" "use_selected_spline" "script=spline_tie" "x_offset=-1.5f" CreateSplineCreatures "type=tiefighter" "use_selected_spline" "script=spline_tie" "x_offset=1.5f" CreateSplineCreatures "type=tiefighter" "type=tieinterceptor" "use_selected_spline" "script=spline_tie" "y_offset=3.3f" SetState "Base" } }