Team Fortress 2 Update Released

tf2.com

L13: Stunning Member
Jun 16, 2010
1,186
712
An update to Team Fortress 2 has been released. The update will be applied automatically when you restart Team Fortress 2. The major changes include:
  • Fixed a server crash caused by running out of free edicts
  • Fixed a problem that was preventing some older demos from being played
  • Fixed the Spy getting the afterburn immunity while disguised as Demoman wielding the Chargin' Targe
  • Fixed the Process and Standin map stamp donations displaying incorrect map names on the World Traveler
  • Fixed the Pyro not using the correct model for the Reserve Shooter
  • Fixed a bug that would cause certain attributes (kill counts, trade time) to appear incorrectly on items viewed through Steam Community and the trade UI
  • Removed promotion restrictions from the Crosslinker's Coil
  • Updated the Loose Cannon description to match the updated gameplayUpdated the Short Circuit description to match the updated gameplay

Source: TF2.com
 

henke37

aa
Sep 23, 2011
2,075
515
Was there a map that overran the edict budget?
 

Toomai

L3: Member
Apr 14, 2011
129
144
[*]Fixed the Spy getting the afterburn immunity while disguised as Demoman wielding the Chargin' Targe
This is the kind of thing that makes you wonder just how ridiculously convoluted the game's codebase has become.
 

PoignardAzur

L2: Junior Member
Mar 21, 2013
92
9
This is the kind of thing that makes you wonder just how ridiculously convoluted the game's codebase has become.

Oui. I thought that they had a specific part in the code of the spy that said "He hasn't any effects of the objects he pretends to be wearing !".

EDIT : what am I writing ? I mean, they're shouldn't be any part in the code that gives the spy any enemy attribute. (yeah, like henke says)
 
Last edited:

henke37

aa
Sep 23, 2011
2,075
515
More like that there shouldn't be any code that links his attributes to those of the one he is impersonating.
 

PoignardAzur

L2: Junior Member
Mar 21, 2013
92
9
Yeah, but what part of the code makes the spy immune to fire after getting the Chargin' Targe ? I mean, I guess the spy's code only include his appearance, and how enemies (medic, sentries) affect him. This has nothing to do with being immune to fire.
The only way I see that would make that glitch possible is if the fireproofness was implemented in the same code that handles appearing with the Targe. But then, since it's probably the same code that handles the snipers bagpack, shouldn't you have the same bonus has a sniper when disguising him ? It makes little sense to me.
 

henke37

aa
Sep 23, 2011
2,075
515
It is however wrong, since it violates the IS-A test.
 

PoignardAzur

L2: Junior Member
Mar 21, 2013
92
9
such bugs are perfectly normal when the code grows larger than what one person can keep in mind and architectural mistakes come into play along with the local ones
I don't say that this code proves bad coding, just... I don't understand how it was possible in the first place ? What mistake could have lead to that and not have been fixed before this update ?
 

Toomai

L3: Member
Apr 14, 2011
129
144
cant go into specifics without knowing details of whatever system they have in place for that
Frankly if they had a functioning system we wouldn't be having things like the invisible buildings bug hang around for more than 24 hours.
 

Geit

💜 I probably broke it 💜
aa
May 28, 2009
598
1,161
I don't say that this code proves bad coding, just... I don't understand how it was possible in the first place ? What mistake could have lead to that and not have been fixed before this update ?

The following is pure speculation based on the networked properties of TF2 Items:

In TF2 every item inherits a base item class which provides a member value called m_hOwnerEntity - this is the entity number of the client (with a value of anywhere between 1 and 33). When an effect on a weapon is supposed to be applied to the client, as opposed to the weapon itself, like afterburn immunity, it would have to access m_hOwnerEntity and apply the effect there.

This bug most likely arises from the person who programed it forgetting to check if the m_hOwnerEntity is actually a *disguised* spy, rather than a demoman, and thus applying the effect with impunity.

In programming terms, the fix is probably something as simple as

Code:
if(m_hOwnerEntity->getClass() == TFClass_Spy && (m_hOwnerEntity->getConditionFlags() & TFCond_Disguised) == TFCond_Disguised)
{
    // Do stuff, but don't give afterburn-immunity...
}
 

henke37

aa
Sep 23, 2011
2,075
515
Uhm, shouldn't it be a simple matter of using a different base class? You know, the one that only shows the model and nothing more?
 

Geit

💜 I probably broke it 💜
aa
May 28, 2009
598
1,161
Uhm, shouldn't it be a simple matter of using a different base class? You know, the one that only shows the model and nothing more?

Because some of the attributes of a weapon do need to be applied to the disguised spy in some circumstances, and it's the weapon class that determines those attributes?
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,701
2,583
I'm trying to think what items would need to do that. The GRU making "heavies" as fast as the spy can already run? The Excape Plan doing likewise? Can't think of any others offhand, and I don't even know if either of those do that.
 

Geit

💜 I probably broke it 💜
aa
May 28, 2009
598
1,161
I'm trying to think what items would need to do that. The GRU making "heavies" as fast as the spy can already run? The Excape Plan doing likewise? Can't think of any others offhand, and I don't even know if either of those do that.

I was more thinking along the lines of taunts, names, particle effects and stuff like that. - I honestly have very little idea why they do it the way they do, I'm not a Valve employee, but their method does make a lot of sense in some respects.