forward spawn flags?


(Shad0w) #41

hmm, i changed what u said but, my script give the spawn to the owner of the flag, but, at the start, no one got the flag. I can select it on the map for axis, but i will not respawn at the forward point.

I tryed this script :

game_manager
{
spawn
{

\your stuff here

setautospawn “Forward Bunker” 1
setautospawn “Forward Bunker” 0
}

trigger forwardbunker_flagblue
{
// Some kind of UI pop-up to alert players
wm_announce “Allies captured the Forward Shack!”

  wm_objective_status   3 1 1 
  wm_objective_status   3 0 2 
  //accum 1 set 0 

}

trigger forwardbunker_flagred
{
// Some kind of UI pop-up to alert players
wm_announce “Axis captured the forward Shack!”

  wm_objective_status   3 1 2 
  wm_objective_status   3 0 1 
  accum 1 set 1 

}
}
forwardbunker_spawns
{
spawn
{
}
}

forwardbunker_wobj
{
spawn
{
}
}

forwardbunker_flag
{
spawn
{
accum 0 set 0 // Who has the flag: 0-Axis, 1-Allied
}

trigger allied_capture
{
accum 0 abort_if_equal 1 // do Allies own flag?

  trigger game_manager forwardbunker_flagblue 

  setstate forwardbunker_spawns default 
  setstate forwardbunker_wobj default 

  trigger forwardbunker_flag setallies 

  // *----------------------------------- vo ------------------------------------------* 
  wm_addteamvoiceannounce 0 "battery_axis_controls_defend" 
  wm_addteamvoiceannounce 0 "battery_axis_bunker_capture" 

  wm_addteamvoiceannounce 1 "battery_allies_controls_destroy" 

  wm_teamvoiceannounce 0 "battery_axis_bunker_lost" 
  wm_teamvoiceannounce 0 "battery_axis_controls_defend" 

  wm_teamvoiceannounce 1 "battery_allies_bunker_captured" 
  wm_teamvoiceannounce 1 "battery_allies_controls_destroy" 

  wm_removeteamvoiceannounce 0 "battery_axis_bunker_defend" 

  wm_removeteamvoiceannounce 1 "battery_allies_bunker_capture" 
  // *---------------------------------------------------------------------------------* 

}

trigger setallies
{
accum 0 abort_if_equal 1
accum 0 set 1

  alertentity forwardbunker_wobj 
  alertentity forwardbunker_spawns 

  setautospawn "Axis Spawn" 0 

}

trigger axis_capture
{
accum 0 abort_if_equal 0 // do Axis own flag?

  trigger game_manager forwardbunker_flagred 

  setstate forwardbunker_spawns default 
  setstate forwardbunker_wobj default 

  trigger forwardbunker_flag setaxis 

  // *----------------------------------- vo ------------------------------------------* 
        wm_addteamvoiceannounce 0 "battery_axis_bunker_defend" 

  wm_addteamvoiceannounce 1 "battery_allies_bunker_capture" 

  wm_teamvoiceannounce 0 "battery_axis_bunker_captured" 

  wm_teamvoiceannounce 1 "battery_allies_bunker_lost" 

  wm_removeteamvoiceannounce 0 "battery_axis_bunker_capture" 

  wm_removeteamvoiceannounce 1 "battery_allies_controls_destroy" 
  // *---------------------------------------------------------------------------------* 

}

trigger setaxis
{
accum 0 abort_if_equal 0
accum 0 set 0

  alertentity forwardbunker_wobj 
  alertentity forwardbunker_spawns 

}
}

// ================================================
// ============ FORWARD SPAWN ==============
// ================================================

forward_spawn
{
spawn
{
// accum 3 set 2 // 0-Axis, 1-Allied
}

trigger axis_capture
{

  accum 3 abort_if_not_equal 1

  accum 3 set 0

  trigger game_manager axis_flag

  setautospawn	"Forward Spawn"	0
  setautospawn	"Allies Spawn"	1

  wait 1000

  // *----------------------------------- vo ------------------------------------------*
  wm_teamvoiceannounce 0 "radar_axis_bunker_stop"

  wm_teamvoiceannounce 1 "radar_allies_bunker_capture"

  wm_addteamvoiceannounce 0 "radar_axis_bunker_stop"

  wm_addteamvoiceannounce 1 "radar_allies_bunker_capture"
  // *---------------------------------------------------------------------------------*

}

trigger allied_capture
{

  accum 3 abort_if_not_equal 0

  accum 3 set 1

  trigger game_manager allies_flag

  setautospawn	"Axis Spawn"	0
  setautospawn	"Forward Spawn"	1

  wait 1000

  // *----------------------------------- vo ------------------------------------------*
  wm_teamvoiceannounce 0 "radar_axis_bunker_captured"

  wm_teamvoiceannounce 1 "radar_allies_bunker_captured"

  wm_addteamvoiceannounce 0 "radar_axis_bunker_captured"

  wm_addteamvoiceannounce 1 "radar_allies_bunker_captured"
  // *---------------------------------------------------------------------------------*

}
}


(sock) #42

hmm, i changed what u said but, my script give the spawn to the owner of the flag, but, at the start, no one got the flag. I can select it on the map for axis, but i will not respawn at the forward point

Give me a moment I will whip up some example of forward spawn points. Its about time I finished off this section of the LDR.

EDIT: back with links …

Initially Allies controlled: http://www.planetquake.com/simland/ldr1_1/samplemap07a.htm
Initially Axis controlled: http://www.planetquake.com/simland/ldr1_1/samplemap07b.htm

EDIT: back with the final variant of the forward spawn, the oasis style permenant switch. The only other version I can think of is one linked to a command post like in the map radar. If people require this version I will create it otherwise I will get on with other sample maps instead.

Permenant switch: http://www.planetquake.com/simland/ldr1_1/samplemap07c.htm

Sock
:moo:


(Shad0w) #43

OMG!, IT’S WOORK!!! THXXXX :banana: :notworthy:


(Roeltje) #44

ME TOOOOO!!! :drink:
i have read this tutorial for 300 times now :banana:
and finally it wooorks!! :clap: :clap: :clap:


(eRRoLfLyNN) #45

I don’t suppose there is a way to do this?

Axis own at the start, spawning near it. Allies can capture, pushing Axis back, but don’t spawn around the flag themselves. They spawn at a forward location, but not around the flag.

How close do the forward Allied ctf_bluespawns need to be to the wolf_obj for it to work?


(ayatollah) #46

I think they can be positioned anywhere in the map…they don’t have to be right beside the flag at all. Could be wrong but I think I did that in an early stage of a map I made.


(eRRoLfLyNN) #47

I’ll give it a test anyway, see how it goes. I coulda phoned you! :stuck_out_tongue:


(]UBC[ McNite) #48

Shouldn’t be a problem.

Do you want to Allies spawn at the location you mentioned when they capture the flag, or is that connected to another event?
One thought about the gameplay though… if they spawn a good distance from the flag they capture, it will look odd. Maybe build the spawns around another event, or around a trigger_multiple construction. Not that this changes anything about what you want to effect, but players are used to spawn at the captured flag.


(eRRoLfLyNN) #49

Aye that I thought about that. When captured they spawn not too far away from it (maybe 5 secs away), but not as close as normal. The thing I was worried about was using 2 wolf_objs for use with the flag triggers, but it works fine with one. It looks a bit weird in limbo, if Allies get the forward spawn, but don’t spawn exactly at it, but I think players will get used to it.

I had the forward spawn originally connected with a destrucable gate, but it wasn’t great for gameplay. The flag, I hope, will improve it. Will let you know how the flag distance goes in some tests. :slight_smile:


(mortis) #50

The “team_WOLF_checkpoint” entity (flagpole) works regardless of what you do in the script. You should see in game the pole switching flags when either team touch the pole. The Axis/Allied spawn points will not switch unless they are linked to the flag pole.

The script is really being used to switch the state of “team_WOLF_objective” entity so that it will change on the command map. If you are unsure how to create one of these entities then check the sample map “goldrush” for an example.

I’m working on a script that will allow a capturable foward spawn (in et_beach) to be locked to the Allies when Allies have the CP up. I noticed by trial and error that the flag capture was indeed, as you noted, hard coded into the team_wolf_checkpoint. If I setstate the checkpoint invisible during this period, will it be uncapturable? Could I then bitset the flag so that it is ‘owned’ by the allies when the CP is built? I’m trying to set it to ‘lock’ when the CP is up and ‘unlock’ when the CP is blown by Axis.