Colorful - A Scrolling Platformer (Mobile Support) #games #all
@Stage\n\n@Player\n\nwhen I receive [tick v]\ntick\n\ndefine tick\nif <<key (d v) pressed?> or <<key (right arrow v) pressed?> or <<mouse down?> and <(x position) < (mouse x)>>>> then\n    change [x v] by (1)\n    switch costume to (costume1 v)\nend\nif <<key (a v) pressed?> or <<key (left arrow v) pressed?> or <<mouse down?> and <(mouse x) < (x position)>>>> then\n    change [x v] by (-1)\n    switch costume to (costume2 v)\nend\nchange x by (x)\nset [x v] to ((0.9) * (x))\nif <touching color (#1aff00)?> then\n    change y by (1)\n    if <touching color (#1aff00)?> then\n        change y by (1)\n        if <touching color (#1aff00)?> then\n            change y by (1)\n            if <touching color (#1aff00)?> then\n                change y by (1)\n                if <touching color (#1aff00)?> then\n                    change y by (1)\n                    if <touching color (#1aff00)?> then\n                        change x by ((x) * (-1))\n                        change y by (-5)\n                        if <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n                            if <(x) > [0]> then\n                                set [x v] to [-10]\n                            else\n                                set [x v] to [10]\n                            end\n                            set [yv v] to [15]\n                        else\n                            set [x v] to [0]\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\nchange [yv v] by (-1)\nchange y by (yv)\nif <touching color (#1aff00)?> then\n    change y by ((yv) * (-1))\n    set [yv v] to [0]\nend\nchange y by (-1)\nif <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n    if <touching color (#1aff00)?> then\n        set [yv v] to [13]\n    end\nend\nchange y by (1)\nchange [scroll x v] by ((x position) * (-1))\nchange [scroll y v] by ((y position) * (-1))\ngo to x: (0) y: (0)\nif <<touching color (#ff0000)?> or <(scroll y) > [999]>> then\n    broadcast (Died v)\n    set [scroll x v] to [880]\n    set [scroll y v] to [400]\nend\n\nwhen flag clicked\nforever\n    if <touching color (#f0ff00)?> then\n        broadcast (Next Level v)\n    end\nend\n\nwhen I receive [next level v]\nrepeat (2)\n    change [ghost v] effect by (50)\nend\nrepeat (2)\n    change size by (-30)\nend\nrepeat (2)\n    change [ghost v] effect by (-50)\nend\nrepeat (2)\n    change size by (35)\nend\n\nwhen I receive [next level v]\nset size to (60) %\nset [scroll x v] to [880]\nset [scroll y v] to [400]\n\nwhen flag clicked\nforever\n    set size to (60) %\nend\n\nwhen I receive [begin game v]\ngo to x: (0) y: (0)\nforever\n    broadcast (tick v)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen I receive [color change right v]\nchange [color v] effect by (10)\n\nwhen I receive [color change left v]\nchange [color v] effect by (-10)\n\nwhen I receive [respawn v]\nset [scroll x v] to [880]\nset [scroll y v] to [400]\n\nwhen flag clicked\nset [scroll x v] to [880]\nset [scroll y v] to [400]\n\nwhen I receive [begin game v]\nset [scroll x v] to [880]\nset [scroll y v] to [400]\n\nwhen I receive [you win v]\nhide\n\nwhen flag clicked\n\nwhen flag clicked\n\n@Platform\n\nwhen flag clicked\nswitch costume to (size hack v)\nset size to (450) %\nswitch costume to (1 v)\nset [scroll x v] to [880]\nset [scroll y v] to [400]\nforever\n    go to x: (scroll x) y: (scroll y)\nend\n\nwhen I receive [died v]\ngo to x: (scroll x) y: (scroll y)\n\nwhen I receive [next level v]\nnext costume\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen flag clicked\nforever\n    if <(costume [number v]) = [12]> then\n        broadcast (You win v)\n    end\nend\n\nwhen I receive [you win v]\nhide\n\n@Respawn\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-184) y: (132)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((125) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Respawn v)\n\nwhen I receive [toggle off v]\nhide\n\nwhen I receive [toggle on v]\nshow\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen I receive [you win v]\nhide\n\nwhen [r v] key pressed\nbroadcast (Respawn v)\n\n@Skip\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-91) y: (132)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((125) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Next Level v)\n\nwhen I receive [toggle on v]\nshow\n\nwhen I receive [toggle off v]\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen I receive [you win v]\nhide\n\nwhen [y v] key pressed\nbroadcast (Next Level v)\n\n@Mute\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-184) y: (50)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((125) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nnext costume\nif <(costume [number v]) = [2]> then\n    set volume to (0) %\nelse\n    set volume to (100) %\nend\n\nwhen flag clicked\nswitch costume to (costume1 v)\n\nwhen I receive [toggle on v]\nshow\n\nwhen I receive [toggle off v]\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen flag clicked\nset volume to (100) %\nset [skip song v] to [0]\nstart sound [Time Lapse v]\n\nwhen I receive [skip songs v]\nstop all sounds\nchange [skip song v] by (1)\nif <(skip song) = [1]> then\n    play sound [Time Lapse v] until done\n    change [skip song v] by (1)\nelse\n    if <(skip song) = [2]> then\n        play sound [Xenogenesis v] until done\n        change [skip song v] by (1)\n    else\n        if <(skip song) = [3]> then\n            play sound [Prelude v] until done\n            change [skip song v] by (1)\n        else\n            if <(skip song) = [4]> then\n                play sound [Unity v] until done\n                change [skip song v] by (1)\n            else\n                if <(skip song) = [5]> then\n                    play sound [Open Secrets v] until done\n                    change [skip song v] by (1)\n                else\n                    if <(skip song) = [6]> then\n                        play sound [Popsicle v] until done\n                        change [skip song v] by (1)\n                    else\n                        if <(skip song) = [7]> then\n                            set [skip song v] to [1]\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [you win v]\nhide\n\nwhen [m v] key pressed\nnext costume\nif <(costume [number v]) = [2]> then\n    set volume to (0) %\nelse\n    set volume to (100) %\nend\n\nwhen [q v] key pressed\nchange volume by (-10)\n\nwhen [e v] key pressed\nchange volume by (10)\n\n@Turn off/on\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (97) y: (160)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((125) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen flag clicked\nswitch costume to (costume2 v)\n\nwhen this sprite clicked\nnext costume\nif <(costume [number v]) = [1]> then\n    broadcast (Toggle Off v)\nelse\n    broadcast (Toggle On v)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen I receive [you win v]\nhide\n\n@Menu Background\n\nwhen flag clicked\nshow\n\nwhen I receive [begin game v]\nhide\n\nwhen I receive [intro ended v]\n\n@Begin Game\n\nwhen flag clicked\nset [switched? v] to [0]\nshow\nset size to (0) %\ngo to x: (0) y: (70)\npoint in direction (90)\nset [turn v] to [0]\nforever\n    change size by (((100) - (size)) / (4))\n    change [turn v] by (4)\n    if <(switched?) = [0]> then\n        point in direction ((90) + (([sin v] of (turn) ) * (3)))\n    else\n        point in direction ((-90) + (([sin v] of (turn) ) * (3)))\n    end\n    change y by (([sin v] of (turn) ) / (4))\nend\n\nwhen flag clicked\ngo to x: (-61) y: (-25)\nshow\nforever\n    wait (0.001) seconds\n    change [color v] effect by (10)\nend\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((150) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Begin Game v)\n\nwhen I receive [begin game v]\nhide\n\nwhen I receive [intro ended v]\n\n@Icon\n\nwhen flag clicked\ngo to x: (-7) y: (89)\nshow\nforever\n    wait (0.001) seconds\n    change [color v] effect by (10)\nend\n\nwhen I receive [begin game v]\nhide\n\nwhen I receive [intro ended v]\n\n@Color Change Left\n\nwhen flag clicked\ngo to x: (-200) y: (-132)\nshow\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Color Change Left v)\n\nwhen flag clicked\nforever\n    wait (0.001) seconds\n    change [color v] effect by (10)\nend\n\nwhen I receive [begin game v]\nhide\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-200) y: (-132)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((75) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((50) - (size)) / (4))\n    end\nend\n\nwhen I receive [intro ended v]\n\n@Color Change Right\n\nwhen flag clicked\nshow\ngo to x: (-165) y: (-132)\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Color Change Right v)\n\nwhen flag clicked\nforever\n    wait (0.001) seconds\n    change [color v] effect by (10)\nend\n\nwhen I receive [begin game v]\nhide\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-165) y: (-132)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((75) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((50) - (size)) / (4))\n    end\nend\n\nwhen I receive [intro ended v]\n\n@Color Sample\n\nwhen flag clicked\nshow\n\ngo to x: (-182) y: (-99)\n\nwhen I receive [color change left v]\nchange [color v] effect by (-10)\n\nwhen I receive [color change right v]\nchange [color v] effect by (10)\n\nwhen I receive [begin game v]\nhide\n\nwhen I receive [intro ended v]\n\n@Skip Song\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (25)\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        set [ghost v] effect to (0)\n    end\nend\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (-25) y: (143)\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((125) - (size)) / (4))\n    end\n    if <not <touching (mouse-pointer v)?>> then\n        change size by (((100) - (size)) / (4))\n    end\nend\n\nwhen I receive [toggle on v]\nshow\n\nwhen I receive [toggle off v]\nhide\n\nwhen I receive [begin game v]\nshow\n\nwhen flag clicked\nhide\n\nwhen this sprite clicked\nbroadcast (Skip Songs v)\n\nwhen flag clicked\nrepeat (1)\n    if <touching (mouse-pointer v)?> then\n        broadcast (Skip text v)\n    end\nend\n\nwhen I receive [you win v]\nhide\n\nwhen [1 v] key pressed\nbroadcast (Skip Songs v)\n\n@Level Counter\n\nwhen flag clicked\ngo to [front v] layer\nhide\ngo to x: (184) y: (-160)\n\nwhen I receive [next level v]\nnext costume\n\nwhen flag clicked\nswitch costume to (costume1 v)\n\nwhen I receive [begin game v]\nshow\n\n@Menu Background2\n\nwhen flag clicked\nhide\n\nwhen I receive [you win v]\nshow\n\n@Sprite1\n\nwhen flag clicked\nhide\ngo to x: (1) y: (14)\nset [switched? v] to [0]\nset size to (0) %\npoint in direction (90)\nset [turn v] to [0]\nforever\n    change size by (((100) - (size)) / (4))\n    change [turn v] by (4)\n    if <(switched?) = [0]> then\n        point in direction ((90) + (([sin v] of (turn) ) * (3)))\n    else\n        point in direction ((-90) + (([sin v] of (turn) ) * (3)))\n    end\n    change y by (([sin v] of (turn) ) / (4))\nend\n\nwhen flag clicked\n\nwhen I receive [you win v]\nshow\n\n@Sprite2\n\nwhen flag clicked\ngo to x: (51) y: (-138)\nshow\nwait (3) seconds\nhide\n\nwhen I receive [begin game v]\nhide\n\n@Thumbnail\n\nwhen flag clicked\nhide\n\ngo to x: (36) y: (28)\nshow\ngo to [front v] layer\n\n
Me and @Ryham301 collab out NOW!!! https://scratch.mit.edu/projects/431252402/\nA Colorful Platformer (Mobile Support)\n=============================================\nControls: ( Note: I made it so you cant jump downhill )\nWASD, Arrow Keys, and Mobile Support.\n(Did you know can change the color of your player?)\n------------------------------HOTKEYS------------------------------------\n1 - Skip Song\nQ - Volume Down\nE - Volume Up\nM - Mute\nY - Skip Level\nR - Respawn