spawn script


(DWM|Commando) #1

Hey guys here is a script for one of my capturable spawns this is a default axis spawn that originally, i “borrowed” from a sample/tutorial. I am learning scripting though and i want to try to make this work with another capturable spawn so when one is captured it dosnt send the axis to the one determined by the one they captured… its complicate but i need to know waht you guys think or know the accums are for in the script.

I think accum 1 is what is used to tell who has captured the spawn. so the axis cant “re-capture” their own sapwn causeing the entities to alternate. i dont know about 2 or 3 though or their roles i nteh script, any help would be great, i cant find the tutorial i used to make this. thanks!


{
	spawn
	{
		wait 200
		accum 1 set 0
		accum 2 set 0
		accum 3 set 0
	}
	trigger axis_capture
	{
		accum 1 abort_if_equal 0
		accum 1 set 0 
		wm_announce "Axis reclaim the Cafe!"
		setstate cafe_spawn_wobj default
		setautospawn "Cafe"	0
		setautospawn "City Entrance"	1
		alertentity cafe_spawn_wobj
		alertentity cafe_spawn
		accum 3 abort_if_equal 1
		accum 2 abort_if_equal 1
		alertentity cafe_spawn_wobj
		accum 2 set 1
	}

	trigger allied_capture
	{
		accum 1 abort_if_equal 1
		accum 1 set 1
		wm_announce "Allies capture the Cafe!"
		setstate cafe_spawn_wobj default
		alertentity cafe_spawn_wobj
		alertentity cafe_spawn
		setautospawn "Cafe"	1
		setautospawn "Garage"	0
		accum 3 set 1
	}
}



(TFate) #2

Whatever they are they seem unnecessary. It appears that they keep track of if either team has ever had the flag. (2=Axis, 3=Allies)


(DWM|Commando) #3

ohh thats it. that sounds very familiar from the tutorial… . i jsut want to make sure before i take out parts that i dont know about.