respawn option

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
digitac
Sergeant
Posts: 58
Joined: Mon Jul 28, 2003 3:30 pm

respawn option

Post by digitac »

Hi Guys,

I want to do the following but i really can't get any further

I want to when a player respawns after he died to go to an other spawn point like in liberation on Breaktrough
So when the map starts the player will spawns on the original spawn point
and when he died he spawns on the spawnpoint i made

i know how to create spawnpoints by using scripts.

Greetz DigitaC
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

you must have access to the *.map file. If you do: give the 2 different sets of spawnpoints 2 different names ( one set with targetname / "start_spawn_area" and the other set with targetname / "later_spawn_area" as an example ). Execute

Code: Select all

$later_spawn_area disablespawn
before the start of the map. And execute

Code: Select all

$later_spawn_area enablespawn
$start_spawn_area disablespawn
after, say... 10 seconds? ... Thats it.
Admin .MAP Forums
Image
Head above heels.
digitac
Sergeant
Posts: 58
Joined: Mon Jul 28, 2003 3:30 pm

Post by digitac »

That's the problem

I am creating a mod for an stock map :S

it's for The Hunt

Maybee u know how to do it there ?
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

It can be done I think... there is a thread somewhere on editing the spawns on stock maps.... just a sec...........


......here: /forum/viewtopic.php?t=5714&highlight=hex+bsp+spawn
Admin .MAP Forums
Image
Head above heels.
digitac
Sergeant
Posts: 58
Joined: Mon Jul 28, 2003 3:30 pm

Post by digitac »

is it possible to do the following
main:

Code: Select all

thread check_players
end

check_players:

Code: Select all

for ( local.n = 1 ; local.n <= $player.size ; local.n++ ) 
{ 
	$player[local.n].prisoner = 1
	$player[local.n] thread capture $player[local.n].dmteam
}
end

capture local.team:

Code: Select all

while (( isalive self ) && ( self.prisoner == 1 ))
{
	self.origin = ( x y z )
}
end


i did this just out of the head so i don't know if there is something wrong or so

DigitaC
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Hmmm... cool idea... it SHOULD work... try it.

But there is another way to do it: two different sets of spawnpoints. And you disable the "normal" spawn set a short while into the game and enable the set that is located only inside the prison.

And script object bars for the prison.

Make any sence?
Admin .MAP Forums
Image
Head above heels.
Post Reply