Spy is probably one of the harder TF2 classes; it's hard in that good spies have set the bar already and the enemy team is already on the lookout for you, it's hard in that once you're spotted you have very little chance of surviving, it's hard in that there aren't really any transferable skills from other FPSs and you have to learn it from scratch, and it's hard to use your class to make an actual difference.
But in the hands of a pro, the spy is absolutely the most annoying and effective class in the game. Here are some things I've picked up:
The stock load-out is good. Really! Sure, the dead ringer can be really annoying to play against, but experienced players can spot a fake DR death easily, you're still useless against pyros, and the stock Invis Watch gives you cloak-on-demand, which is very useful. Overall I'd say the IW is a lot less forgiving, so it forces you to be careful and it's therefore good to learn with. The other weapons are more simple preference, I think.
TF2's weapon balance system is very good - stock or non-stock weapons are almost never direct upgrades (apart from the medic's melee choices). The IW is more about prevention than cure, and the DR is more about cure than prevention. In highly spammy circumstances, the DR is an advantage, but generally, the IW is fine.
Play with other loadouts if you want (and when you get comfortable), but you should definitely not dismiss the defaults.
Plenty of newbie spies are completely obvious even before they do anything.
- What you're trying to do is get behind the whole enemy team, as this gives you a safer and more effective attack position. Some enemies are completely happy to let you co-exist with them as long as you don't wander in from the front.
- Your basic objective should be to cloak just before the front lines, then to get as far behind them as possible while cloaked (pick up ammo packs along the way to keep your cloak from running out).
- People can use bumping into you as a method of spychecking. Therefore it's best to prevent them from getting particularly close to you, and to do so naturally, it means gently evading them as soon as possible, not suddenly changing direction when they get close to you.
- If someone does start shooting at you, if they aren't so likely to actually hit you, just keep going. They might be spy-checking, which means they're looking for a reaction of some kind. That means either damaging you or making you do something out of the ordinary. If they aren't too likely to damage you, take the risk and assume they won't. If they miss a few times there's a good chance they won't pursue you, either because they lose interest or they assume that since you didn't break cover that you really are one of them.
- At the start of the round (during setup time) and when approaching the lines, it's good practice to avoid alerting the enemy team to your presence as a spy. That's what friendly disguises are for (press '-' on the disguise selector). Someone who's just seen a spy approaching will be more likely to spycheck than someone who hasn't
- Some classes make for bad disguises. Eg: scout (you're too slow, you'll be noticed) and medic (you can't heal, people will get suspicious). Other classes depend more on situation; e.g. engineer is bad if you're in a situation where you'd be expected to be putting up a sentry, but okay if you want to run around behind their lines without them thinking much about it.
- Further to the last point, it's generally a good idea to avoid disguising as any class the other team doesn't have, so keep aware of their class distribution.
- B is a shortcut for reapply last disguise. Use it when you've broken cover and need to disappear quickly.
- Your main enemy is the pyro, obviously. You also have to watch out for good medics, who should be hyper-alert for you, and you also have to be careful about accidentally taking explosive damage that wasn't intended for you (so don't run in front of a demoman).
- Chain-stabs are great, but don't start in the middle. Even if you're tempted by the idea of two quick and easy stabs, don't go for it if there's a soldier behind you. Being a spy is all about discipline, not just taking the first kill that comes to you.
- When rumbled, cloak as soon as you can and then run somewhere completely unpredictable. Don't stand in the nearest corner, demomen love this.
- Don't be worried to abort an attack if the situation changes and you think it'll go wrong. The spy is extremely vulnerable in the open and you're no use dead.
- Engineers and sentry nests make tempting targets, but you have to assess whether they're worth it. If all you manage to do is plant a sapper and die then they'll instantly remove it and you'll have died for nothing. Sometimes a well placed sentry nest is best left to a demoman.
- After a while, people will start spychecking everyone no matter how convincingly you're acting. In these situations it becomes more a game of getting behind someone before they can see you, which means being very smart with cloak/decloak and appearing from around corners
So okay, you're now not dying too much, but how can you be useful to your team?
- The main idea of the spy is to take down difficult targets, not to get tonnes of kills.
- Snipers are easy targets for a spy, but hard for the rest of the team so definitely focus on snipers. If they have a razorback, no problem, just wait until they're scoped then shoot them with your revolver.
- A sentry nest is a difficult target. Some of these will be out of your ability due to the positioning the engineer sets up, but others can be okay. If you're fast, you can backstab an engineer and set the sapper on his sentry before the sentry targets you. You'll need to practice the weapon switching, though.
- Sometimes engineers who set up otherwise well will be vulnerable to telefragging. And if not, using their teleporter can sometimes get you behind them and give you a better attack
- Medic/heavy pairs are very important targets. You might be able to chainstab both, but if not, the medic is probably the more sensible target; heavies attract bullets so quickly that they don't live long without a medic, and the medic's ubercharge is always worth resetting. But it's situation dependent - go for whichever one presents the best chances of success.
- Your knife is immensely powerful, but only from behind. A pretty neat trick is to run up some stairs with an enemy following you and then at the top jump backwards over their head (jump-crouch), and backstab them
- When you're feeling confident being disguised and not having to kill everyone, try to get an enemy medic to waste his ubercharge on you. Adopt a combat class disguise (heavy/soldier/demoman, in that order), rush out to the front of their lines and yell 'MEIDC' a few times. When you've got an enemy medic healing you and he has his uber ready, start heading out towards your own lines.