Raised This Month: $ Target: $400
 0% 

teleport all players?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
image.
Junior Member
Join Date: Dec 2010
Old 05-10-2013 , 10:20   teleport all players?
Reply With Quote #1

anyone know how to teleport all alive players to theirs respawns ?

Last edited by image.; 05-10-2013 at 10:22.
image. is offline
didoWEE
Senior Member
Join Date: Oct 2012
Location: Bulgaria
Old 05-10-2013 , 10:53   Re: teleport all players?
Reply With Quote #2

get the origins where they are spawned and teleport them to these origins when you want
didoWEE is offline
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 05-10-2013 , 11:16   Re: teleport all players?
Reply With Quote #3

PHP Code:
stock respawn_all()
{
    new 
intPlayersarrayPlayers[32]
    
get_players(arrayPlayersintPlayers"a")
    
    for(new 
0intPlayersi++)
    {
        
ExecuteHamB(Ham_CS_RoundRespawnarrayPlayers[i])
    }

__________________
Retired.

Last edited by Xalus; 05-15-2013 at 11:45.
Xalus is offline
didoWEE
Senior Member
Join Date: Oct 2012
Location: Bulgaria
Old 05-10-2013 , 11:50   Re: teleport all players?
Reply With Quote #4

Won't the weapons disappear?
didoWEE is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 05-10-2013 , 11:54   Re: teleport all players?
Reply With Quote #5

Weapons shouldn't disappear, but it will restore players' health to full. Should be something like this:
PHP Code:
    for(new 0playerhealthintPlayersi++)
    {
        
player arrayPlayers[i];
        
health get_user_health(player);
        
ExecuteHamB(Ham_CS_RoundRespawnplayer)
        
set_user_health(player);
    } 
__________________

Last edited by hleV; 05-10-2013 at 11:55.
hleV is offline
image.
Junior Member
Join Date: Dec 2010
Old 05-13-2013 , 11:16   Re: teleport all players?
Reply With Quote #6

thanks, now I need this function but...with only teleport alive ct to spawn and 'freeze' ct for 8 seconds...
image. is offline
jimaway
Heeeere's Jimmy!
Join Date: Jan 2009
Location: Estonia
Old 05-14-2013 , 14:08   Re: teleport all players?
Reply With Quote #7

check for player team in the for loop, add FL_FROZEN flag to the player and create a task to remove the frozen
jimaway is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:49.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode