1.
Quote:
Originally Posted by NiHiLaNTh
Its 2018, why you still change viewmodels with CurWeapon event?
|
Fix this.
2.Don't use FM_Touch when you want to catch specific touches between entities, register_touch from engine or Ham_Touch should be better in this case because filtering is doing in the module.
3.
PHP Code:
#define SMOKE_ID 26
Don't hardcode that, use precache_event with
createsmoke.sc.
4.Use real offset names
OFFSET_GRENADE - >
m_usEvent
5.Don't duplicate code, create a private function for this:
PHP Code:
new iColor[3], iCvar = get_pcvar_num(g_pCvarExplosionColor)
iColor[0] = (iCvar / 1000000)
iCvar %= 1000000
iColor[1] = (iCvar / 1000)
iColor[2] = (iCvar % 1000)
6.I don't think you have to check both
isGrenade and
isAvaliableGrenade,
isAvaliableGrenade should be enough.
__________________