Scroll　PLATFORMER　＃game  #platformer
@Stage\n\nwhen flag clicked\nforever\n    play sound [TheFatRat+-+Unity v] until done\nend\n\nwhen flag clicked\nset [☁ 0 v] to ((☁ 0) + (1))\n\n@スプライト1\n\nwhen flag clicked\nshow\nset volume to (100) %\nswitch costume to (1 v)\nbroadcast (スタート v)\n\nwhen I receive [スタート v]\nset [scrollx v] to [0]\nset [scrolly v] to [0]\nset [speedx v] to [0]\nset [speedy v] to [0]\nset [y v] to [0]\nset [x v] to [0]\ngo to x: (0) y: (0)\nforever\n    broadcast (game stuff v)\n    broadcast (tick v)\nend\n\nwhen I receive [game stuff v]\nコントロール [1] [-1] [15] [0.9]\n\ndefine セットY (speedy)\nchange [y v] by (speedy)\nposition\nif <touching (スプライト2 v)?> then\n    repeat until <not <touching (スプライト2 v)?>>\n        if <(speedy) > [0]> then\n            change [y v] by (-1)\n        else\n            set [地面に触れた v] to [1]\n            change [y v] by (1)\n        end\n        set [speedy v] to [0]\n        position\n    end\nend\n\ndefine セットX (speedx)\nchange [x v] by (speedx)\nposition\nif <touching (スプライト2 v)?> then\n    repeat until <not <touching (スプライト2 v)?>>\n        if <(speedx) > [0]> then\n            change [x v] by (-1)\n        else\n            change [x v] by (1)\n        end\n        set [speedx v] to [0]\n        position\n    end\n    if <key (up arrow v) pressed?> then\n        set [speedx v] to [-10]\n        set [speedy v] to [10]\n        start sound [壁キック \(1\) v]\n    end\nend\n\ndefine position\ngo to x: ((X) - (scrollX)) y: ((Y) - (scrollY))\n\ndefine コントロール (speed) (重力) (ジャンプの高さ) (スライド)\nif <[4580] < (X)> then\n    broadcast (FINISH v)\n    go to x: (-114) y: (129)\n    stop [this script v]\nelse\n    if <<(Y) < [-150]> or <touching (障害物 v)?>> then\n        set [y v] to [0]\n        set [x v] to [-50]\n        if <touching (障害物 v)?> then\n            start sound [やられる v]\n            set [speedx v] to [0]\n            set [speedy v] to [0]\n        else\n            start sound [crash v]\n        end\n    end\nend\nset [speedx v] to ((スライド) * (speedx))\nif <<key (right arrow v) pressed?> or <<[1] < (mouse x)> and <mouse down?>>> then\n    change [speedx v] by (speed)\nend\nif <<key (left arrow v) pressed?> or <<(mouse x) < [-1]> and <mouse down?>>> then\n    change [speedx v] by ((0) - (speed))\nend\nif <<key (up arrow v) pressed?> or <<[50] < (mouse y)> and <mouse down?>>> then\n    if <(地面に触れた) = [1]> then\n        start sound [suck1 v]\n        set [地面に触れた v] to [0]\n        set [speedy v] to (ジャンプの高さ)\n    end\nend\nchange [speedy v] by (重力)\nセットX (speedx)\nセットY (speedY)\nchange [scrollx v] by ((X) - (scrollX))\nchange [scrolly v] by ((Y) - (scrollY))\nposition\n\nset [x v] to [4580]\n\nwhen I receive [finish v]\nhide\nstop [other scripts in sprite v]\n\n@スプライト2\n\nwhen I receive [tick v]\ngo to x: ((AX) - (scrollX)) y: ((AY) - (scrollY))\nif <<((AX) - (scrollX)) = (x position)> and <((AY) - (scrollY)) = (y position)>> then\n    show\nelse\n    hide\nend\n\nwhen I receive [スタート v]\nset [ax v] to [0]\nset [ay v] to [0]\nrepeat (1)\n    switch costume to (1 \(7\) v)\n    set [ax v] to [0]\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to [480]\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (2))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (3))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (4))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (5))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (6))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (7))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (8))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (9))\n    create clone of (_myself_ v)\nend\n\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (10))\n    create clone of (_myself_ v)\nend\n\nchange [6 v] by (1)\n\nswitch costume to (コスチューム1 v)\n\nnext costume\n\nswitch costume to (コスチューム1 v)\n\nswitch costume to (コスチューム1 v)\n\nswitch costume to (コスチューム1 v)\n\nswitch costume to (コスチューム1 v)\n\nset [ax v] to [0]\n\nset [ax v] to [0]\n\nset [ax v] to [0]\n\nset [ax v] to [0]\n\nwhen I receive [finish v]\nshow\ngo to [front v] layer\nswitch costume to (クリア v)\ngo to x: (0) y: (0)\nwait (1.5) seconds\nstop [other scripts in sprite v]\nhide\nwait (0.1) seconds\nstop [all v]\n\nwhen flag clicked\ngo to x: ((AX) - (scrollX)) y: ((AY) - (scrollY))\nif <<((AX) - (scrollX)) = (x position)> and <((AY) - (scrollY)) = (y position)>> then\n    show\nelse\n    hide\nend\n\n@障害物\n\nwhen I receive [スタート v]\nhide\nset [ax v] to [0]\nset [ay v] to [0]\nrepeat (1)\n    switch costume to (1 v)\n    set [ax v] to [0]\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to [480]\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (2))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (3))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (4))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (5))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (6))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (7))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (8))\n    create clone of (_myself_ v)\nend\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (9))\n    create clone of (_myself_ v)\nend\n\nwhen I receive [tick v]\ngo to x: ((AX) - (scrollX)) y: ((AY) - (scrollY))\nif <<((AX) - (scrollX)) = (x position)> and <((AY) - (scrollY)) = (y position)>> then\n    show\nelse\n    hide\nend\n\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (11))\n    create clone of (_myself_ v)\nend\n\nrepeat (1)\n    next costume\n    set [ax v] to ((480) * (10))\n    create clone of (_myself_ v)\nend\n\nwhen I receive [finish v]\nhide\n\n@背景\n\nwhen flag clicked\ngo to x: (0) y: (0)\ngo to [back v] layer\nshow\n\n@サムネ\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\nset size to (100) %\nset [ghost v] effect to (100)\ngo to [front v] layer\nforever\n    go to [front v] layer\nend\n\nswitch costume to (2 v)\n\n
【日本語は下】\nVolume 20% recommended.\nIf you find it interesting, please give me stars and hearts! ! !\nOperate with arrow keys.\nPlease take a look at this too.\nSimple PLATFORMER\n→https://scratch.mit.edu/projects/813498711\n------------------------------------------------------------------------\n音量20％推奨。\n面白かったら星とハートお願いします！！！\n矢印キーで操作です。\nこっちも是非見てください。\nSimple PLATFORMER\n→https://scratch.mit.edu/projects/813498711\n\n\n