AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   I'm doing something wrote, my event wont fire (https://forums.alliedmods.net/showthread.php?t=57346)

Craftkiller 07-02-2007 23:41

I'm doing something wrote, my event wont fire
 
My goal is to eventually write a team balancer that works based on Mani Admin ranks but everyones gotta start somewhere. Can someone please tell me why I dont respawn when I type !revive

Quote:

#include <sourcemod>
#include <sdktools>
new Handle:hGameConf;
new Handle:hRoundRespawn;
//void CCSPlayer::RoundRespawn();
public Plugin:myinfo = {
name = "Craftkiller's Team Balancer",
author = "Craftkiller",
description = "Balances teams based on Mani Admin Rank",
version = "1.0",
url = "http://craftkiller.com"
};

public OnPluginStart()
{
RegConsoleCmd("sm_revive", Revive)
hGameConf = LoadGameConfigFile("plugin.sdkexamples");
StartPrepSDKCall(SDKCall_Player);
PrepSDKCall_SetFromConf(hGameConf, SDKConf_Signature, "RoundRespawn");
hRoundRespawn = EndPrepSDKCall();
}
public Action:Revive(client, args)
{
if (client)
{
new String:name[32]
GetClientName(client, name, sizeof(name))
PrintToConsole(client, "Command from client: %s", name)
RespawnPlayer(client);

} else {
PrintToServer("Command from server.")
}
}
RespawnPlayer(client)
{
SDKCall(hRoundRespawn, client);
}

Arkshine 07-03-2007 00:39

Re: I'm doing something wrote, my event wont fire
 
Wrong forum.

Craftkiller 07-03-2007 10:53

Re: I'm doing something wrote, my event wont fire
 
haha sorri, got to this forum from the sourcemod website, figured it was all sourcemod


All times are GMT -4. The time now is 21:33.

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