Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <sourcemod>
- #include <sdktools>
- #include <sdkhooks>
- #include <iAmmo.CoreClude>
- #pragma semicolon 1
- #pragma newdecls required
- public void OnPluginStart()
- {
- RegConsoleCmd("sm_clip", clip);
- }
- public Action clip(int client, int args)
- {
- int weapon = GetEntPropEnt(client, Prop_Send, "m_hActiveWeapon");
- if(IsValidEntity(weapon))
- {
- int m_iPrimaryAmmoType = -1;
- if ((m_iPrimaryAmmoType = GetEntProp(weapon, Prop_Send, "m_iPrimaryAmmoType")) != -1)
- {
- SetEntProp(client, Prop_Send, "m_iAmmo", 0, _, m_iPrimaryAmmoType);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment