Twice Upon a Time (1983)
In the world of the Murkworks where nightmares are made, the evil Synonamess Botch hatches a scheme to make non-stop nightmares. Only Ralph and Mumford, misfits from the cheery land of Frivoli where good dreams are made, can stop him.