Jump to content
Sign in to follow this  
Robinio

One Side Respawn?

Recommended Posts

Is there a way making only one side respawn? I'm making a mission but I only want one side to re spawn, I follow the example of making a sqf file.

But I only place one marker for east, then when the east die, they respawn at the point, when other sides die, the respawn there to (at the east respawn) why?

Share this post


Link to post
Share on other sites

You can move the respawnet player away from the battlefield.. then make a Camera for this players they can not respawn and disable the Playerinbut or somthink like this.

Share this post


Link to post
Share on other sites

ummm....im interested in this as well. Im making a missions where you can play as CDF and marines, each start in different towns. Of course, i want each side to spawn in their towns as well :)

+ on a side topic, is it possible to make it so you only respawn once an objective has been completed?

Share this post


Link to post
Share on other sites

Add the Kill event to each player and exec yout Rewpawn script. this can something like this:

(not testet)


cutText ["you died...","BLACK OUT"];
sleep playerRespawnTime;

if(player isKindOf "USMC_Soldier") then {
  if(mission1done) then {
    playet setPos getMarkerPos "respawn_west2usmc";
  };

  if(mission2done) then {
    player setPos getMarkerPos "respawn_west3usmc";
  };
};

if(player isKindOf "CDF_Soldier) then {
  if(mission1done) then {
    playet setPos getMarkerPos "respawn_west2cdf";
  };

  if(mission2done) then {
    player setPos getMarkerPos "respawn_west3cdf";
  };
};

sleep 0.5;
cutText ["you died...","BLACK IN"];

you can also use TypeOf for the isKindOf Command....

Share this post


Link to post
Share on other sites

Ok... so now:

On the INIT.SQF add this Line:

if(local player) then {
  player addEventHandler ["killed", {_this execVM "respawn_player.sqf";}];
};

Create a new textfile name it respawn_player.sqf copy in this code:

if(local player) then {

  cutText ["you died...","BLACK OUT"];
  sleep playerRespawnTime;

  // USMC Respawn at spawn_usmc

  if(player isKindOf "SoldierWB") then {
       player setPos getMarkerPos "spawn_usmc";
  };

  // CDF Respawn at spawn_cdf

  if(player isKindOf "CDF_Soldier_Base") then {
       player setPos getMarkerPos "spawn_cdf";
  };

  sleep 0.5;
  cutText ["","BLACK IN"];

};

Go to the Editor and create 3 Markers:

respawn_west = on any position but far away the battlefield

spawn_usmc = place this marker on the town you whant to spawn the USMC players

and:

spawn_cdf = the respawn fpr the CDF players.

i hope this will work for you.

Edited by R34P3R

Share this post


Link to post
Share on other sites

Just tried it out. My player moved to the respawn marker, but he was still a dead body :p So the marker's work, but for some reason it didnt bring ,me back to life.

Share this post


Link to post
Share on other sites

What kind of respawn do you use in your description ? you must use :

respawn=3;

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×