Ocean - A Platformer #All #games #art #trending #platformer #ocean #teamseas
@Stage\n\nwhen I receive [intro done v]\nforever\n    set [pitch v] effect to (0)\n    play sound [Tobu & Itro - Sunburst.mp3 v] until done\nend\n\nwhen I receive [intro done v]\n\nforever\n    if <key (m v) pressed?> then\n        set [mouse v] to (join (mouse x) (join [ ] (mouse y)))\n    end\nend\n\nwhen I receive [intro done v]\nforever\n    set volume to (MUSIC) %\nend\n\n@TN\n\nwhen flag clicked\nforever\n    go to [front v] layer\n    set [ghost v] effect to (100)\n    go to x: (0) y: (0)\n    show\nend\n\nset [ghost v] effect to (0)\n\n@Player\n\ndefine Platformer\nbroadcast (clone v)\nswitch costume to (costume1 v)\nset rotation style [left-right v]\nif <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(x position) < (mouse x)>>> then\n    point in direction (90)\n    change [xv v] by (1)\nend\nif <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(x position) > (mouse x)>>> then\n    point in direction (-90)\n    change [xv v] by (-1)\nend\nset [xv v] to ((xv) * (0.9))\nchange x by (xv)\nif <touching (level v)?> then\n    change y by (1)\n    if <touching (level v)?> then\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by (1)\n        if <touching (level v)?> then\n            change y by (1)\n        end\n    end\nend\nif <touching (level v)?> then\n    change x by ((xv) * (-1))\n    change y by (-4)\nend\nchange [yv v] by (-1)\nchange y by (yv)\nif <touching (level v)?> then\n    change y by ((yv) * (-1))\n    set [yv v] to [0]\nend\nchange y by (-1)\nif <touching (level v)?> then\n    if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(y position) < (mouse y)>>> then\n        set [yv v] to [15]\n    end\nend\nchange y by (1)\nif <touching (water v)?> then\n    set [yv v] to [-0.7]\nend\nif <<<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(y position) < (mouse y)>>> and <touching (water v)?>> then\n    set [yv v] to [4]\nend\nif <<<<key (down arrow v) pressed?> or <key (s v) pressed?>> or <<mouse down?> and <(y position) > (mouse y)>>> and <touching (water v)?>> then\n    set [yv v] to [-4]\nend\nif <<<<(x position) > [235]> and <(MAX COIN) = (COIN)>> or <key (j v) pressed?>> or <(REDO) = [2]>> then\n    if <<key (j v) pressed?> or <(REDO) = [2]>> then\n        if <(LEVEL) > [11]> then\n            stop [this script v]\n        end\n    end\n    broadcast (next level v)\n    reset\n    wait (1.3) seconds\n    change [level v] by (1)\n    broadcast (reset v)\n    wait until <not <key (j v) pressed?>>\nend\nif <<<<<<<touching (danger v)?> or <touching (saw v)?>> or <(y position) < [-175]>> or <key (r v) pressed?>> or <touching (plastics v)?>> or <touching (pufferfish v)?>> or <(REDO) = [1]>> then\n    if <touching (pufferfish v)?> then\n        broadcast (green v)\n    else\n        broadcast (red v)\n    end\n    start sound [Punch Sound Effect2 v]\n    set rotation style [all around v]\n    set [yv v] to [12]\n    repeat until <(y position) < [-179]>\n        change [yv v] by (-1)\n        turn left (4) degrees\n        change x by (-2)\n        change y by (yv)\n        change [ghost v] effect by (2)\n    end\n    hide\n    wait (0.8) seconds\n    reset\nend\n\nif <<key (up arrow v) pressed?> or <key (w v) pressed?>> then\n    if <(xv) > [0]> then\n        set [xv v] to [-5]\n    else\n        set [xv v] to [5]\n    end\n    set [yv v] to [10]\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [intro done v]\nset [level v] to [1]\ngo to [back v] layer\ngo [forward v] (9) layers\nshow\nreset\nforever\n    Platformer\nend\n\nswitch costume to (costume2 v)\n\ndefine reset\nshow\nbroadcast (reset v)\nset [xv v] to [0]\nset [yv v] to [0]\npoint in direction (90)\nset [ghost v] effect to (0)\ngo to x: (-200) y: (-80)\n\nwhen I receive [intro done v]\nforever\n    wait (pick random (2) to (10)) seconds\n    start sound [Glug v]\nend\n\nwhen flag clicked\nforever\n    set volume to ((SOUND) * (2)) %\nend\n\n@Water\n\nwhen flag clicked\nhide\ngo to [back v] layer\ngo to [back v] layer\n\nwhen I receive [intro done v]\nshow\nforever\n    switch costume to (LEVEL)\nend\n\ngo [forward v] (1) layers\n\n@Level\n\nwhen flag clicked\nhide\ngo to [back v] layer\ngo [forward v] (3) layers\n\nwhen I receive [intro done v]\nshow\nforever\n    switch costume to (LEVEL)\nend\n\n@intro\n\nwhen flag clicked\nstart sound [TheFatRat - Prelude v]\nswitch costume to (background v)\nset [done v] to [0]\nset [type v] to [b]\ncreate clone of (_myself_ v)\nswitch costume to (pfp v)\nhide\nwait (0.5) seconds\ngo to x: (300) y: (0)\nshow\nstart sound [High Whoosh v]\nrepeat until <(x position) < [1]>\n    change x by (((0) - (x position)) / (12))\nend\nset [type v] to [m]\nswitch costume to (mfyy v)\ncreate clone of (_myself_ v)\nswitch costume to (pfp v)\nrepeat until <(x position) < [-42]>\n    change x by (((-43) - (x position)) / (10))\nend\nhide\nset [done v] to [1]\nbroadcast (intro done v)\n\nwhen I start as a clone\nshow\nif <(type) = [m]> then\n    repeat until <(x position) > [42]>\n        change x by (((43) - (x position)) / (10))\n    end\nelse\n    go to x: (0) y: (0)\n    go to [back v] layer\nend\n\nwhen I receive [intro done v]\ndelete this clone\n\nwhen flag clicked\nforever\n    if <mouse down?> then\n        if <(done) = [0]> then\n            wait until <not <mouse down?>>\n            hide\n            stop all sounds\n            set [done v] to [1]\n            broadcast (intro done v)\n            stop [other scripts in sprite v]\n            stop [this script v]\n        end\n    end\nend\n\nset [done v] to [0]\n\n@Danger\n\nwhen flag clicked\nhide\ngo to [back v] layer\ngo [forward v] (2) layers\n\nwhen I receive [intro done v]\nshow\nforever\n    switch costume to (LEVEL)\nend\n\n@Level#\n\nwhen flag clicked\nhide\n\nwhen I start as a clone\nset [brightness v] effect to (0)\ngo to x: ((-165) + ((digits) * (12))) y: (165)\nforever\n    if <(digits) > (length of (LEVEL))> then\n        hide\n    else\n        show\n        switch costume to (letter (digits) of (LEVEL))\n    end\nend\n\ndefine clone\nset [digits v] to [0]\nrepeat (10)\n    change [digits v] by (1)\n    set [type v] to [digit]\n    create clone of (_myself_ v)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [intro done v]\nshow\nclone\ngo to x: (-165) y: (165)\nswitch costume to (costume1 v)\n\n@bubles\n\nwhen I receive [intro done v]\nset rotation style [left-right v]\nforever\n    go to x: (240) y: (pick random (-180) to (180))\n    create clone of (_myself_ v)\n    wait (pick random (0.1) to (0.5)) seconds\nend\n\nwhen I start as a clone\nshow\ngo to [back v] layer\ngo [forward v] (2) layers\nset size to (pick random (60) to (80)) %\nset [ghost v] effect to (pick random (20) to (50))\nglide (pick random (2) to (5)) secs to x: (-240) y: (pick random (-180) to (180))\ndelete this clone\n\n@next level\n\nwhen flag clicked\nhide\nset [cos v] to [2]\nrepeat (2)\n    create clone of (_myself_ v)\n    change [cos v] by (1)\nend\n\nwhen I start as a clone\nshow\nswitch costume to (big v)\nif <(cos) = [2]> then\n    go to x: (400) y: (0)\nelse\n    go to x: (-400) y: (0)\nend\nswitch costume to (cos)\n\nwhen I receive [next level v]\nset [ghost v] effect to (0)\nstart sound [Low Whoosh v]\ngo to [front v] layer\nrepeat until <(round (x position)) = [0]>\n    change x by (((0) - (x position)) / (6))\nend\nwait (0.1) seconds\nrepeat (25)\n    change [ghost v] effect by (4)\nend\nswitch costume to (big v)\nif <(cos) = [2]> then\n    go to x: (400) y: (0)\nelse\n    go to x: (-400) y: (0)\nend\nswitch costume to (cos)\n\nwhen flag clicked\nforever\n    set volume to (SOUND) %\nend\n\nwhen I start as a clone\nforever\n    set volume to (SOUND) %\nend\n\n@a single distinct meaningful element of speech or writing, used with others (or sometimes alone) to form a sentence and typically shown with a space on either side when written or printed.\n\nwhen flag clicked\nhide\ngo to [back v] layer\ngo [forward v] (7) layers\n\nwhen I receive [intro done v]\nshow\nforever\n    switch costume to (LEVEL)\nend\n\n@Saw\n\ndefine clone at (x) (y) (speed) (speed2) (v/h) (size)\ngo to x: (x) y: (y)\nset size to (size) %\nset [sp1 v] to (speed)\nset [sp2 v] to (speed2)\nset [v/h v] to (v/h)\ncreate clone of (_myself_ v)\n\nwhen I receive [reset v]\nhide\nwait (0) seconds\nif <(LEVEL) = [3]> then\n    clone at [-5] [14] [90] [10] [v] [100]\n    clone at [50] [14] [-90] [5] [v] [100]\n    clone at [0] [-50] [90] [10] [h] [100]\n    clone at [0] [-160] [90] [10] [h] [100]\nelse\n    if <(LEVEL) = [4]> then\n        clone at [40] [120] [-40] [4] [h] [100]\n    else\n        if <(LEVEL) = [6]> then\n            clone at [17] [-20] [50] [5] [v] [100]\n        else\n            if <(LEVEL) = [8]> then\n                clone at [-17] [-86] [50] [5] [v] [100]\n            else\n                if <(LEVEL) = [11]> then\n                    clone at [-12] [-91] [40] [5] [v] [100]\n                    clone at [-12] [-91] [50] [5] [h] [100]\n                end\n            end\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    hide\nend\n\nwhen I start as a clone\nset [timer v] to [0]\nforever\n    change [timer v] by ((1) / (30))\n    show\n    go to [back v] layer\n    go [forward v] (4) layers\n    if <(v/h) = [v]> then\n        change y by (([sin v] of ((timer) * (sp1)) ) * (sp2))\n    else\n        change x by (([sin v] of ((timer) * (sp1)) ) * (sp2))\n    end\n    turn right (4) degrees\nend\n\nwhen I receive [reset v]\ndelete this clone\n\n@coin\n\ndefine clone at (x) (y)\ngo to x: (x) y: (y)\nchange [max coin v] by (1)\ncreate clone of (_myself_ v)\n\nwhen flag clicked\nhide\n\nwhen I receive [reset v]\nwait (0) seconds\nif <(LEVEL) = [7]> then\n    clone at [-214] [142]\nelse\n    if <(LEVEL) = [8]> then\n        clone at [25] [-91]\n        clone at [-147] [82]\n        clone at [-232] [-92]\n    else\n        if <(LEVEL) = [9]> then\n            clone at [186] [-118]\n            clone at [186] [2]\n            clone at [186] [124]\n        else\n            if <(LEVEL) = [10]> then\n                clone at [203] [-132]\n            else\n                if <(LEVEL) = [11]> then\n                    clone at [179] [-86]\n                end\n            end\n        end\n    end\nend\n\nwhen I start as a clone\nshow\ngo to [back v] layer\ngo [forward v] (5) layers\nset [timer v] to [0]\nrepeat until <touching (player v)?>\n    change y by (([sin v] of ((timer) * (300)) ) * (0.5))\n    change size by (([sin v] of ((timer) * (100)) ) * (0.5))\n    change [timer v] by ((1) / (30))\nend\nstart sound [Collect v]\nchange [coin v] by (1)\nrepeat (10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\nwhen I receive [reset v]\nset [coin v] to [0]\nset [max coin v] to [0]\ndelete this clone\n\n@Plastics\n\nwhen flag clicked\nhide\ngo to [back v] layer\ngo [forward v] (1) layers\n\nwhen I receive [intro done v]\nshow\nforever\n    switch costume to (LEVEL)\n    change [timer v] by ((1) / (30))\n    if <(LEVEL) = [5]> then\n        change y by (([sin v] of ((timer) * (100)) ) * (0.5))\n    else\n        set y to (0)\n    end\nend\n\nwhen I receive [reset v]\nswitch costume to (LEVEL)\nset y to (0)\nset [timer v] to [0]\n\n@Pufferfish\n\nwhen flag clicked\nhide\n\ndefine clone at (x) (y) (xv) (yv) (size)\ngo to x: (x) y: (y)\nset size to (size) %\nset [xv v] to (xv)\nset [yv v] to (yv)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nshow\nrepeat until <touching (player v)?>\n    switch costume to (hitbox v)\n    change x by (xv)\n    set rotation style [left-right v]\n    if <<<touching (level v)?> or <touching (_edge_ v)?>> or <touching (danger v)?>> then\n        set [xv v] to ((0) - (xv))\n        change x by (xv)\n    end\n    change y by (yv)\n    if <<<touching (level v)?> or <touching (_edge_ v)?>> or <touching (danger v)?>> then\n        set [yv v] to ((0) - (yv))\n        change y by (yv)\n    end\n    point in direction (((xv) / ([abs v] of (xv) )) * (-90))\n    switch costume to (pufferfish v)\nend\nrepeat (10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\nwhen I receive [reset v]\ndelete this clone\n\nwhen I receive [reset v]\nif <(LEVEL) = [7]> then\n    clone at [69] [-56] [-4] [-3] [90]\n    clone at [89] [136] [-4] [-3] [60]\nelse\n    if <(LEVEL) = [9]> then\n        clone at [40] [-119] [4] [2] [40]\n        clone at [40] [2] [4] [2] [40]\n        clone at [40] [134] [4] [2] [40]\n    else\n        if <(LEVEL) = [11]> then\n            clone at [0] [0] [10] [5] [90]\n            clone at [-207] [-30] [5] [-3] [90]\n        end\n    end\nend\n\n@red\n\nwhen I receive [red v]\ngo to [front v] layer\nset [color v] effect to (0)\nshow\nwait (0.1) seconds\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [green v]\ngo to [front v] layer\nset [color v] effect to (60)\nshow\nwait (0.1) seconds\nhide\n\n@tail\n\nwhen flag clicked\nhide\n\nwhen I start as a clone\ngo to [back v] layer\ngo [forward v] (8) layers\nshow\nrepeat (10)\n    change [ghost v] effect by (10)\n    change size by (-5)\nend\ndelete this clone\n\nwhen I receive [clone v]\nif <(costume [name v]) = [a]> then\n    switch costume to (costume1 v)\n    go to (player v)\n    create clone of (_myself_ v)\n    switch costume to (a v)\nend\n\n@buttons\n\nwhen flag clicked\nset [sound v] to [100]\nset [music v] to [100]\nhide\n\nwhen I receive [intro done v]\nswitch costume to (1 v)\ngo to x: (70) y: (159)\nrepeat (4)\n    create clone of (_myself_ v)\n    change x by (40)\n    next costume\nend\n\ncreate clone of (_myself_ v)\n\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nshow\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (((150) - (size)) / (5))\n    else\n        change size by (((100) - (size)) / (5))\n    end\nend\n\nwhen I start as a clone\nset [ghost v] effect to (30)\ngo to [front v] layer\ngo [forward v] (1) layers\nshow\nforever\n    if <touching (mouse-pointer v)?> then\n        start sound [Clock Ticking v]\n        wait until <not <touching (mouse-pointer v)?>>\n    end\nend\n\nwhen I start as a clone\nshow\nforever\n    if <<touching (mouse-pointer v)?> and <mouse down?>> then\n        start sound [Wood Tap v]\n        if <(costume [number v]) = [1]> then\n            set [redo v] to [1]\n            wait (0) seconds\n            set [redo v] to [0]\n        else\n            if <(costume [number v]) = [2]> then\n                set [redo v] to [2]\n                wait (0) seconds\n                set [redo v] to [0]\n            else\n                if <(costume [number v]) = [3]> then\n                    set [music v] to [0]\n                    switch costume to (music off v)\n                else\n                    if <(costume [number v]) = [4]> then\n                        set [sound v] to [0]\n                        switch costume to (sound off v)\n                    else\n                        if <(costume [number v]) = [5]> then\n                            set [music v] to [100]\n                            switch costume to (3 v)\n                        else\n                            if <(costume [number v]) = [6]> then\n                                set [sound v] to [100]\n                                switch costume to (4 v)\n                            end\n                        end\n                    end\n                end\n            end\n        end\n        wait until <not <mouse down?>>\n    end\nend\n\nwhen I start as a clone\nforever\n    set volume to (SOUND) %\nend\n\n
------------------------Ocean - A Platformer---------------------\nGive me time to do part 2. I'm kinda busy now.\nIn level 11, hold down and left when you spawn.\nThis project is made for @TrentonTNT contest.\nHappy Birthday @TrentonTNT!\nALL THE LEVELS ARE POSSIBLE\n\nInstructions:\nUse WASD, arrow keys or mouse to move.\nAvoid spikes, plastics, saws, and pufferfishes.\nCollect all the coins in the level to go to the next level.\nPress J to skip.\nOn level 11, hold down when you spawn.\nLike and Favourite this project and follow me.\nLevel 11 tutorial:\nhttps://scratch.mit.edu/projects/610806438/\nAdd this to more studios.\n\nWhat's in the game:\nSpikes\nSaws\nPlastic bags\nPlastic bottles\nPufferfishes\n\nSave the ocean by using less plastic. #teamseas\n\nCredits:\n@TrentonTNT for the contest.\n@Areeb52090 for the mobile friendly sign.\n@holybird3 for the Glug sound effect.\n@mfyy (me) for the rest.\nMusic is Sunburst\n\nCheck out my other projects:\nhttps://scratch.mit.edu/projects/585135712/\nhttps://scratch.mit.edu/projects/583293878/\nhttps://scratch.mit.edu/projects/596652997/\nhttps://scratch.mit.edu/projects/544593654/\nhttps://scratch.mit.edu/projects/615522819/\n\nComment any bugs or glitches so I can fix them as soon as possible.\nComment any level that you think is hard so I can help.\n\nComment "Ocean pufferfish"\n\n\n\n75 likes and favourites for Part 2.\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n#games #mfyy #ocean #sea #teamseas #All #art #music #trentontnt #contest #mrbeast #saws #mobilefriendly #pufferfish #plastic #savethesea