Raised This Month: $ Target: $400
 0% 

Need help for AMX Respawn


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
ds811888
BANNED
Join Date: Mar 2009
Location: Hong Kong
Old 04-04-2009 , 15:19   Need help for AMX Respawn
Reply With Quote #1

Code:
public death_msg() 
{   
 if(get_pcvar_num(cvar_zrespawn))  
 { 
  new vIndex = read_data(2) 
  new svIndex[2]
  svIndex[0] = vIndex
  set_task(10.0,"respawn",0,svIndex,2)
 }
 return PLUGIN_CONTINUE 
}
public respawn(svIndex[]) 
{ 
 new vIndex = svIndex[0] 
 if(get_user_team(vIndex) == 3 || is_user_alive(vIndex)) 
  return PLUGIN_CONTINUE 
 spawn(vIndex)
 
 return PLUGIN_CONTINUE    
}
public plugin_init() 
{ 
 register_event("DeathMsg","death_msg","a")
 cvar_zrespawn   = register_cvar("bh_respawn","1") 
 
 return PLUGIN_CONTINUE 
}
I have a bug when set "10"

set_task(10.0,"respawn",0,svIndex,2)

+karma
ds811888 is offline
 



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 02:25.


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