thecannons / Insurgency-dy-sourcemod

Updated folder structure
31 stars 21 forks source link

om_propspawn_sernix.sp exploit #30

Closed NullifidianSF closed 6 years ago

NullifidianSF commented 6 years ago

If player joins as engineer, opens engineer menu, switches to different class & then he/she can still build things. I'm not a programmer, but I managed to use existing code to do extra check if class is engineer before building prop.

on line 1161 change: if (client > 0 && g_ConstructRemainingTime[client] <= 0 && IsPlayerAlive(client) && !IsClientTimingOut(client) && ((StrContains(sWeapon, "weapon_knife") > -1) || (StrContains(sWeapon, "weapon_wrench") > -1)))

to:

if (client > 0 && g_ConstructRemainingTime[client] <= 0 && IsPlayerAlive(client) && !IsClientTimingOut(client) && (StrContains(g_client_last_classstring[client], "engineer") > -1) && ((StrContains(sWeapon, "weapon_knife") > -1) || (StrContains(sWeapon, "weapon_wrench") > -1)))