[TFC] Grenade Bug (Respawn Grenades Bug)
This is 2 of 2 remaining bugs in TFC that really need attention.
Name: Grenade Bug (Respawn Grenades)
Explanation: This is another strange and rather inconsistent bug. The respawn grenade bug occurs when an unfortunate player has a grenade primed upon dying. When the respawn occurs, the grenade appears to travel with the player into the respawn and explodes causing damage to the player and his or her team mates. Seems to effect every type of grenade and is more frequent than the Death Bug.
I have no video clips of this bug yet.
Servers are currently using a 3rd party AMXX Plugin to fix this bug and a Metamod plugin called Sparkys is also available.
AMXX Plugin: https://forums.alliedmods.net/showthread.php?t=333746
- FIX 14: Grenades that prime immediately before death will no longer follow the player to their spawn if they respawn quick enough.
Sparkys Utilities: http://web.archive.org/web/20050502130920/http://sparky.konspiracy.org/server/
An official fix would make the game almost perfect.
The game doesn't remove grenades that are primed when the player respawns. There is logic for throwing grenades from dead players so it should be fine to continue priming the grenade if they haven't respawned yet.
A check could be added to grenades where if the player has respawned after the grenade was primed but before a grenade has been thrown the grenade is simply removed instead.
The method CTFPrimeGrenade::GrenadePrimed already contains logic to do this, so a second condition needs to be added:
//Don't remove grenades spawned the same frame as when the player respawned?
if ( pPlayer->bRemoveGrenade || m_flPrimeTime < pPlayer->m_flLastRespawnTime )
{
if( pPlayer->bRemoveGrenade )
{
pPlayer->tfstate &= 0xFFFFFBFE;
pPlayer->bRemoveGrenade = 0;
}
dremove(this);
return;
}
The new variables need to be added of course.
Just had some more information passed regarding this bug by the guys that made the TFC Fixes Plugin:
[09:50] azul`: it's a question of respawning too quickly after priming a grenade... there's a window in which the grenade entity thinks before it actually exists as a proper ctf grenade entity if you respawn before it does the 2nd think and assigns itself as the proper grenade the origin doesn't set, so it ends up setting on the priming player.
@mikela-valve
It sounds like there could be a couple easy ways to fix this problem. And it is indeed an obnoxious bug for those that routinely experience it (as I do), and which even casual players continue to express great annoyance over.
#2493 Also remains an important grenade-related issue that severely impacts most players' abilities to accurately time their conc/grenade jumps depending on server lag, especially casual/vanilla players who don't take the time to implement some of the more complex workarounds (which still have their own significant drawbacks).
I have added a fix to the TFC Bug Fixes plugin for AMXX while this is fixed by Valve:
https://forums.alliedmods.net/showthread.php?t=333746