Duet - A Hard Platformer
@Stage\n\n@Sprite1\n\nwhen I receive [message1 v]\ngo to x: (-240) y: (-163)\nset [x v] to [0]\nset [y v] to [0]\nset size to (100) %\n\nwhen flag clicked\nset [x v] to [0]\nset [y v] to [0]\ngo to x: (-240) y: (-163)\nset [level v] to [1]\npoint in direction (0)\nset size to (100) %\nforever\n    if <(I made this for fun) = [0]> then\n        change [y v] by (-0.5)\n        if <touching color (#f0ff8a)?> then\n            broadcast (JUMP v)\n        end\n        if <key (right arrow v) pressed?> then\n            change [x v] by (0.7)\n        end\n        if <key (left arrow v) pressed?> then\n            change [x v] by (-0.7)\n        end\n        set [x v] to ((x) * (0.9))\n        change x by (x)\n        if <<touching color (#ff3b3b)?> or <touching color (#000000)?>> then\n            change y by (1)\n            if <<touching color (#ff3b3b)?> or <touching color (#000000)?>> then\n                change y by (1)\n                if <<touching color (#ff3b3b)?> or <touching color (#000000)?>> then\n                    change y by (1)\n                    if <<touching color (#ff3b3b)?> or <touching color (#000000)?>> then\n                        change y by (1)\n                        if <<touching color (#ff3b3b)?> or <touching color (#000000)?>> then\n                            change y by (1)\n                            if <<touching color (#ff3b3b)?> or <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 (#ff3b3b)?> or <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 (#ff3b3b)?> or <touching color (#000000)?>> then\n            if <key (up arrow v) pressed?> then\n                set [y v] to [10]\n            end\n        end\n        change y by (1)\n        if <<[-170] > (y position)> or <<key (r v) pressed?> or <<touching color (#019f01)?> or <touching color (#23c8ff)?>>>> then\n            go to x: (-240) y: (-163)\n            set [x v] to [0]\n            set [y v] to [0]\n            broadcast (message1 v)\n            set size to (100) %\n        end\n        if <touching color (#00ffff)?> then\n            if <key (up arrow v) pressed?> then\n                set [y v] to [3]\n            else\n                set [y v] to [-0.7]\n            end\n        end\n        if <key (s v) pressed?> then\n            wait until <not <key (s v) pressed?>>\n            if <(backdrop [name v]) = [backdrop5]> then\n                broadcast (WINNER v)\n            end\n            change [level v] by (1)\n            switch backdrop to (next backdrop v)\n        end\n        if <(y position) > [170]> then\n            wait until <not <key (s v) pressed?>>\n            if <([y position v] of [sprite2 v]) > [170]> then\n                if <(backdrop [name v]) = [backdrop5]> then\n                    broadcast (WINNER v)\n                end\n                go to x: (-240) y: (-163)\n                set [x v] to [0]\n                set [y v] to [0]\n                broadcast (message1 v)\n                change [level v] by (1)\n                switch backdrop to (next backdrop v)\n                set size to (100) %\n            end\n        end\n        if <touching color (#ffb061)?> then\n            set [y v] to [12.5]\n        end\n        if <touching color (#fff88f)?> then\n            set [x v] to ((x) * (0.7))\n            set [y v] to [0]\n        end\n        if <touching color (#45cf79)?> then\n            set [x v] to [20]\n        end\n        if <touching color (#c649ff)?> then\n            set [y v] to [0]\n            if <not <touching color (#23c8ff)?>> then\n                if <(x position) < [17]> then\n                    go to x: ((x position) + (410)) y: (y position)\n                else\n                    if <[19] < (x position)> then\n                        go to x: ((x position) - (480)) y: (y position)\n                    end\n                end\n            end\n        end\n    end\nend\n\nset [x v] to [0]\nif <(x) > [0]> then\n    set [x v] to [-0.3]\nelse\n    set [x v] to [0.3]\nend\n\nwhen I receive [start v]\ngo to x: (-240) y: (-163)\nset [x v] to [0]\nset [y v] to [0]\nset size to (100) %\nswitch backdrop to (backdrop7 v)\n\nwhen I receive [jump v]\nset [y v] to [13]\n\nwhen I receive [start v]\nforever\n    play sound [Waterflame - Blue Pasture - Oh My Goat! OST.mp3 v] until done\nend\n\n@Sprite2\n\nif <key (up arrow v) pressed?> then\n    if <(x) > [0]> then\n        set [x v] to [-8]\n    else\n        set [x v] to [8]\n    end\n    set [y v] to [10]\nelse\n    set [x v] to [0]\nend\n\nwhen flag clicked\nset [x v] to [0]\nset [y v] to [0]\ngo to x: (50) y: (-163)\nset [level v] to [1]\npoint in direction (0)\nset size to (100) %\nforever\n    if <(I made this for fun) = [0]> then\n        if <touching color (#f0ff8a)?> then\n            broadcast (JUMP v)\n        end\n        change [y v] by (-0.5)\n        if <key (right arrow v) pressed?> then\n            change [x v] by (0.7)\n        end\n        if <key (left arrow v) pressed?> then\n            change [x v] by (-0.7)\n        end\n        set [x v] to ((x) * (0.9))\n        change x by (x)\n        if <<touching color (#23c8ff)?> or <touching color (#000000)?>> then\n            change y by (1)\n            if <<touching color (#23c8ff)?> or <touching color (#000000)?>> then\n                change y by (1)\n                if <<touching color (#23c8ff)?> or <touching color (#000000)?>> then\n                    change y by (1)\n                    if <<touching color (#23c8ff)?> or <touching color (#000000)?>> then\n                        change y by (1)\n                        if <<touching color (#23c8ff)?> or <touching color (#000000)?>> then\n                            change y by (1)\n                            if <<touching color (#23c8ff)?> or <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 (#23c8ff)?> or <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 (#23c8ff)?> or <touching color (#000000)?>> then\n            if <key (up arrow v) pressed?> then\n                set [y v] to [10]\n            end\n        end\n        change y by (1)\n        if <<[-178] > (y position)> or <<key (r v) pressed?> or <<touching color (#019f01)?> or <touching color (#ff3b3b)?>>>> then\n            go to x: (50) y: (-163)\n            set [x v] to [0]\n            set [y v] to [0]\n            broadcast (message1 v)\n            set size to (100) %\n        end\n        if <touching color (#00ffff)?> then\n            if <key (up arrow v) pressed?> then\n                set [y v] to [3]\n            else\n                set [y v] to [-0.7]\n            end\n        end\n        if <key (s v) pressed?> then\n            wait until <not <key (s v) pressed?>>\n            go to x: (-240) y: (-163)\n            set [x v] to [0]\n            set [y v] to [0]\n            broadcast (message1 v)\n            set size to (100) %\n            change [level v] by (1)\n        end\n        if <(y position) > [170]> then\n            wait until <not <key (s v) pressed?>>\n            if <([y position v] of [sprite1 v]) > [170]> then\n                change [level v] by (1)\n                go to x: (-240) y: (-163)\n                set [x v] to [0]\n                set [y v] to [0]\n                set size to (100) %\n                switch backdrop to (next backdrop v)\n                broadcast (message1 v)\n            end\n        end\n        if <touching color (#ffb061)?> then\n            set [y v] to [12.5]\n        end\n        if <touching color (#fff88f)?> then\n            set [x v] to ((x) * (0.7))\n            set [y v] to [0]\n        end\n        if <touching color (#45cf79)?> then\n            set [x v] to [20]\n        end\n        if <touching color (#c649ff)?> then\n            set [y v] to [0]\n            if <not <touching color (#ff3a3a)?>> then\n                if <(x position) < [17]> then\n                    go to x: ((x position) + (410)) y: (y position)\n                else\n                    if <[19] < (x position)> then\n                        go to x: ((x position) - (480)) y: (y position)\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [jump v]\nset [y v] to [13]\n\nwhen I receive [start v]\ngo to x: (50) y: (-163)\nset [x v] to [0]\nset [level v] to [1]\nset [y v] to [0]\nset size to (100) %\n\nwhen I receive [message1 v]\ngo to x: (50) y: (-163)\nset [x v] to [0]\nset [y v] to [0]\nset size to (100) %\n\n@Sprite3\n\nwhen I receive [lock2 v]\nwait until <touching (sprite6 v)?>\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nset [ghost v] effect to (0)\n\nwhen backdrop switches to [backdrop3 v]\nshow\n\nwhen I receive [message1 v]\nif <(backdrop [name v]) = [backdrop5]> then\n    show\nend\n\nwhen flag clicked\nset size to (100) %\ngo to x: (35) y: (-163)\nhide\nforever\n    if <not <(backdrop [name v]) = [backdrop5]>> then\n        hide\n    end\nend\n\n@Sprite4\n\nwhen flag clicked\nforever\n    if <(I made this for fun) = [0]> then\n        repeat (8)\n            change y by (-1)\n        end\n        repeat (5)\n            turn left (1) degrees\n        end\n        repeat (8)\n            change y by (1)\n        end\n        repeat (5)\n            turn left (-1) degrees\n        end\n    else\n        point in direction (90)\n    end\nend\n\nwhen backdrop switches to [backdrop3 v]\nshow\n\nwhen flag clicked\nset [i made this for fun v] to [0]\nswitch costume to (costume1 v)\npoint in direction (90)\ngo to x: (228) y: (61)\nhide\nforever\n    if <not <(backdrop [name v]) = [backdrop3]>> then\n        hide\n    end\n    if <<touching (sprite1 v)?> or <touching (sprite2 v)?>> then\n        go to [front v] layer\n        broadcast (lock v)\n        change [i made this for fun v] by (1)\n        glide (3) secs to x: (-55) y: (-21)\n        repeat (8)\n            wait (0.4) seconds\n            next costume\n        end\n        repeat (10)\n            change [ghost v] effect by (10)\n        end\n        hide\n        set [ghost v] effect to (0)\n        wait (1) seconds\n        set [i made this for fun v] to [0]\n    end\nend\n\nwhen flag clicked\nforever\n    if <(I made this for fun) = [0]> then\n        repeat (10)\n            change [ghost v] effect by (5)\n        end\n        repeat (10)\n            change [ghost v] effect by (-5)\n        end\n    else\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen I receive [message1 v]\nif <(backdrop [name v]) = [backdrop3]> then\n    set [i made this for fun v] to [0]\n    show\n    go to x: (228) y: (61)\nend\n\n@Sprite5\n\nwhen I receive [lock v]\nwait until <touching (sprite4 v)?>\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nset [ghost v] effect to (0)\n\nwhen backdrop switches to [backdrop3 v]\nshow\n\nwhen I receive [message1 v]\nif <(backdrop [name v]) = [backdrop3]> then\n    show\nend\n\nwhen flag clicked\nset size to (100) %\ngo to x: (-78) y: (-40)\nhide\nforever\n    if <not <(backdrop [name v]) = [backdrop3]>> then\n        hide\n    end\nend\n\n@Sprite6\n\nwhen flag clicked\nset [i made this for fun v] to [0]\nswitch costume to (costume1 v)\npoint in direction (90)\ngo to x: (220) y: (157)\nhide\nforever\n    if <not <(backdrop [name v]) = [backdrop5]>> then\n        hide\n    end\n    if <<touching (sprite1 v)?> or <touching (sprite2 v)?>> then\n        go to [front v] layer\n        broadcast (lock2 v)\n        change [i made this for fun v] by (1)\n        glide (3) secs to x: (56) y: (-143)\n        repeat (8)\n            wait (0.4) seconds\n            next costume\n        end\n        repeat (10)\n            change [ghost v] effect by (10)\n        end\n        hide\n        set [ghost v] effect to (0)\n        wait (1) seconds\n        set [i made this for fun v] to [0]\n    end\nend\n\nwhen I receive [message1 v]\nif <(backdrop [name v]) = [backdrop5]> then\n    set [i made this for fun v] to [0]\n    show\n    go to x: (220) y: (157)\nend\n\nwhen flag clicked\nforever\n    if <(I made this for fun) = [0]> then\n        repeat (10)\n            change [ghost v] effect by (5)\n        end\n        repeat (10)\n            change [ghost v] effect by (-5)\n        end\n    else\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen flag clicked\nforever\n    if <(I made this for fun) = [0]> then\n        repeat (8)\n            change y by (-1)\n        end\n        repeat (5)\n            turn left (1) degrees\n        end\n        repeat (8)\n            change y by (1)\n        end\n        repeat (5)\n            turn left (-1) degrees\n        end\n    else\n        point in direction (90)\n    end\nend\n\nwhen backdrop switches to [backdrop5 v]\nshow\ngo to x: (220) y: (157)\n\n@Sprite7\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\ngo to [front v] layer\n\nwhen I receive [start v]\nhide\n\n@Sprite8\n\nwhen flag clicked\nshow\nrepeat (2)\n    go to [front v] layer\nend\nset [ghost v] effect to (80)\nforever\n    go to x: ((mouse x) * (0.2)) y: ((mouse y) * (0.2))\nend\n\nwhen I receive [start v]\nhide\n\n@Sprite9\n\nwhen flag clicked\nshow\nrepeat (2)\n    go to [front v] layer\nend\nset [ghost v] effect to (95)\nforever\n    go to x: ((mouse x) * (0.07)) y: ((mouse y) * (0.07))\nend\n\nwhen I receive [start v]\nhide\n\n@Sprite10\n\nwhen flag clicked\ngo to x: (-45) y: (-32)\npoint in direction (90)\nshow\nset size to (100) %\nrepeat (3)\n    go to [front v] layer\nend\n\nwhen this sprite clicked\nhide\nbroadcast (start v)\n\n@Sprite11\n\nwhen flag clicked\ngo to x: (10) y: (-4)\nset [ghost v] effect to (0)\nshow\nset size to (100) %\nrepeat (10)\n    go to [front v] layer\nend\nwait (2) seconds\nrepeat (10)\n    change size by (-10)\n    change [ghost v] effect by (5)\nend\nhide\n\n@Sprite12\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\nswitch costume to (costume1 v)\nrepeat (10)\n    go to [front v] layer\nend\n\nwhen I receive [start v]\nhide\n\nwhen this sprite clicked\nnext costume\n\n@Sprite13\n\nwhen I receive [winner v]\nshow\n\nwhen flag clicked\nhide\nforever\n    go to x: (0) y: (0)\n    go to [front v] layer\nend\n\nwhen flag clicked\n\n
-------ϟ DUET ϟ-------------------------------------------------------------------------------Be sure to check out my new platformer: https://scratch.mit.edu/projects/159719053/\n\nPLEASE CHECK THE INSTRUCTIONS IN THE GAME! IT IS VERY IMPORTANT!\nSo far, there are 7 challenging levels. ALL LEVELS ARE POSSIBLE BUT THEY MAY BE HARD.\n---------------------------------------------------------------------------------------------------