red forest platformer #Games

Instructions: spam the green flag\nuse arrow keys to move\ndon't touch lava and spikes\nget coins\npress S to skip\nmobile friendly\njump on bad blobs\npress space to shoot boss\nonce you get enough coins it will say "double jump activated!" then you will be able to double jump

@Stage\n\nwhen flag clicked\nforever\n    play sound [Tobu - Candyland \[NCS Release\].mp3 v] until done\nend\n\n@ground\n\nwhen flag clicked\ngo to [front v] layer\nerase all\npen up\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\n\nwhen I receive [next level v]\nnext costume\ngo to [front v] layer\nset [boss lives v] to [3]\nwait (1) seconds\n\n@player\n\nwhen I receive [double v]\nset [y v] to [12]\nwait until <not <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>>\nwait until <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>\nset [y v] to [12]\n\nwhen flag clicked\nforever\n    if <(mobile?) = [2]> then\n        if <<key (space v) pressed?> and <(level) > [13]>> then\n            set [player shoot v] to [-10]\n        else\n            set [player shoot v] to [1]\n        end\n    end\nend\n\nwhen flag clicked\npoint in direction (90)\ngo to x: (-206) y: (-83)\nset [x v] to [0]\nset [y v] to [0]\nforever\n    set size to (100) %\n    go [forward v] (1) layers\n    set size to (90) %\n    if <<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    end\n    if <<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    end\n    set [x v] to ((x) * (0.9))\n    change x by (x)\n    if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n        change y by (1)\n        if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n            change y by (1)\n            if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                change y by (1)\n                if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                    change y by (1)\n                    if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                        change y by (1)\n                        if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                            change y by (1)\n                            if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                                change y by (1)\n                                if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                                    change y by (1)\n                                    if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n                                        change y by (-8)\n                                        change x by ((x) * (-1))\n                                        if <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>> then\n                                            if <(x) > [2]> then\n                                                set [x v] to [-8]\n                                                set [y v] to [13]\n                                            else\n                                                set [x v] to [8]\n                                                set [y v] to [13]\n                                            end\n                                        else\n                                            set [x v] to [0]\n                                        end\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change [y v] by (-1)\n    change y by (y)\n    if <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>> then\n        change y by ((y) * (-1))\n        set [y v] to [0]\n    end\n    change y by (-1)\n    if <<<key (w v) pressed?> or <<key (up arrow v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>> and <<touching color (#e60000)?> or <<touching color (#e65252)?> or <touching color (#ff6666)?>>>> then\n        if <(double) = [true]> then\n            broadcast (double v)\n        else\n            set [y v] to [12]\n        end\n    end\n    change y by (1)\n    set size to (100) %\n    if <touching color (#ff4848)?> then\n        set [y v] to [20.5]\n    end\n    if <touching color (#940000)?> then\n        broadcast (died v)\n    end\nend\n\nwhen flag clicked\nforever\n    if <<<(x position) > [222]> or <key (s v) pressed?>> and <not <(level) > [13]>>> then\n        broadcast (next level v)\n        go to x: (-206) y: (-83)\n        wait until <not <key (s v) pressed?>>\n    end\nend\n\nwhen I receive [died v]\nrepeat (10)\n    change [ghost v] effect by (10)\n    go to x: (-206) y: (-83)\nend\nset [ghost v] effect to (0)\nshow\n\nwhen I receive [next level v]\ngo to x: (-206) y: (-83)\n\nwhen flag clicked\nforever\n    set rotation style [left-right v]\n    if <<(x) < [-.5]> or <key (left arrow v) pressed?>> then\n        point in direction (-90)\n    end\n    if <<(x) > [0.5]> or <key (right arrow v) pressed?>> then\n        point in direction (90)\n    end\nend\n\n@spikes\n\nwhen flag clicked\nhide\nforever\n    switch costume to (costume2 v)\n    set [level v] to ([costume # v] of [ground v])\n    go to [back v] layer\n    erase all\n    set [brightness v] effect to (20)\n    if <([costume # v] of [ground v]) = [8]> then\n        erase all\n        change [direction v] by (5)\n        place [-100] [-135]\n        show\n        place [100] [-135]\n    else\n        if <([costume # v] of [ground v]) = [9]> then\n            erase all\n            change [direction v] by (5)\n            place [-100] [-135]\n            show\n            place [100] [-135]\n            place [-100] [5]\n            show\n            place [100] [5]\n        else\n            if <([costume # v] of [ground v]) = [11]> then\n                erase all\n                change [direction v] by (5)\n                place [-30] [-135]\n                place [125] [-135]\n                place [170] [20]\n                hide\n            else\n                if <([costume # v] of [ground v]) = [12]> then\n                    erase all\n                    change [direction v] by (5)\n                    place [-200] [80]\n                    place [170] [15]\n                    hide\n                else\n                    if <([costume # v] of [ground v]) = [13]> then\n                        erase all\n                        change [direction v] by (5)\n                        place [-205] [62]\n                        place [165] [45]\n                        hide\n                    else\n                        hide\n                        set [direction v] to [0]\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine place (x) (y)\npoint in direction (([sin v] of (direction) ) * (100))\ngo to x: (x) y: (y)\nstamp\nshow\nif <touching (player v)?> then\n    broadcast (died v)\nend\n\n@Sprite2\n\nwhen flag clicked\nforever\n    go to x: (0) y: (0)\n    hide\n    point in direction (pick random (-180) to (180))\nend\n\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\n\nset [ghost v] effect to (0)\nshow\nrepeat (40)\n    go to [back v] layer\n    change [ghost v] effect by (3)\n    turn right (1) degrees\n    move (5) steps\nend\ndelete this clone\n\n@Sprite1\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\ngo to [front v] layer\nset [ghost v] effect to (0)\nset [ghost v] effect to (100)\nforever\n    go to [front v] layer\nend\n\n@Sprite4\n\nwhen flag clicked\ngo to [front v] layer\ngo [backward v] (10) layers\nforever\n    go to x: (([x position v] of [player v]) * (-0.2)) y: (([y position v] of [player v]) * (-0.2))\n    set [ghost v] effect to (40)\n    show\n    set [brightness v] effect to (5)\nend\n\n@Sprite5\n\nwhen flag clicked\nshow\nforever\n    go to [back v] layer\n    go [forward v] (1) layers\n    set [ghost v] effect to (40)\n    set [brightness v] effect to (5)\n    go to x: (([x position v] of [player v]) * (-0.1)) y: (([y position v] of [player v]) * (-0.1))\nend\n\nshow\n\n@bad blob\n\ndefine bad (bad x) (bad y)\ngo to x: ((bad x) + (bad x)) y: ((bad y) + (bad y))\n\nwhen flag clicked\nhide\nforever\n    if <([costume # v] of [ground v]) = [6]> then\n        repeat (50)\n            change [bad x v] by (2)\n            point in direction (-90)\n            if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n                set [y v] to [10]\n                broadcast (blob died v)\n                stop [other scripts in sprite v]\n                hide\n            else\n                if <touching (player v)?> then\n                    broadcast (died v)\n                end\n            end\n        end\n        repeat (50)\n            change [bad x v] by (-2)\n            point in direction (90)\n            if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n                set [y v] to [10]\n                broadcast (blob died v)\n                stop [other scripts in sprite v]\n                hide\n            else\n                if <touching (player v)?> then\n                    broadcast (died v)\n                end\n            end\n        end\n    else\n        if <([costume # v] of [ground v]) = [10]> then\n            repeat (50)\n                change [bad x v] by (2)\n                point in direction (-90)\n                if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n                    set [y v] to [10]\n                    broadcast (blob died v)\n                    stop [other scripts in sprite v]\n                    hide\n                else\n                    if <touching (player v)?> then\n                        broadcast (died v)\n                    end\n                end\n            end\n            repeat (50)\n                change [bad x v] by (-2)\n                point in direction (90)\n                if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n                    set [y v] to [10]\n                    broadcast (blob died v)\n                    stop [other scripts in sprite v]\n                    hide\n                else\n                    if <touching (player v)?> then\n                        broadcast (died v)\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [next level v]\nset [bad x v] to [0]\nset [bad y v] to [0]\nhide\nforever\n    go to [front v] layer\n    set rotation style [left-right v]\n    if <([costume # v] of [ground v]) = [6]> then\n        bad [0] [-115]\n        show\n    else\n        if <([costume # v] of [ground v]) = [10]> then\n            bad [-100] [-3]\n            show\n        else\n            hide\n            set [bad x v] to [0]\n            set [bad y v] to [0]\n        end\n    end\nend\n\n@bad blob2\n\ndefine bad (bad x) (bad y)\ngo to x: ((bad x) + (bad x)) y: ((bad y) + (bad y))\n\nwhen flag clicked\nhide\nforever\n    if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n        set [y v] to [10]\n        broadcast (blob died 2 v)\n        stop [other scripts in sprite v]\n        hide\n        erase all\n    else\n        if <touching (player v)?> then\n            broadcast (died v)\n        end\n    end\nend\n\nwhen I receive [next level v]\nset [bad x v] to [0]\nset [bad y v] to [0]\nhide\nforever\n    go to [front v] layer\n    set rotation style [left-right v]\n    if <([costume # v] of [ground v]) = [10]> then\n        bad [115] [100]\n        show\n    else\n        hide\n    end\nend\n\nwhen I receive [next level v]\nforever\n    point in direction ([direction v] of [bad blob v])\nend\n\n@level count\n\nwhen I receive [next level v]\ndelete this clone\n\nwhen I receive [next level v]\nwait (0.001) seconds\nhide\ngo to x: (-224) y: (163)\nset [number v] to [1]\nrepeat (length of (level))\n    switch costume to ((letter (number) of (level)) - (-1))\n    create clone of (_myself_ v)\n    change x by (10)\n    change [number v] by (1)\nend\n\nwhen I start as a clone\nshow\ngo to [front v] layer\n\nwhen flag clicked\nswitch costume to (costume1 v)\nwait (0.001) seconds\nhide\ngo to x: (-224) y: (163)\nset [number v] to [1]\nrepeat (length of (level))\n    switch costume to ((letter (number) of (level)) - (-1))\n    create clone of (_myself_ v)\n    change x by (10)\n    change [number v] by (1)\nend\n\n@Sprite8\n\nwhen flag clicked\nswitch costume to (costume2 v)\nforever\n    go to x: (205) y: (-156)\n    if <(mobile?) = [1]> then\n        go to [front v] layer\n        show\n        if <(level) = [14]> then\n            if <<<mouse down?> and <touching (mouse-pointer v)?>> and <(mobile?) = [1]>> then\n                set [player shoot v] to [-10]\n            else\n                set [player shoot v] to [1]\n            end\n        end\n    else\n        hide\n    end\nend\n\n@boss shoot\n\ndefine bad (bad x) (bad y)\ngo to x: ((bad x) + (bad x)) y: ((bad y) + (bad y))\n\nwhen flag clicked\nforever\n    if <(blob shoot) = [true]> then\n        create clone of (_myself_ v)\n        wait (0.5) seconds\n    end\nend\n\nwhen I start as a clone\nshow\ngo to (blob boss v)\npoint towards (player v)\ngo to [back v] layer\nset size to (70) %\nrepeat until <<touching (player v)?> or <<touching (ground v)?> or <touching (_edge_ v)?>>>\n    move (10) steps\nend\nif <touching (player v)?> then\n    broadcast (died v)\nend\ndelete this clone\n\nwhen I receive [died v]\ndelete this clone\n\n@Sprite3\n\nwhen flag clicked\nset [blob shoot v] to [false]\nforever\n    go to (blob boss v)\n    if <(level) = [14]> then\n        go to (blob boss v)\n        point towards (player v)\n        go to\n        show\n        if <touching (player v)?> then\n            set [blob shoot v] to [true]\n            hide\n            wait (0.5) seconds\n        else\n            set [blob shoot v] to [false]\n        end\n        hide\n    else\n        set [blob shoot v] to [false]\n        hide\n    end\nend\n\ndefine go to\nhide\nrepeat until <<touching (player v)?> or <<touching (ground v)?> or <touching (_edge_ v)?>>>\n    show\n    move (10) steps\nend\n\n@Sprite6\n\nwhen I start as a clone\nmove (20) steps\nshow\ngo to (player v)\npoint in direction ([direction v] of [player v])\ngo to [front v] layer\nset size to (70) %\nrepeat until <<touching (blob boss v)?> or <<touching (ground v)?> or <touching (_edge_ v)?>>>\n    move (10) steps\n    next costume\nend\nif <touching (blob boss v)?> then\n    broadcast (blob lost heart v)\nend\ndelete this clone\n\nwhen flag clicked\nhide\nforever\n    if <(player shoot) = [-10]> then\n        create clone of (_myself_ v)\n        wait (0.5) seconds\n    else\n    end\nend\n\nwhen I receive [died v]\ndelete this clone\n\n@blob boss\n\nwhen flag clicked\nhide\n\nwhen flag clicked\ngo to x: (-206) y: (-83)\nset [boss lives v] to [3]\nset [boss x v] to [0]\nset [boss y v] to [0]\nforever\n    if <(level) = [14]> then\n        show variable [boss lives v]\n        switch costume to (costume2 v)\n        show\n        if <(x position) > (([x position v] of [player v]) - (2))> then\n            change [boss x v] by (-0.1)\n            point in direction (90)\n        end\n        if <(([x position v] of [player v]) - (-2)) > (x position)> then\n            change [boss x v] by (0.1)\n            point in direction (-90)\n        end\n        set [boss x v] to ((boss x) * (0.999))\n        change x by (boss x)\n        if <touching (ground v)?> then\n            change y by (1)\n            if <touching (ground v)?> then\n                change y by (1)\n                if <touching (ground v)?> then\n                    change y by (1)\n                    if <touching (ground v)?> then\n                        change y by (1)\n                        if <touching (ground v)?> then\n                            change y by (1)\n                            if <touching (ground v)?> then\n                                change y by (1)\n                                if <touching (ground v)?> then\n                                    change y by (1)\n                                    if <touching (ground v)?> then\n                                        change y by (1)\n                                        if <touching (ground v)?> then\n                                            change y by (-8)\n                                            change x by ((boss x) * (-1))\n                                            if <(([y position v] of [player v]) - (1)) > (y position)> then\n                                                if <(boss x) > [2]> then\n                                                    set [boss x v] to [-1]\n                                                    set [boss y v] to [15]\n                                                else\n                                                    if <[-2] > (boss x)> then\n                                                        set [boss x v] to [1]\n                                                        set [boss y v] to [15]\n                                                    end\n                                                end\n                                            else\n                                                set [boss x v] to [0]\n                                            end\n                                        end\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n        change [boss y v] by (-1)\n        change y by (boss y)\n        if <touching (ground v)?> then\n            change y by ((boss y) * (-1))\n            set [boss y v] to [0]\n        end\n        change y by (-1)\n        if <<(([y position v] of [player v]) - (1)) > (y position)> and <touching (ground v)?>> then\n            set [boss y v] to [14]\n        end\n        change y by (1)\n        switch costume to (costume2 v)\n        switch costume to (costume1 v)\n    else\n        hide\n        hide variable [boss lives v]\n    end\nend\n\nwhen I receive [died v]\nset [boss lives v] to [3]\ngo to x: (150) y: (100)\nset [boss y v] to [0]\nset [boss x v] to [0]\n\nwhen I receive [next level v]\nif <(level) = [14]> then\n    go to x: (150) y: (100)\nend\n\nwhen flag clicked\nforever\n    if <(boss lives) < [1]> then\n        hide\n        stop [other scripts in sprite v]\n        broadcast (next level v)\n        hide variable [boss lives v]\n        stop [this script v]\n    end\n    if <(level) = [14]> then\n        if <<touching (player v)?> and <(([y position v] of [player v]) - (10)) > (y position)>> then\n            set [y v] to [10]\n            change [boss lives v] by (-1)\n            wait (0.5) seconds\n        end\n    else\n        hide\n        hide variable [boss lives v]\n    end\nend\n\nwhen I receive [blob lost heart v]\nchange [boss lives v] by (-1)\n\n@Sprite7\n\nwhen flag clicked\nswitch costume to (costume2 v)\nforever\n    set [brightness v] effect to (10)\n    go to x: (-160) y: (158)\n    if <<mouse down?> and <touching (mouse-pointer v)?>> then\n        show\n        next costume\n        wait until <not <mouse down?>>\n    end\n    set [mobile? v] to (costume [number v])\nend\n\n@Sprite9\n\nwhen flag clicked\nswitch costume to (costume2 v)\nforever\n    go to x: (130) y: (-156)\n    if <(mobile?) = [1]> then\n        show\n        go to [front v] layer\n        if <<<mouse down?> and <touching (mouse-pointer v)?>> and <(mobile?) = [1]>> then\n            broadcast (next level v)\n            wait until <not <mouse down?>>\n        else\n        end\n    else\n        hide\n    end\nend\n\n@Sprite10\n\nwhen flag clicked\nset [coins v] to [0]\nset [light v] to [0]\ngo to x: (0) y: (-30)\ncreate clone of (_myself_ v)\nforever\n    hide\n    change [light v] by (1)\nend\n\nwhen I receive [next level v]\ndelete this clone\n\nwhen I start as a clone\nforever\n    show\n    set [brightness v] effect to ([sin v] of ((light) * (20)) )\n    if <touching (player v)?> then\n        change [coins v] by (1)\n        delete this clone\n    end\nend\n\nwhen I receive [next level v]\nset [light v] to [0]\nwait (0.001) seconds\nif <([costume # v] of [ground v]) = [2]> then\n    go to x: (-100) y: (50)\n    create clone of (_myself_ v)\nelse\n    if <([costume # v] of [ground v]) = [3]> then\n        go to x: (-20) y: (-30)\n        create clone of (_myself_ v)\n    else\n        if <([costume # v] of [ground v]) = [4]> then\n            go to x: (0) y: (70)\n            create clone of (_myself_ v)\n        else\n            if <([costume # v] of [ground v]) = [5]> then\n                go to x: (100) y: (0)\n                create clone of (_myself_ v)\n            else\n                if <([costume # v] of [ground v]) = [7]> then\n                    go to x: (-220) y: (0)\n                    create clone of (_myself_ v)\n                else\n                    if <([costume # v] of [ground v]) = [9]> then\n                        go to x: (220) y: (50)\n                        create clone of (_myself_ v)\n                    else\n                        if <([costume # v] of [ground v]) = [12]> then\n                            go to x: (-160) y: (150)\n                            create clone of (_myself_ v)\n                        else\n                            if <([costume # v] of [ground v]) = [11]> then\n                                go to x: (50) y: (30)\n                                create clone of (_myself_ v)\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [blob died v]\ngo to (bad blob v)\nwait (0.3) seconds\ncreate clone of (_myself_ v)\n\nwhen I receive [blob died 2 v]\ngo to (bad blob2 v)\nwait (0.3) seconds\ncreate clone of (_myself_ v)\n\n@Sprite11\n\nwhen flag clicked\nhide\nset [ghost v] effect to (0)\nset [double v] to [false]\nforever\n    if <(coins) > [9]> then\n        show\n        go to [front v] layer\n        set [double v] to [true]\n        wait (1) seconds\n        repeat (10)\n            change [ghost v] effect by (10)\n        end\n        stop [this script v]\n    end\nend\n\n