View Full Version : ClientCommand When Somebody Knifed.
i Wanna make everybody do a command when somebody knifed and killed.
how i can do it?
Dr. Greg House
02-03-2012, 17:08
How about googling?
http://docs.sourcemod.net/api/index.php?fastload=file&id=27&type=&
Keep in mind that there are certain restrictions affected by how the netcode is designed and security.
Jasonbourne
02-04-2012, 07:42
i Wanna make everybody do a command when somebody knifed and killed.
how i can do it?
i lol @ your threads
i Wanna make everybody do a command when somebody knifed and killed.
how i can do it?
What kind client commands... ?
TheAvengers2
02-04-2012, 12:19
Hmmm.. I think this is what you're looking for: http://wiki.amxmodx.org/Events_%28SourceMod_Scripting%29#Post_Hooks. All you need to do is add a check on the weapon and fake command, something like:
if (StrEqual(weapon, "weapon_knife"))
{
for (new i = 1; i <= MaxClients; i++)
{
if (!IsClientInGame(i))
continue;
FakeClientCommandEx(i, "say \"lol you got knifed, boy!\"");
}
}
Hmmm.. I think this is what you're looking for: http://wiki.amxmodx.org/Events_%28SourceMod_Scripting%29#Post_Hooks. All you need to do is add a check on the weapon, something like:
if (StrEqual(weapon, "weapon_knife"))
{
// do something
}
how can i do it?
vBulletin® v3.8.7, Copyright ©2000-2024, vBulletin Solutions, Inc.