Thanks for the very beautiful plugin.
Looks like crash in L4D1 caused by the same issue, wrong sig for OnStaggered.
Bugs:
"Flash" grenade causes "Screen of death" appear, however player is not dead and continue to play.
"Freezer" doesn't target commons.
Also, plugin conflicts with gear_transfer. When you press LMB + RMB and somebody accidentally runs past you, you give him a grenade instead of switching the mode.
Can you add optional ConVar to change the method of switching grenade mode,
e.g.
PHP Code:
// Grenade switch mode: 0 - switch by circle, 1 - switch by menu (list of modes will appear)
l4d_grenades_switchmode "0"
New grenade type request:
"Tank" - force all tanks on the map to follow the grenade (e.g. use evil witch method - change angle OnThink).
"Antigravity" - force all players in the area to be pushed off the ground for some time (possibly, also not easy one, maybe force "+jump" hijack in OnPlayerRunCmd + changing velocity / gravity prop, and maybe check some abilities from
VPhysics).
--
Also, it's very nice to see configs for default "stock" grenade mode, to be able to override them, e.g. ignite time (like,
Spoiler
PHP Code:
public void OnPluginStart()
{
hConVar_FireLifetime = FindConVar("inferno_flame_lifetime");
}
public void ExplodeMain()
{
hConVar_FireLifetime.SetInt(l4d2_lw_firelifetime.IntValue, true, false);
// do action
CreateTimer(l4d2_lw_firelifetime.FloatValue + 0.5 /* this is required! */, Timer_RestoreLifeTime);
}
public Action Timer_RestoreLifeTime(Handle timer)
{
hConVar_FireLifetime.RestoreDefault(true, false);
}
), radius...
+ Like
__________________