Home   Help Search Login Register  

Author Topic: Limiting Player Respawns  (Read 3382 times)

0 Members and 1 Guest are viewing this topic.

Offline norrin

  • Tutorial Writer
  • **
Limiting Player Respawns
« on: 14 Jul 2009, 05:35:50 »
Limiting player respawn scripts

© JULY 2009 - norrin

Description:
A suite of scripts that allows you to specify the total number of lives/respawns each team gets (for maximum of two sides).  When there are no lives left players respawn in spectate mode.  Players respawn with the load out they started the mission with.

Download
http://www.norrin.org/downloads/ArmA2/Limit_respawns/Limit_respawns_02.utes.rar

To implement
1. Copy the limit_respawns and NORRN_spectate folders into your mission directory
2. Copy the info from the description.ext into your own description.ext file - note you can change the respawndelay, header etc but respawn must = "base" and the AI must be disabled for the scripts to work.
3.  Copy the info from the init.sqf into your own init.sqf file - Note there are some parameters that you may wish to change here ie.

// Set parameters for the first playable side
_side_1       = WEST;
_total_respawns_1   = 2;
_respawn_point_1   = "west base";   

// Set parameters for the second playable side
_side_2       = EAST;
_total_respawns_2   = 3;
_respawn_point_2   = "east base";

To suit your mission set-up.

4.  If your 2 sides are WEST and EAST then create respawn_west and respawn_east markers on the map - alter to suit your settings.  NB make sure that these two markers are a long way from each other and the combat zone.
5. Create markers on the map at which you would like your players to respawn in the test mission these are named "west base" for west units and "east base" for east units
6. Create a game logic (object) in the editor and name it:

server

NB this last step is extremely important

When no lives remain, players will get a spectate camera when they die

Key Bindings for simple camera script
W/S keys - next/previous camera
A/D keys - next/previous unit
N - toggles night vision

In "Free camera" mode
Right mouse click on the screen and the camera will rotate, move up and down etc (many thanks to the boys at OFPEC for providing this function).
Mouse wheel -zoom in/out
This camera mode takes a little getting used to but you'll master it fairly quickly

Note these scripts have only been tested quickly so please let me know if any bugs exist.

Offline Binary

  • Members
  • *
Re: Limiting Player Respawns
« Reply #1 on: 17 Jul 2009, 17:02:31 »
Awesome !  :clap:

Is there a simple way to modify this so that respawn only accours when everyone has been killed?
« Last Edit: 17 Jul 2009, 17:04:03 by Binary »
"Ah.. Home sweet hell !" - Al Bundy

Offline norrin

  • Tutorial Writer
  • **
Re: Limiting Player Respawns
« Reply #2 on: 17 Jul 2009, 23:27:11 »
I can set-up something like this but first tell me exactly how you want it to work. This is what I think you're after:

1. When a player dies he goes into spectate mode
2. When all players on his side are dead he respawns at base with the other players on his side.

Is that right?

Offline MRO204

  • Members
  • *
  • I'm a llama!
Re: Limiting Player Respawns
« Reply #3 on: 20 Jul 2009, 01:21:58 »
I need something like that exactly Norris, Reinforcement Respawn as i would call it! if you can do something like that would be awesome, also this script is also great!  :good:

Keep up the good work!

Offline norrin

  • Tutorial Writer
  • **
Re: Limiting Player Respawns
« Reply #4 on: 22 Jul 2009, 14:19:58 »
Limited Player Lives with Reinforce Respawn system

JULY 2009 - norrin

Description:
A suite of scripts that allow you to specify the total number of lives/respawns each team gets (for two teams). Players only respawn once every other player in their group is dead.  If they die but they are  not the last unit to die in the group they can spectate the other units on the map while waiting for other team members to die. Players respawn with the load out they started the mission with.

Note: I recommend that you have the number of lives available equal to the a multiple of the group size eg. 2 players in a group have 2, 4, 6 or 8 lives etc

To implement:
1. Copy the Reinforce_respawn and NORRN_spectate folders into your mission directory
2. Copy the info from the description.ext into your own description.ext file - note you can change the respawndelay, header etc but respawn must = "base" and the AI must be disabled for the scripts to work.
3.  Copy the info from the init.sqf into your own init.sqf file - Note there are some parameters that you may wish to change here ie.

// Set parameters for the first playable side
_side_1       = WEST;
_total_respawns_1   = 4;
_respawn_point_1   = "west base";   

// Set parameters for the second playable side
_side_2       = EAST;
_total_respawns_2   = 4;
_respawn_point_2   = "east base";

To suit your mission set-up.

4.  If your 2 sides are WEST and EAST then create respawn_west and respawn_east markers on the map - alter to suit your settings.  NB make sure that these two markers are a long way from each other and the combat zone.
5. Create markers on the map at which you would like your players to respawn. In the test mission these are named "west base" for west units and "east base" for east units
6. Create a game logic (object) in the editor and name it:

server

NB this last step is extremely important

When no lives remain, players will get a spectate camera when they die

Key Bindings for simple camera script
W/S keys - next/previous camera
A/D keys - next/previous unit
N - toggles night vision

In "Free camera" mode
Right mouse click on the screen and the camera will rotate, move up and down etc (many

Once again thanks to the boys at OFPEC for providing this function).
Mouse wheel -zoom in/out
This camera mode takes a little getting used to but you'll master it fairly quickly
« Last Edit: 22 Jul 2009, 14:22:08 by norrin »

Offline MRO204

  • Members
  • *
  • I'm a llama!
Re: Limiting Player Respawns
« Reply #5 on: 19 Sep 2009, 11:52:41 »
Is it possible to make another kind of reinforment respawn? Let me explain.

You have many players fighting a battle, but when they die, they respawn in a waiting area then once the first player dies and is in the waiting area a timer starts to count down from how ever long you set it say 5min and if other players die say with a minute left to the counter everyone will all be teleported back to the base togther so they can all mount up and move back to the mission area togther.

Some pluses to this is that people wont respawn one at a time and each induvidually take a vehicle etc.

Offline Pirin

  • Members
  • *
Re: Limiting Player Respawns
« Reply #6 on: 19 Sep 2009, 19:01:11 »
So that means that everyone suffers an estimate 5 minute wait (excessively long imo) because you're worried about people taking vehicles?  Even a 10 second wait is painful for me. :)

Why not have motorbikes available for solo riders and instead limit larger vehicles to requiring a crew of 2-3+ before letting them roll out?

Offline MRO204

  • Members
  • *
  • I'm a llama!
Re: Limiting Player Respawns
« Reply #7 on: 19 Sep 2009, 20:30:21 »
thats becuause in our clan, we promote get shot wait 5min... otherwise people will just rambo and knw they will be back as base straight away and we dont want people taking unessary risks which may cause unessary deaths :)

also if the first person dies and he has 1min left to respawn with this idea if someone else dies he will only have to wait that 1min so everyone in that zone will all spawn together. "Reinforcement Respawn"