There have been many times when I was sitting with a guitar, waiting for my Muse, and the wench done stood me up. I think the only thing to do is endeavor to persevere.
That said, I have also found certain things that sometimes help to jolt me out of my rut (or downward spiral) and put me on a new (sometimes more fruitful) track.
Maybe try putting on an album you like and playing along with it, front to back, every track, repeatedly, until your contribution (whether you're doing backing rhythms, screaming leads or whatever) starts to sound like you're actually part of the band, and adding something to the songs. I don't mean try to duplicate or copy what the other guys are doing; I mean just riff along and do what YOU feel, play your own part, and add it to what they're doing. On occasion, I've done this for up to three or four weeks with a single album, every spare minute I could scratch out of each day. What I found over time was that it made me a much, much better guitar player, not only technically more proficient, but much more tuned in to what all the other parts were doing and how I could find something to weave into the mix. And in turn that gave me both increased confidence and a deeper approach to the creative process of making music.
Another trick I've found useful on many occasions: think of some song you're very familiar with, at least as a listener, even if you haven't ever played it. Then sit down all alone in a quiet room (don't put the song on the stereo) and do a quick run through of the chord structure of that song. And then, noodle around and take an entirely different approach to that song, some style you've never heard anyone do it in before. For example, maybe take the Beatles' "Let It Be" and work it to a reggae beat, or slow it down and turn it into a more delta-blues number, or maybe change the time signature and try it in waltz time, or whatever. Just play around with different approaches to familiar songs, things that are completely off-the-wall. You'll spend a lot of time screwing around, and not hearing anything cool. But every now and then, you'll stumble onto something that clicks, even if just a little bit, and it can spark ideas and approaches you hadn't thought of before. Then you can let that guide you into a new direction for your own songwriting. An awful lot of great songs are similar in chord structure to other great songs, but done with different rhythms, different tempos, different styles, sufficiently different emphasis, that they become something different in their own right. Take the chord progression of a song you like and reverse it, or reverse parts of it, or stay on one chord longer and another chord less time, or alter a major into a minor. Just noodling around with stuff like that, not really trying to force it, but just plunking around and listening for something that catches your ear, can be a great way to spend an evening. The great majority of the time you spend doing that won't lead immediately to a new song, but the time is never "wasted" because you're getting in exercise with your hands on the strings, you're getting more fluent with the instrument's voice, you're (even if only subconsciously) developing your own personal style, and you're (even if only subconsciously) storing away in your mind little pieces of riffs, progressions and ideas that might very well lead -- eventually -- to a cool song.
The main thing is, don't give up, and don't lose patience. If you're getting too frustrated, take a break for a day or two, but get back to it, and keep plunking away. Eventually, the Muse will arrive, and when she does, she'll make you forget all about the nights she stood you up.