2.5D Pen Platformer hacked
@Stage\n\nwhen flag clicked\nforever\n    if <(level) = [2]> then\n        switch backdrop to (backdrop2 v)\n    else\n        switch backdrop to (backdrop1 v)\n    end\nend\n\n@Pen Platformer \n\ndefine end\ncreate platform [-240] [-150] [10] [90] [480] [1] [33]\ncoin [200] [-60]\ncoin [150] [-60]\ncoin [100] [-60]\ncoin [-200] [-60]\ncoin [-150] [-60]\ncoin [-100] [-60]\ncoin [-50] [-60]\ncoin [0] [-60]\ncoin [50] [-60]\ncoin [200] []\ncoin [150] []\ncoin [100] []\ncoin [-200] []\ncoin [-150] []\ncoin [-100] []\ncoin [-50] []\ncoin [0] []\ncoin [50] []\n\ndefine level3\ncoin [720] [150]\ncoin [720] [50]\ncoin [720] [250]\ncoin [1350] [30]\ncoin [1150] [-150]\ncoin [1450] [-160]\ncreate platform [-240] [-100] [10] [90] [300] [1] [10]\ncreate platform [60] [-100] [10] [70] [230] [1] [15]\ncreate platform [280] [-60] [10] [80] [230] [1] [20]\ncreate platform [520] [-20] [10] [50] [230] [1] [25]\ncreate platform [700] [-100] [10] [90] [100] [2] [16]\ncreate platform [1000] [-100] [10] [90] [100] [1] [60]\ncreate platform [1100] [-100] [10] [0] [100] [1] [70]\ncreate platform [1100] [0] [10] [90] [100] [1] [80]\ncreate platform [1100] [-200] [10] [90] [200] [1] [90]\ncreate platform [1300] [-200] [10] [0] [100] [1] [10]\ncreate platform [1400] [-200] [10] [90] [100] [1] [10]\ncreate platform [1300] [0] [10] [0] [100] [1] [20]\ncreate platform [1300] [-100] [10] [90] [100] [1] [30]\ncreate platform [1300] [0] [10] [90] [100] [1] [40]\ncreate platform [1300] [100] [10] [90] [300] [1] [50]\ncreate platform [1600] [0] [10] [90] [100] [1] [60]\ncreate platform [1700] [100] [10] [90] [100] [1] [70]\ncreate platform [1900] [200] [10] [180] [100] [1] [10]\ncreate platform [1800] [100] [10] [0] [100] [1] [80]\ncreate platform [1800] [200] [10] [90] [100] [1] [90]\ncreate platform [1900] [100] [10] [90] [100] [1] [20]\ncreate platform [2000] [100] [10] [0] [100] [4] [30]\n\ndefine draw light\ngo to x: ((x) - (camx)) y: ((y) - (camy))\nset pen size to ((185) + ((18) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\nset pen color to (#f9ffdc)\npen down\npen up\nset pen size to ((150) + ((16) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\nset pen color to (#ffffff)\npen down\npen up\nset pen size to ((100) + ((10) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\nset pen color to (#ffdebb)\npen down\npen up\nset pen size to ((80) + ((8) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\nset pen color to (#ffcc94)\npen down\npen up\n\ndefine draw coins\nset [loops v] to [1]\nrepeat (length of [coin x v])\n    go to x: ((item (loops) of [coin x v]) - (camx)) y: ((item (loops) of [coin y v]) - (camy))\n    set pen size to ((35) + ((5) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\n    set pen color to (#f9ffdc)\n    pen down\n    pen up\n    set pen size to ((28) + ((5) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\n    set pen color to (#ffffff)\n    pen down\n    pen up\n    set pen size to ((15) + ((3) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\n    set pen color to (#ffca8d)\n    pen down\n    pen up\n    set pen size to ((10) + ((3) * ([sin v] of (((timer) * (100)) + ((loops) * (30))) )))\n    set pen color to (#ffad52)\n    pen down\n    pen up\n    if <<([abs v] of ((item (loops) of [coin x v]) - (x)) ) < [20]> and <([abs v] of ((item (loops) of [coin y v]) - (y)) ) < [35]>> then\n        if <(level) < [4]> then\n            change [coin v] by (1)\n        end\n        delete (loops) of [coin x v]\n        delete (loops) of [coin y v]\n        repeat (10)\n            create clone of (_myself_ v)\n        end\n    end\n    change [loops v] by (1)\nend\n\nif <(level) = [1]> then\n    set [clouds - y v] to [120]\nelse\n    set [clouds - y v] to [180]\nend\ncloud ((60) + (clouds - x)) (clouds - y)\ncloud ((600) + (clouds - x)) (clouds - y)\ncloud ((1000) + (clouds - x)) (clouds - y)\ncloud ((2000) + (clouds - x)) (clouds - y)\nchange [clouds - x v] by (-1)\n\ndefine create platform (x) (y) (size) (dir) (length) (type) (colors)\nadd (x) to [x v]\nadd (y) to [y v]\nadd (type) to [type v]\nadd (length) to [length v]\nadd (dir) to [dir v]\ncreate platform [] [] [] [] [] [] []\nadd (colors) to [color v]\nend\n\ndefine flag (y) (x) (type)\ncreate platform (x) ((y) + (100)) [12] [135] [40] (type) []\ncreate platform (x) (((y) + (100)) - ((80) / ([sqrt v] of (2) ))) [12] [45] [40] (type) []\ncreate platform (x) (y) [12] [0] [100] (type) []\n\ndefine load level\ndelete all of [coin x v]\ndelete all of [coin y v]\ndelete all of [color v]\ndelete all of [x v]\ndelete all of [y v]\ndelete all of [length v]\ndelete all of [dir v]\ndelete all of [type v]\ndelete all of [size v]\nif <(level) = [1]> then\n    level1\nelse\n    if <(level) = [2]> then\n        level2\n    else\n        if <(level) = [3]> then\n            level3\n        else\n            end\n        end\n    end\nend\n\ndefine special detections\nupdate\nif <[touching v] contains [2]?> then\n    set [xv v] to (() - (([cos v] of (touching_dir) ) * (40)))\n    if <([sin v] of (touching_dir) ) > [0]> then\n        if <(yv) < [0]> then\n            set [yv v] to [0]\n        end\n        change [yv v] by (23)\n        change [y v] by (20)\n    else\n        if <[0] > ([sin v] of (touching_dir) )> then\n            set [yv v] to [-40]\n        end\n    end\nend\nif <<[touching v] contains [3]?> or <(y) < [-300]>> then\n    set [clouds - x v] to [0]\n    set [x v] to [-100]\n    set [y v] to [0]\n    set [xv v] to [0]\n    set [yv v] to [0]\n    set [loops v] to [1]\n    repeat (length of [moving platform v])\n        replace item (item (loops) of [moving platform v]) of [x v] with ((item (item (loops) of [moving platform v]) of [x v]) - (move - x))\n        change [loops v] by (1)\n    end\n    set [move - x v] to [0]\n    set [move - xv v] to [4]\n    delete all of [px v]\n    delete all of [py v]\nend\nif <[touching v] contains [4]?> then\n    win\nend\n\ndefine Hill detection\nupdate\nrepeat (10)\n    if <[touching v] contains [1]?> then\n        change [y v] by (1)\n        update\n    end\nend\nif <[touching v] contains [1]?> then\n    change [y v] by (-10)\n    change [x v] by ((xv) * (-1))\nend\n\nwhen I start as a clone\nset pen size to (14)\nset [clone-x v] to ((camx) + (x position))\nset [clone-y v] to ((camy) + (y position))\nset [clone - xv v] to (pick random (-7) to (7))\nset [clone - yv v] to (pick random (8) to (14))\nset pen color to (#ffe0bf)\nforever\n    go to x: ((clone-x) - (camx)) y: ((clone-y) - (camy))\n    change [clone-x v] by (clone - xv)\n    change [clone-y v] by (clone - yv)\n    change [clone - yv v] by (-1)\n    pen down\n    pen up\n    if <(clone-y) < [-180]> then\n        delete this clone\n    end\nend\n\ndefine coin (x) (y)\nadd (x) to [coin x v]\nadd (y) to [coin y v]\n\ndefine update moving platform position \nchange [move - x v] by (move - xv)\nif <(move - x) < [0]> then\n    set [move - xv v] to [4]\nend\nif <[240] < (move - x)> then\n    set [move - xv v] to [-4]\nend\nset [loops v] to [1]\nrepeat (length of [moving platform v])\n    replace item (item (loops) of [moving platform v]) of [x v] with ((item (item (loops) of [moving platform v]) of [x v]) + (move - xv))\n    change [loops v] by (1)\nend\n\ndefine cloud (x) (y)\nset pen size to (15)\ngo to x: ((x) - (camx)) y: ((y) - (camy))\nset pen color to (#ffffff)\npen down\nchange x by (100)\npen up\nchange x by (-25)\npen down\nchange y by (30)\npen up\nchange x by (-30)\npen down\nchange x by (80)\npen up\n\ndefine clouds\n\ncreate platform [140] [-100] [10] [0] [200] [1] []\ncreate platform [240] [-88] [10] [90] [36] [2] []\ncreate platform [300] [-88] [10] [90] [200] [3] []\ncreate platform [600] [-100] [10] [0] [120] [1] []\ncreate platform [740] [-100] [10] [0] [120] [1] []\ncreate platform [600] [20] [10] [90] [140] [1] []\ncreate platform [800] [130] [8] [90] [100] [6] []\ncreate platform [800] [130] [8] [180] [30] [6] []\ncreate platform [800] [100] [8] [90] [100] [6] []\ncreate platform [900] [130] [8] [180] [30] [6] []\n\ndefine level2\ncoin [230] [-50]\ncoin [1065] [-45]\ncreate platform [-240] [-100] [10] [90] [940] [1] []\ncreate platform [160] [-100] [10] [0] [100] [1] []\ncreate platform [300] [-100] [10] [0] [100] [1] []\ncreate platform [800] [-40] [10] [90] [50] [1] []\ncreate platform [950] [0] [10] [90] [30] [1] []\ncreate platform [1100] [-90] [10] [90] [45] [1] []\ncreate platform [1260] [-160] [10] [90] [200] [1] []\ncreate platform [1500] [-100] [40] [90] [0] [4] []\n\ndefine level1\ncoin [2020] [50]\ncoin [2220] [50]\ncoin [-100] [100]\ncoin [223] [-100]\ncoin [323] [-20]\ncoin [423] [-100]\ncreate platform [-240] [-150] [10] [90] [800] [1] [33]\ncreate platform [-240] [-150] [10] [0] [600] [1] [33]\ncreate platform [160] [-150] [10] [0] [400] [1] [33]\ncreate platform [160] [-50] [10] [-90] [100] [1] [33]\ncreate platform [60] [50] [10] [-90] [100] [1] [33]\ncreate platform [160] [150] [10] [-90] [100] [1] [33]\ncreate platform [620] [-40] [80] [] [] [1] [9]\ncreate platform [770] [0] [60] [] [] [1] [9]\ncreate platform [900] [-70] [70] [] [] [1] [9]\ncreate platform [1060] [-140] [10] [90] [200] [1] [33]\ncreate platform [1260] [-140] [10] [60] [200] [1] [33]\ncreate platform [1460] [10] [10] [90] [200] [1] [33]\ncreate platform [1660] [10] [10] [90] [100] [3] [0]\ncreate platform [1770] [10] [10] [90] [100] [1] [33]\ncreate platform [1870] [10] [10] [0] [100] [1] [33]\ncreate platform [1970] [10] [10] [90] [100] [1] [33]\ncreate platform [1970] [10] [10] [0] [100] [1] [33]\ncreate platform [1870] [110] [10] [90] [100] [1] [33]\ncreate platform [2070] [10] [10] [0] [200] [1] [33]\ncreate platform [2170] [10] [10] [0] [200] [1] [33]\ncreate platform [2070] [210] [10] [90] [100] [1] [33]\ncreate platform [2170] [10] [10] [90] [100] [1] [33]\ncreate platform [2270] [10] [10] [0] [100] [1] [33]\ncreate platform [2370] [10] [10] [0] [100] [1] [33]\ncreate platform [2370] [10] [10] [90] [100] [1] [33]\ncreate platform [2270] [110] [10] [90] [100] [1] [33]\ncreate platform [2470] [10] [10] [0] [100] [4] [80]\n\ndefine win\nset [move - x v] to [0]\nset [move - xv v] to [4]\nset [clouds - x v] to [0]\nchange [level v] by (1)\nload level\nset [x v] to [-100]\nset [y v] to [0]\ndelete all of [px v]\ndelete all of [py v]\n\nwhen [s v] key pressed\nif <(level) < [4]> then\n    win\nend\n\ndefine camera \nchange [camx v] by (((x) - (camx)) / (5))\nchange [camy v] by ((((y) - (camy)) - (-50)) / (5))\nif <(camy) < [-40]> then\n    set [camy v] to [-40]\nend\nif <(camx) < [0]> then\n    set [camx v] to [0]\nend\n\nwhen flag clicked\nswitch costume to (costume1 v)\nset size to (5000) %\nswitch costume to (costume2 v)\n\nwhen flag clicked\nshow variable [- v]\ndelete all of [color v]\ndelete all of [type v]\ndelete all of [x v]\ndelete all of [y v]\ndelete all of [length v]\ndelete all of [dir v]\ndelete all of [size v]\ndelete all of [moving platform v]\nset [coin v] to [0]\nset [camx v] to [0]\nset [camy v] to [0]\nset [level v] to [1]\nset [x v] to [-100]\nset [y v] to [0]\nset [yv v] to [0]\nset [done_create_line v] to [0]\nset [level v] to [0]\nwin\nforever\n    clouds\n    up-down movement\n    Left-right movement\n    special detections\n    Hill detection\n    camera \n    draw player\n    Make list\n    update moving platform position \n    if <(level) = [4]> then\n        set [- v] to (join (coin) [/14 \(the end\)])\n    else\n        set [- v] to (join (coin) [/14])\n    end\nend\n\ndefine draw player\nerase all\nif <(level) = [2]> then\n    draw light\nend\nset [loops v] to [0]\nrepeat (length of [dir v])\n    change [loops v] by (1)\n    draw line (item (loops) of [x v]) (item (loops) of [y v]) (item (loops) of [length v]) (item (loops) of [dir v]) (item (loops) of [size v]) (item (loops) of [type v]) (item (loops) of [color v])\nend\nset pen color to (#ff9400)\nset pen size to (25)\nset [trail-pos v] to [1]\nset pen (saturation v) to (50)\nset pen (saturation v) to (50)\nrepeat (length of [px v])\n    go to x: ((item (Trail-pos) of [px v]) - (camx)) y: ((item (Trail-pos) of [py v]) - (camy))\n    change y by (4)\n    pen down\n    pen up\n    change [trail-pos v] by (1)\n    change pen (saturation v) by ((50) / (length of [px v]))\nend\ngo to x: ((x) - (camx)) y: ((y) - (camy))\nchange y by (4)\npen down\npen up\nchange x by ((5) + ((xv) / (2)))\nchange y by (5)\nset pen size to (8)\nset pen color to (#ffffff)\npen down\npen up\nset pen size to (4)\nset pen color to (#2b2b2b)\npen down\npen up\nchange x by (-10)\nset pen size to (8)\nset pen color to (#ffffff)\npen down\npen up\nset pen size to (4)\nset pen color to (#2b2b2b)\npen down\npen up\ndraw coins\n\ndefine update\ndelete all of [touching v]\nset [loops v] to [0]\nrepeat (length of [dir v])\n    change [loops v] by (1)\n    set [x2 v] to ((item (loops) of [x v]) + (([sin v] of (item (loops) of [dir v]) ) * (item (loops) of [length v])))\n    set [y2 v] to ((item (loops) of [y v]) + (([cos v] of (item (loops) of [dir v]) ) * (item (loops) of [length v])))\n    set [dot v] to (((((x) - (item (loops) of [x v])) * ((x2) - (item (loops) of [x v]))) + (((y) - (item (loops) of [y v])) * ((y2) - (item (loops) of [y v])))) / ((item (loops) of [length v]) * (item (loops) of [length v])))\n    set [closestx v] to ((item (loops) of [x v]) + ((dot) * ((x2) - (item (loops) of [x v]))))\n    set [closesty v] to ((item (loops) of [y v]) + ((dot) * ([abs v] of ((y2) - (item (loops) of [y v])) )))\n    set [distx v] to ((x) - (closestx))\n    set [disty v] to ((y) - (closesty))\n    set [dotdist1 v] to ([sqrt v] of ((((closestx) - (item (loops) of [x v])) * ((closestx) - (item (loops) of [x v]))) + ([abs v] of (((closesty) - (item (loops) of [y v])) * ((closesty) - (item (loops) of [y v]))) )) )\n    set [dotdist2 v] to ([sqrt v] of ((((closestx) - (x2)) * ((closestx) - (x2))) + (((closesty) - (y2)) * ((closesty) - (y2)))) )\n    set [dotdist v] to ((dotdist1) + (dotdist2))\n    if <<([sqrt v] of (((distx) * (distx)) + ((disty) * (disty))) ) < (((item (loops) of [size v]) * (0.3)) + (16))> and <([abs v] of ((dotdist) - (item (loops) of [length v])) ) < ((item (loops) of [size v]) * (2))>> then\n        add (item (loops) of [type v]) to [touching v]\n        if <(item (loops) of [type v]) = [2]> then\n            set [touching_dir v] to (item (loops) of [dir v])\n        end\n    end\nend\n\ndefine Make list\nadd (x) to [px v]\nadd (y) to [py v]\nif <(length of [px v]) > [5]> then\n    delete (1) of [px v]\nend\nif <(length of [py v]) > [5]> then\n    delete (1) of [py v]\nend\n\ndefine up-down movement\nchange [y v] by (-1)\nupdate\nif <not <<[touching v] contains [1]?> or <[touching v] contains [6]?>>> then\n    change [yv v] by (-1)\nend\nif <<[touching v] contains [1]?> or <[touching v] contains [6]?>> then\n    change [y v] by (1)\n    update\n    if <<(yv) < [0]> or <(yv) = [0]>> then\n        repeat until <not <<[touching v] contains [1]?> or <[touching v] contains [6]?>>>\n            change [y v] by (1)\n            update\n        end\n        set [yv v] to [0]\n        change [y v] by (-1)\n        if <<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > [50]>>> then\n            set [yv v] to [15]\n            change [y v] by (5)\n        end\n    else\n        change [y v] by (-1)\n        change [y v] by ((yv) * (-1))\n        set [yv v] to [0]\n    end\nend\nchange [y v] by (yv)\nupdate\n\ndefine draw line (x) (y) (len) (dir) (size) (type) (color)\nset pen (transparency v) to (0)\nset pen (brightness v) to (50)\nif <(level) = [2]> then\n    set pen (brightness v) to (-100)\nend\nset pen (saturation v) to (100)\nset pen (color v) to (color)\nset [draw-y v] to [0.8]\nrepeat (10)\n    go to x: (((x) - (camx)) * (draw-y)) y: (((y) - (camy)) * (draw-y))\n    set pen size to (size)\n    point in direction (dir)\n    pen down\n    move ((len) * (draw-y)) steps\n    pen up\n    change [draw-y v] by (0.02)\n    change pen (brightness v) by (2)\n    if <(level) = [2]> then\n        change pen (brightness v) by (-2)\n    end\nend\n\ndefine Left-right movement\nif <<key (left arrow v) pressed?> or <<mouse down?> and <(mouse x) < [-50]>>> then\n    change [xv v] by (-1)\nend\nif <<key (right arrow v) pressed?> or <<mouse down?> and <(mouse x) > [50]>>> then\n    change [xv v] by (1)\nend\nset [xv v] to ((xv) * (0.9))\nchange [x v] by (xv)\nupdate\n\n@Sprite1\n\nwhen flag clicked\nhide\n\n