I got it working, but two problems.
First, I want the weapon to be dropped on death. But not if pressing to drop it, with e.g "g".
Also, it's strange but the gun started acting weird after I tried my script.
Quote:
#include <sdkhooks>
#include <sourcemod>
public OnPluginStart()
{
for (new i= 1; i<= MaxClients; i++)
{
if (IsClientInGame(i))
{
SDKHook(i, SDKHook_WeaponDrop, OnWeaponDrop);
}
}
}
public OnClientPutInServer(client)
{
SDKHook(client, SDKHook_WeaponDrop, OnWeaponDrop);
}
public Action OnWeaponDrop(int client, int weapon)
{
return Plugin_Stop;
}
|