properly working version of spawn_lens