Jump to content
Sign in to follow this  
ZNorQ

Multible 'base' respawn zones

Recommended Posts

In my MP COOP there are 3 teams with one medic each. This medic is responsible for establishing and moving a medic tent where the casualities will respawn.

The way it is supposed to work, is that when a player dies, he will respawn to the nearest medic tent.

But, I'm abit uncertain how to go about this challange. What I did try is to use a 'BASE' respawn, and then just setpos the player to the nearest tent, based on where he died. But, when I try this, the engine refuses to move the player to this position.. (Talking about setPos, I've heard rumours that setPos isn't working properly in MP, can anyone confirm this?)

This is the code snippet I use in my respawn script (initiated by EH "Killed")

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">player setPos getMarkerPos "markernamehere"

Any ideas why?

ZNorQ

Share this post


Link to post
Share on other sites

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

player setpos [getmarkerpos "markernamehere" select 0,getmarkerpos "markernamehere" select 1,0];

Share this post


Link to post
Share on other sites

I'm pretty sure I've already tested that, but I'll try again.

Share this post


Link to post
Share on other sites

It worked. Was so sure I already tried that, but I was wrong I guess..

Thanks, Zaphod.

ZNorQ

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  

×