୨୧ kuromi - a platformer game ˎˊ-


@Stage\n\n@player,, kuromi <3\n\ndefine Physics\nif <key (right arrow v) pressed?> then\n    change [x v] by (2)\nend\nif <key (left arrow v) pressed?> then\n    change [x v] by (-2)\nend\nchange x by (x)\nif <touching (levels,, <3 v)?> then\n    change x by ((x) * (-1))\n    if <key (up arrow v) pressed?> then\n        if <(x) > [0]> then\n            set [x v] to [-10]\n            set [y v] to [10]\n        else\n            set [x v] to [10]\n            set [y v] to [10]\n        end\n    else\n        set [x v] to [0]\n    end\nelse\n    set [x v] to ((x) * (0.8))\nend\nchange y by (y)\nif <touching (levels,, <3 v)?> then\n    change y by ((y) * (-1))\n    set [y v] to [0]\n    if <key (up arrow v) pressed?> then\n        if <(Jumping?) = [y]> then\n            set [y v] to [12]\n            set [jumping? v] to [n]\n        end\n    end\nelse\n    change [y v] by (-1)\n    set [jumping? v] to [y]\nend\nif <touching (enemy ai v)?> then\n    Restart\n    broadcast (Reset Enemy v) and wait\nend\nif <(x position) > [396]> then\n    change [level v] by (1)\n    Restart\n    broadcast (next spike! v)\n    broadcast (next level + show skull v)\nend\nif <touching (spikes,, <3 v)?> then\n    Restart\nend\nif <touching (toxic thingy o.o v)?> then\n    Restart\nend\n\nwhen flag clicked\nRestart\nshow\nset [level v] to [1]\nforever\n    Physics\nend\n\ndefine Restart\nset [x v] to [0]\nset [y v] to [0]\ngo to x: (0) y: (0)\n\ndefine Slope Detection\nset [slope v] to [0]\nrepeat until <<(Slope) = [8]> or <not <touching (levels,, <3 v)?>>>\n    change y by (1)\n    change [slope v] by (1)\nend\nif <touching (levels,, <3 v)?> then\n    change y by (-8)\nend\n\nwhen flag clicked\ngo to [front v] layer\nset [✞︎ 𝖘𝖈𝖔𝖗𝖊 ✞︎ v] to [0]\nforever\n    if <touching (collect,, <3 v)?> then\n        change [✞︎ 𝖘𝖈𝖔𝖗𝖊 ✞︎ v] by (1)\n        broadcast (hide skull v)\n    end\nend\n\nwhen [left arrow v] key pressed\nswitch costume to (kuromi #1 v)\n\nwhen [right arrow v] key pressed\nswitch costume to (kuromi #2 v)\n\n@levels,, <3\n\nwhen flag clicked\nswitch costume to (costume1 v)\nshow\nforever\n    switch costume to (Level)\nend\n\n@spikes,, <3\n\nwhen flag clicked\ngo to [back v] layer\nswitch costume to (costume1 v)\n\nwhen I receive [next spike! v]\nnext costume\n\n@guide,, <33\n\nwhen flag clicked\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\nshow\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nforever\n    play sound [rose // lukrembo v] until done\nend\n\nwhen flag clicked\nforever\n    if <(Level) > [6]> then\n        hide\n    else\n        show\n    end\nend\n\n@collect,, <3\n\nwhen flag clicked\nswitch costume to (costume1 v)\nshow\nforever\n    switch costume to (Level)\nend\n\nwhen I receive [hide skull v]\nhide\n\nwhen I receive [next level + show skull v]\nnext costume\nshow\n\n@stars,, <33\n\nwhen I start as a clone\nforever\n    show\n    set [ghost v] effect to (0)\n    set size to (pick random (5) to (100)) %\n    set [ghost v] effect to (pick random (45) to (100))\n    go to x: (500) y: (pick random (-180.01) to (180))\n    glide (pick random (1.01) to (5)) secs to x: (-240) y: (pick random (-180.01) to (180))\nend\n\nwhen flag clicked\nhide\nwait (0) seconds\nshow\ngo to [front v] layer\nhide\nforever\n    create clone of (_myself_ v)\nend\n\n@dots,, <33\n\nwhen I start as a clone\nforever\n    show\n    set [ghost v] effect to (0)\n    set size to (pick random (5) to (100)) %\n    set [ghost v] effect to (pick random (45) to (100))\n    go to x: (500) y: (pick random (-180.01) to (180))\n    glide (pick random (1.01) to (5)) secs to x: (-240) y: (pick random (-180.01) to (180))\nend\n\nwhen flag clicked\nhide\nwait (0) seconds\nshow\ngo to [front v] layer\nhide\nforever\n    create clone of (_myself_ v)\nend\n\n@toxic thingy o.o\n\nwhen flag clicked\ngo to [back v] layer\nswitch costume to (costume1 v)\n\nwhen I receive [next spike! v]\nnext costume\n\n@Screenshot 2022-05-11 3\n\nwhen flag clicked\ngo to [front v] layer\nrepeat (100)\n    wait (0.01) seconds\n    change [ghost v] effect by (5)\nend\n\n