Raised This Month: $ Target: $400
 0% 

Respawn player without Animation


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Trickzz
Member
Join Date: Jun 2011
Old 07-10-2012 , 17:58   Respawn player without Animation
Reply With Quote #1

How to do that would be the death of the body vanished and death animation player

Code:
public respawn_player(id)
{
    // Disconnected, already spawned, or switched to Spectator
    if (!is_user_connected(id) || is_user_alive(id) || cs_get_user_team(id) == CS_TEAM_SPECTATOR)
        return;
        
    // Try to spawn the player setting the appropiate dead flag and forcing a think
    set_pev(id, pev_deadflag, DEAD_RESPAWNABLE, EF_NODRAW)
    dllfunc(DLLFunc_Think, id)
    
    // Fix for CZ Bots: DLLFunc_Think won't work on them,
    // but DLLFunc_Spawn does the job without any bugs.
    // (for some reason I'm not suprised...)
    if (is_user_bot(id) && pev(id, pev_deadflag) == DEAD_RESPAWNABLE)
    {
        dllfunc(DLLFunc_Spawn, id)
    }
}
Trickzz is offline
Reply



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 15:13.


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