View Single Post
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 06-06-2017 , 23:12   Re: Help with plugin
Reply With Quote #13

Quote:
Originally Posted by dzinks2009 View Post
I hooked up playerspawn but how do i use it now? Sorry, Im kind of new in c++
PHP Code:
#include <sdktools>

public OnPluginStart()
{
    
HookEvent("player_spawn"Action:Event_PlayerSpawn);
}
public 
Action:Event_PlayerSpawn(Handle:event, const String:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event"userid"));
    if (
IsPlayerAlive(client) && g_bKill)
        
ForcePlayerSuicide(client);


Last edited by 8guawong; 06-06-2017 at 23:13.
8guawong is offline