Quote:
Originally Posted by p3tsin
PHP Code:
for(new i = 1; i <= MaxClients; i++) { if(IsClientInGame(i) && IsPlayerAlive(i) && GetEntProp(i, Prop_Send, "m_nPlayerCond") & 16) { //player is cloaked } }
Sorry, couldnt resist optimizing your code
PHP Code:
KillSentries(client) { new offset = FindSendPropInfo("CObjectSentrygun","m_hBuilder"); new ent = -1;
while((ent = FindEntityByClassname(ent,"obj_sentrygun")) != -1) { if(GetEntDataEnt2(ent, offset) == client) { AcceptEntityInput(ent, "Kill"); } } }
|
Hehe, I nicked it from the dispenser on death plugin, the author of which had credited Bl4nk for the snippet. Thanks
Quote:
Originally Posted by p3tsin
The first (and only) thing that comes to my mind would be OR'ing in IN_DUCK to the client's buttons in ProcessUsercmds hook (post hook?).
|
OR'ing? umm I'll do some research I suppose
edit: oh dukehacks, I was wondering if I'd have to use that
Quote:
Originally Posted by p3tsin
You'd have to modify the packets sent to clients. In the HL1 engine this could be done by hooking AddToFullPack, havent tried it in source yet. At least I can tell you its not doable without an extension.
|
Blah, I'll just try and force thirdperson on them then
__________________