Improved Platformer Engine

Instructions: Arrow Keys\n\nLook inside for the code, I've put a script which does not support Wall Jumping as well.

@Stage\n\n@Sprite1\n\nwhen flag clicked\nset [wall jumping? v] to []\nset [lvl v] to [0]\nhide list [typewrite v]\ngo to x: (-88) y: (-9)\nswitch backdrop to (backdrop2 v)\nAsk [Do you want Wall Jumping enabled? \(Y or N\)]\nif <(answer) = [y]> then\n    set [wall jumping? v] to [Yes]\n    broadcast (yes v)\n    show list [typewrite v]\nelse\n    if <(answer) = [n]> then\n        set [wall jumping? v] to [No]\n        broadcast (no v)\n        show list [typewrite v]\n    end\nend\n\ndefine Ask (ask)\nSay (ask)\nask [] and wait\n\ndefine Say (say)\ndelete (all) of [typewrite v]\nset [la v] to [0]\nset [wigts v] to []\nrepeat (length of (say))\n    change [la v] by (1)\n    set [wigts v] to (join (Wigts) (letter (la) of (say)))\n    add (Wigts) to [typewrite v]\n    delete ((length of [typewrite v]) - (1)) of [typewrite v]\nend\n\n@Sprite2\n\nwhen flag clicked\nhide\n\nwhen I receive [yes v]\nshow\nswitch backdrop to (backdrop1 v)\ngo to x: (-195) y: (-22)\nset [x v] to [0]\nset [y v] to [0]\nset rotation style [left-right v]\npoint in direction (90)\nforever\n    change [y v] by (-1)\n    if <key (right arrow v) pressed?> then\n        change [x v] by (1)\n        point in direction (90)\n    end\n    if <key (left arrow v) pressed?> then\n        change [x v] by (-1)\n        point in direction (-90)\n    end\n    set [x v] to ((x) * (0.9))\n    change x by (x)\n    if <touching color (#000000)?> then\n        change y by (1)\n        if <touching color (#000000)?> then\n            change y by (1)\n            if <touching color (#000000)?> then\n                change y by (1)\n                if <touching color (#000000)?> then\n                    change y by (1)\n                    if <touching color (#000000)?> then\n                        change y by (1)\n                        if <touching color (#000000)?> then\n                            change x by ((x) * (-1))\n                            change x by (-1)\n                            change y by (-5)\n                            change x by (1)\n                            if <key (up arrow v) pressed?> then\n                                if <(x) > [0]> then\n                                    set [x v] to [-10]\n                                else\n                                    set [x v] to [10]\n                                end\n                                set [y v] to [10]\n                            else\n                                set [y v] to [0]\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change y by (y)\n    if <touching color (#000000)?> then\n        change y by ((y) * (-1))\n        set [y v] to [0]\n    end\n    change y by (-1)\n    if <touching color (#000000)?> then\n        if <key (up arrow v) pressed?> then\n            set [y v] to [15]\n        end\n    end\n    change y by (1)\n    if <touching color (#ff0000)?> then\n        go to x: (-210) y: (151)\n    end\n    if <touching color (#00cccc)?> then\n        set [y v] to [20]\n    end\nend\n\nwhen I receive [no v]\nshow\nswitch backdrop to (backdrop1 v)\ngo to x: (-195) y: (-22)\nset [x v] to [0]\nset [y v] to [0]\nset rotation style [left-right v]\npoint in direction (90)\nforever\n    change [y v] by (-1)\n    if <key (right arrow v) pressed?> then\n        change [x v] by (1)\n        point in direction (90)\n    end\n    if <key (left arrow v) pressed?> then\n        change [x v] by (-1)\n        point in direction (-90)\n    end\n    set [x v] to ((x) * (0.9))\n    change x by (x)\n    if <touching color (#000000)?> then\n        change y by (1)\n        if <touching color (#000000)?> then\n            change y by (1)\n            if <touching color (#000000)?> then\n                change y by (1)\n                if <touching color (#000000)?> then\n                    change y by (1)\n                    if <touching color (#000000)?> then\n                        change y by (1)\n                        if <touching color (#000000)?> then\n                            change x by ((x) * (-1))\n                            change x by (-1)\n                            change y by (-5)\n                            change x by (1)\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change y by (y)\n    if <touching color (#000000)?> then\n        change y by ((y) * (-1))\n        set [y v] to [0]\n    end\n    change y by (-1)\n    if <touching color (#000000)?> then\n        if <key (up arrow v) pressed?> then\n            set [y v] to [15]\n        end\n    end\n    change y by (1)\n    if <touching color (#ff0000)?> then\n        go to x: (-210) y: (151)\n    end\n    if <touching color (#00cccc)?> then\n        set [y v] to [20]\n    end\nend\n\n