Just write. Put all your ideas on paper/midi/whatever. Writing is a process which consists of everything that might eventually lead you to the result. Write down even the shittiest idea you come up with. Writing can be in a way, a "collaborative process" even if you do it alone. The shitty riff might inspire you to write a second riff, which might be the awesomest riff ever. Maybe you'll come up with a weak melody idea, what will eventually inspire you to write a great chord progression. The end result can be magical and full of emotion even when the process of doing it isn't. You don't have to wait for the inspiration. Just do it. A great song is a result of determined work. Put aside your self-criticism and enjoy the process. Decide to come up with great ideas and write contigously and succeeding will become inevitable.
Work on your skill to translate the ideas in your head to music with your ideas. If you can come up with musical ideas in your head, but can't actualize them with an instrument, just slow things doing. Try to sing the melody, play it with a differen't instrument. You'll find it sooner or later.
You might also find this video helpful:
http://www.youtube.com/watch?v=ijtQP9nwrQA