This is a compilation of all the not-so-widely-known stuff I have found in TF2. Includes gameplay mechanics, cool tips and tricks, a bit of math and lots of cvar explanations.

Please note that this is just a draft; my English skills aren't that good for a neatly formatted guide. I'll leave it to someone else.

There may be errors and miscalculations. Bear with it. I can't physically test all the stuff that is written here.

I'll try to update this guide when I'm not too lazy... If you encounter an error or have a suggestion, comment in this reddit thread, or hit me up in Steam.

UPDATE 02/26/16: yay! YouTube user SeriousMartin made a video describing some of the most useful tricks. Look it up - it's better to see that stuff in-game and narrated.

UPDATE 02/27/16: Finally made that renderer documentation. There is even a small FPS config. Also moved sound and voice stuff in their separate files. Going for material system now.

Other guides/documentations with huge walls of text

I'm still expanding this guide. It gets bigger. And as this tiny textbox cannot hold all that weight, I have to put some info in separate files.

At the moment I have these (mainly deep-level cvar documentations):

Renderer (r_cvars): everything renderer-related. Optimize your game to MAXIMUM PERFORMANCE. Debunk FPS configs with all that n'awledge. They have to know the truth.

Voice system (voice cvars): voice-related stuff. If you are using in-game voicecomm often, you surely have to take a look.

Sound system (snd, dsp cvars): sound system cvars and explanations. Now you will definitely hear that jumping soldier that needs a health pack on cp_badlands.

My small FPS config: it's a huge work in progress and it is not anywhere near finished. However, you can take a look. It is also documented.

There will be more. Keep an eye on it!

The actual guide

General tricks, random stuff and such

Use "extendfreeze" command to extend your death time by two seconds. Spam it in the console if you want to be dead the entire round. VERY useful in MvM if you just don't have enough respawn time for your medic to revive you. Hit the bind and bam, instant +2 seconds.

Another way of extending your freezetime is keeping the class selection screen open.

You can destroy player-dropped ammo packs with explosives! They have 900 health, so carefully putting 8-10 stickies under one should definitely destroy it. Practically useless, but still interesting.

For some reason if Scottish Resistance or Quickiebomb Launcher stickies collide with each other, they do reduced damage to the ammo pack. That does not happen with the stock stickybomb launcher. To circumvent that, put stickies in a circle around the ammo pack, that should do it.

Ammo packs also have a 30-second life time and a single player could never spawn more than 3 simultaneously.

Played-dropped weapons, however, have infinite health. That's why it is possible to glitch doors, gates and carts using Heavy's gloves.

If playing as a random class (question mark icon), you won't be selected as the same class twice in a row. The game always selects a new class for you when respawning.

Heavy has a 50% knockback penalty from everything, except sentry gun bullets. That's what makes pootisbirds possible.

If a player recently took damage and was left with 25% or less health, his in-game character face would look sad. With facial features turned on, estimating enemy's health using this trick can be a solid strategy.

Passing an argument to lastdisguise makes the spy disguise as a random class, excluding Spy and Scout. Without the argument you just get the most recent disguise. Something like lastdisguise random will do the trick.

When you change teams or disconnect from the server, any spies disguised as you will automatically redisguise as someone else. The spy kit will try to pick a person with the same class to disguise, but if there's no one, the spy will just redisguise as a random class.

That does not apply to forced team changes, like scrambles, team swaps or switching to spectator due to idling.

Also your dominations/revenges will be lost, so if you just can't kill that pesky HL plat sniper, change your team and then change back.

TF2 takes too much time to load? If you have a HDD, put the TF2 folder in the end of your physical drive using a defragmenting tool. That should result in decreased load times.

- MVM -

If an engineer destroys their sentry while a sentry buster is tracking it, the buster will still continue tracking to the last known sentry position. That allows engineers to place their sentry in an unreachable position, and then destroy it so the buster will infinitely run around trying to get to the non-existent sentry. Tell your Medic/Soldier to smack the buster for free uber/banner and hope your other teammates won't do the same.

That also resets buster cooldown for kills and damage. You can trick the second buster same way.

Note: the spot should be in navvable area! Rocks on Mannworks won't work.

My personal favorite on this one is some pallets near the drop-down on Mannhattan. Also the rightmost rock on Rottenburg.

Medic's shield, when on level 1, has only 30% less frontal coverage compared to level 2. Taking full coverage into account, the level 2 has 100% more, as expected. It also recharges faster.

Medics farm 100% more support points when kritzing someone who is dealing damage to the tank. They get 2 points for each point of indirect damage done to the tank, compared to 1 point for regular robots.

Medic's canteens do not count to "Invulns" stat.

Medics can instantly revive people! When the reanimator falls from a dead person, there is a small delay before it sets up a "max health" entprop. So if you start reviving the reanimator as soon as it spawns, the revive will be instant. In order to do it, aim a little over the person's head when he is about to die. If you do this right, your medigun beam will catch the falling reanimator, which at the moment has 0 max health, and a single server tick will be enough to do a full revive. You can mess with people who are trying to suicide, you can farm points at the meat grinder in Mannhattan, or even trap your teammates in wooden bridge at Rottenburg (when they are trapped, just hold the beam steady above their head).

Easy and Normal robots have poor prediction skills when tracking a moving target. Strafe left and right in front of a robot so that it loses its aim. Easy/Normal robots also have blue eye color, compared to Hard/Expert: these robots have yellow eye color.

There is A LOT more stuff regarding MvM on sigsegv's channel which is here.

- SENTRY -

When sentry gun is idle, it turns left and right, searching the area for enemies. Its max turn cone is 90 degrees, and when a sentry is deployed it initially starts to turn right. Sentries also turn up or down sometimes when idle (max angle is 10 degrees in both sides, possibility is 30% on each rotation).

Sentry health increases by 20% at each level (it's widely known, but that explains why sentry health goes from 150 to 180 to 216).

A level 1 sentry has no built-in resistance to pootisman minigun boolets. Level 2 has 15%, level 3 has 20%.

Sentries can sometimes fire a bullet or two when in the process of redeploying and upgrading to the next level. They can't turn, however. The possibility of this is rare. For the best results, the angle difference between sentry viewpos and target origin must be less than 10 degrees.

One ammo piece equals one metal when repairing the sentry, one rocket equals two metal. 40 ammo and 8 rockets are added on each hit.

While restocking, sentries prioritize health first (up to 34 metal using the stock wrench or up to 27 using Jag), then they upgrade (if possible). After that they restock ammo and rocket (if ammo is full) reserves.

Sentry tracking and firing cone is a sphere with a 1100 hammer unit wide radius.

If a sentry is tracking a player and another player comes near, it won't attack that new player unless he gets 25% closer to the sentry.

If a sentry had acquired a spy as a target and the spy disguised while still in viewcone, it would keep shooting at the said spy even if he chooses to redisguise, until the spy leaves the sentry gun view cone.

Sentries can't shoot players through the water line. However, even if a slightest bit of player's feet is in the water, the sentry will shoot at him. I think this could be exploited in 2fort sewers by surfing off the pipe so that underwater sentries won't target you, but I've never tested this.

Probably already known: Level 1 sentries fire 5 times per second. Level 2/3 fire 10 times per second. Rockets are fired once per 3 seconds.

Level 1 sentries and mini-sentries contain a maximum of 150 ammo. Level 2/3 contain 200.

Level 3 sentries can have 20 rockets max.

You can destroy your sentry and other buildings using "destroy" command even when holding the said building. That could be useful combined with the sentry buster glitch (in MvM section above).

If the spy disguise process is below 50% (not yet disguised), the sentry will still track that spy.

Sentry gibs, and also gibs from other buildings take 30 second to despawn. And you can destroy them the same way as ammopacks.

- POOTISPENSER -

Dispenser base heal rate is 10 hp/s. Level 2 heals at 15/s, level 3 heals at 20/s.

Dispensers can store 400 metal and they can't heal more than 32 players simultaneously. The latter limit is kinda useless, though.

There is no limit on how many dispensers can a player heal off from.

Ammo dispenses occur at a rate of a single dispense per second and refills occur once per 6 seconds.

Kinda interesting: if the dispenser is already giving ammo to someone and another player shows up, there will be a 1-second (or less) delay before the new player can receive ammo from the dispenser. Health is dispensed almost instantly.

Dispenser healing cone is a box that expands to 70 units in all directions. The ammo dispense cone is a sphere with a 64-unit radius.

Dispenser can give ammo and metal through props and thin walls. The game does not check if the dispenser is actually visible to a particular player; however, when giving health the dispenser does the visibility checks.

- TELEPORTER -

In order to teleport, your velocity must be less than 5 HU/s. That's why crowding a teleporter usually does not work at all.

Telefrag "hitbox" has the same size as a player, except it stretches outwards just a little bit. So even if you were not touching the teleporting player, he can still telefrag you.

Zoomed-in snipers will have their zoom restored after a successful teleportation.

- CONSOLE COMMANDS -

Too much lag when traversing your backpack contents? Lower your tf_time_loading_item_panels value. Mine is set to 0.0001. Higher values result in faster loading, but the lag is unbearable sometimes.

More backpack stuff: use tf_backpack_page_button_delay to decrease "hover hold" time on page buttons when moving your items. Disable it for insta-switch (tf_backpack_page_button_delay 0).

Loadouts: use tf_item_selection_panel_sort_type 1 to alphabetically sort your loadout options.

For people out there who think that contract HUD element is annoying, tf_contract_progress_show 0 should do the trick. If you'd like to see only active contracts, use tf_contract_progress_show 2.

- DEEP-LEVEL STUFF ABOUT CONSOLE COMMANDS -

UNFINISHED.

Should probably do something about this section.

These were ripped directly from some popular FPS configs out there. I'm not trying to debunk these configs; rather I'm explaining what these commands actually do.

There are lots, lots of useful console commands that can make a huge performance benefit on a particular TF2 setup. This is just a small batch of them.

r_drawbatchdecals: Set to 1 to allow the engine to place several decals on a single mesh. Basically a memory/CPU tradeoff. Doesn't make much of a difference though, but I recommend to disable it if your max decal count is low.

r_spray_lifetime: Works just like it says on the tin: it's a maximum number of "decal wipes" (where all the decals get wiped from the map. It happens on a round start). After the nth wipe the player-placed sprays that already undergone (n-1) wipes will be removed too.

r_decal_cullsize: The game calculates the rough visible size of the decal each frame, and if that size is smaller than this cvar, the decal won't be rendered. You can disable most of decal rendering work by setting this value to 256 or more.

r_queued_decals: Gathers decal events in a queue and then releases the queue when necessary. Has a performance benefit if your max decal value is high, otherwise the benefit could be lost due to extra memory reads and CPU time + threading.

r_shadowmaxrendered: specifies how many visible shadows can be rendered in a single frame, basically an upper cap to the shadow count. This includes dynamic props too. Does nothing if r_shadows is set to 0. Competitive configs use 11 (all the players excluding you in a 6v6 format). HL players can use 17. Don't forget about the dynamic props though; I recommend leaving this at the default value or even increasing it to 64, so that all the rare cases when you see lots of props + weapons + players would be correctly calculated.

Could probably be the cause of weird lighting changes that some players experience.

r_shadowrendertotexture: Complicated. It is a high-end setting that switches the shadow manager to "render-to-texture" state. Your shadows will be better-looking, of course, but that's quite a big tradeoff. Eats quite a lot of memory, allocates two materials for each texture and stuff.

Some configs set it to 2 for some reason, that does the same as setting it to 1.

r_flashlightdepthtexture: High-end setting that allows depth-buffered shadows. A big performance hit, eats memory and GPU time.

r_shadows: Disables most of the operations in the shadow manager. Basically disables all the shadow-related stuff.

nb_shadow_dist: It's a NextBot thing which is entirely serverside, however, this one cvar is clientsided for some reason. Could be the shadow distance for robots and their corpses, I've never got around to finding out what it does.

r_eyes: Draws the eyes on TF characters and some NPCs. Does quite a lot, actually. It is a performance hit, but the game isn't as pleasant with characters having no eyeballs.

r_flex: Controls the morphing code. Can be offloaded to GPU by the game. Also a performance hit.

r_lod: Preferred level of detail in studio models. -1 is automatic, 0 - high, 1 - medium, 2 - low. Controls how the characters and props look like by locking LOD to a fixed value. Use 0 for the best possible quality, otherwise set it to -1. There is no need to set it to 1 or 2; use r_rootlod instead.

r_rootlod: The highest level of detail in studio models. 0 - high, 1 - medium, 2 - low. Set to 2 for the best performance benefit. If set to 1 or 2, it does not offload rendering to CPU, as many people say. It only clamps the highest LOD.

Some more explanations: if set to highest (0), the models will look like they should when they're close to you. As the distance increases, lower LODs come to play.

r_teeth: Who doesn't want to see the Heavy's wide and happy grin? Controls the vertex shader for character's teeth. Only does its calculations when the teeth is visible. Just a small performance hit compared to the eyes.

r_eyemove: No performance hit at all. Controls if the character eyes should move. Use tf_clientsideeye_lookats instead.

r_eyeshift_x, r_eyeshift_y, r_eyeshift_z: These three can fine-tune the eye position. No performance hit.

r_eyesize: Just like it says, an additional increase/decrease to the eye pupil size. No performance hit.

^ These five eye-related commands should be left at their default values; they do not change game performance at all.

blink_duration: Set it to 0 and get a nasty div by zero exception! Just kidding. It probably controls the character eye blinking loop time if there's any. The algorithm is kinda complicated, but it does not affect the performance at all. Leave this at default value.

In order to disable facial expressions and stuff, it's a much better idea to use these:

flex_rules 0

flex_smooth 0,

although I haven't tested it.

cl_ragdoll_fade_time: Controls the duration of the fade out effect on ragdolls. Set to 0 to instantly remove the ragdoll. Has a noticeable performance hit, eats CPU time as long as the ragdoll is still there.

cl_ragdoll_forcefade: Fade the ragdolls even if a local player is looking at them. If cl_ragdoll_fade_time is enabled, adds a small performance hit when disabled.

cl_ragdoll_physics_enable: Enables the interactive player ragdolls. HUGE performance hit as it's the base cvar for ragdoll-related stuff in TF2. Very noticeable in MvM.

cl_ragdoll_pronecheck_distance: Does not have xrefs, does nothing. Probably.

g_ragdoll_fadespeed: Controls how fast the ragdoll should fade out. No performance hit. The more the value, the faster the fade. Lots of configs set it to 0, but that does quite the opposite: either a small memory leak or a waste of CPU time. Leave it at default value, or set it to something like 10000 in order to instantly fade out the ragdoll. The default value of 600 fades the ragdoll in half a second.

g_ragdoll_lvfadespeed: Same as g_ragdoll_fadespeed, but this one is used if the low violence mode (hence the LV abbreviation) is enabled. Better to leave it at default.

^ These two were probably changed in Tough Break update to avoid that memory leak. Not sure about that. Too lazy to check.

ragdoll_sleepaftertime: How long the ragdoll should lie still on the ground before being considered "asleep". Not much of a performance hit, however weird (and fun!) effects can start to show with this being set to 0. You can leave this one at default, 5 is a good round value, or set it to 2.5 for a small performance boost.

g_ragdoll_maxcount: How many ragdolls can be active at any given time. You can safely decrease it to 2 or 4 for a quick performance boost. In order to disable ragdolls entirely, it's better to use cl_ragdoll_physics_enable. Noticeable in MvM. You can also set it to 24 so the drop-down will be literally filled with robot bodies. That is neat.

cl_phys_props_enable: If set to 1, the game parses and creates the client-side physics props on the start of a level. The server-side props aren't affected: these include ammo boxes, sentry gibs and cones on Mannhattan (yay for cones). More testing should be done, but I think you can safely disable it. And this has a performance penalty too even if there are no client-side phys props.

cl_phys_props_max: How many phys props can be active at any given time. Does nothing if phys props are disabled.

r_propsmaxdist: The maximum allowed visible distance for these client-side props. At 75% of this distance the prop starts to slowly fade.

cl_phys_props_respawndist: As it seems, some props can also respawn. (Maybe barrels on Dustbowl? Not sure). This controls the minimum distance on which the prop is allowed to respawn. In order for a prop to respawn, it should not be in player's viewcone and it should be farther than that distance.

cl_phys_props_respawnrate: How often to fire respawn events for said props.

^ I think you shouldn't change these four cvars, they're redundant if phys props are disabled, and even if they are enabled, the only cvar worth changing is cl_phys_props_max.

props_break_max_pieces: How many maximum gibs should a breakable prop produce. This works both for gibs and for static props. Sentry gibs are server-controlled and so this cvar does nothing regarding them.

violence_agibs, violence_ablood: Whether to show alien gibs and blood. This dates back to HL1. Alien gibs/blood do not work in TF2 and so these cvars are outdated. You can disable them just to be sure.

violence_hgibs: If set to 1, default bloody gibs will appear. If set to 0, these gibs are replaced by "silly gibs". Silly gibs can actually affect your performance more, because they are produced in greater numbers. If you have ragdolls disabled, set this to 0, otherwise leave it at 1.

violence_hblood: Whether or not to show blood. Affects performance, but only a little bit.

cl_burninggibs: Does what it says - gib deaths of burning players will produce burning gibs. Quite big of a performance hit.

That is all! Well, at least in this guide. There are others right here.