Raised This Month: $ Target: $400
 0% 

[Snippet] ForcePlayerSuicide workaround for OrangeBox games


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
IceMatrix
New Member
Join Date: Sep 2007
Location: Germany
Old 04-18-2009 , 15:42   [Snippet] ForcePlayerSuicide workaround for OrangeBox games
Reply With Quote #1

As the normal slay using ForceClientSuicide() isn't working for players inside the spawn area in OrangeBox games like DOD:S, I looked for a workaround. But there wasn't a good one.
Mine uses DukeHacks extension and has exactly the same effect as ForcePlayerSuicide().


PHP Code:
#include <sdktools>
#include <dukehacks>

stock SuicideClient(client)
{
    
ForcePlayerSuicide(client);
    if (
IsPlayerAlive(client))
    {    
/* Inside spawn area */
    
        
SetEntityHealth(client0);
        
dhTakeDamage(clientclientclient0.0DMG_PREVENT_PHYSICS_FORCE DMG_NEVERGIB);
    }


Last edited by IceMatrix; 04-18-2009 at 15:45.
IceMatrix 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 18:22.


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