SHARE
TWEET

Untitled

a guest Aug 12th, 2017 47 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. def remove(userid, weapon):
  2.         longname = 'weapon_'+weaponw(weapon)
  3.         if es.createplayerlist(userid)[int(userid)]['weapon'] == longname:
  4.                 es.cexec(userid, 'lastinv')
  5.  
  6.         handle = es.getplayerhandle(userid)
  7.         for index in es.createentitylist(longname):
  8.                 if es.getindexprop(index, 'CBaseEntity.m_hOwnerEntity') <> handle:
  9.                         continue
  10.                        
  11.         es.sexec(userid, "drop")
  12.                 #expand.drop(userid, longname)
  13.                
  14.                 wcs.wcs.tell(userid, 'xrestrict: restricted')
  15.                 break
  16.                
  17. def item_pickup(event_var):
  18.     remove(event_var["userid"], event_var["weapon"])
RAW Paste Data
Top