#1: Overall code reviewed and uniformized, teleport function added,
slope effect added.