I love melodies!
A great place to start learning the basics is
http://www.musictheory.net/Another good resource as far as I've checked is
http://musictheoryblog.blogspot.com/You might have to go over things a couple of times, but the bottom line is you've gotta learn it one way or another.
Once you've got a good foundation, counterpoint can be a great tool for writing melodies. Put too simply, it's writing with multiple voices.
http://en.wikipedia.org/wiki/Counterpoint sets the rules of counterpoint out straight and to the point.
Our beloved Dr. Dissonance wrote up a thread on counterpoint that you may find valuable here:
http://mylittleremix.com/viewtopic.php?f=13&t=5110Great melodies generally don't jump around very often. At maximum you really won't be wanting to jump more than a 6th, and not often if you do choose to do so.
Also avoid parallel 5ths and 8ths at all costs, as they grate against the ear. Some ways to avoid them are choosing different inversions of the chord or choosing a new chord altogether.
An easy-peasy super-lazy way of staying in consonance (at least in FL) is to flesh out the chords on the piano roll and extend them an octave above and below. Open another piano roll so the chords from the 1st are ghosted, and then you can place notes anywhere the ghost bricks are, and you'll never go dissonant!
Following theory knowledge, you can build up a melody systematically regardless of inspiration. I can't really relate to or promote goofing around randomly with a keyboard to be a solid way to make a great melody. If the melody seems nice but seems to be missing the magic, change up the timing and put some drive/groove into it! Dot the notes, stutter, syncopate. Just whatever it takes to give it the drive it needs.
If you have anything more specific, I'd be glad to help where I can!