Find the key, play the major or minor scale that fits. Use accidentals wherever and that's about it.
And no, Guitar Hero will not help. Even on expert. Really.
Listen to your favorite guitar solos and learn to play them. Get a good ear, try to hear melodies in your head and play them on your guitar. And yeah, know the backing track well.

A good solo is not just a bunch of licks thrown together. It needs to have a good flow.
Quote by AlanHB
Just remember that there are no boring scales, just boring players.


Bach Stradivarius 37G
Charvel So Cal
Fender Dimension Bass
Hartke HyDrive 210c
Ibanez BL70
Laney VC30
Tokai TB48
Yamaha FG720S-12
Yamaha P115
No offense, but didn't we already give you a bunch of tools in another thread? Yes, that was in only one key, but take the tools we gave you, generalize them, and then apply them to whatever key you want. No one is going to spoon-feed you here.