Nice Day!! ~Scrolling platformer~

Instructions: Nice Day!!\n<操作方法>\n矢印キーです！\nモバイルの方は画面のタップした方向に行きます!!\n壁に触れた状態で上+左右で壁キックです!\nマグマや針に触れると死にます!\n青色に触れると飛べます!\n～よい一日を～

@Stage\n\nwhen flag clicked\nset volume to (100) %\nforever\n    play sound [Electro-Light - Throwback \[NCS Release\] v] until done\nend\n\nwhen flag clicked\nforever\n    if <<[5] < (current [hour v])> and <(current [hour v]) < [18]>> then\n        switch backdrop to (noon v)\n    else\n        switch backdrop to (night v)\n    end\nend\n\nwhen [timer v] > (0)\nif <[0] = (Outro)> then\n    set [outro v] to [1]\n    broadcast (outro v)\nend\n\nwhen flag clicked\nset [outro v] to [0]\nforever\n    reset timer\nend\n\n@Zone\n\nwhen I receive [set zone v]\ngo to [front v] layer\nif <not <(costume [number v]) = [1]>> then\n    go to x: (round ((Zone_X) - (Player_X))) y: (round ((Zone_Y) - (Player_Y)))\n    if <<(x position) = (round ((Zone_X) - (Player_X)))> and <(y position) = (round ((Zone_Y) - (Player_Y)))>> then\n        show\n    else\n        hide\n    end\n    broadcast (Set Player v)\nend\n\nwhen I start as a clone\nhide\n\ndefine Set Zone (cosutume num) (x) (y) (direct) (size)\nswitch costume to ((cosutume num) + (1))\nset [zone_x v] to (x)\nset [zone_y v] to (y)\npoint in direction (direct)\nset size to (size) %\ncreate clone of (_myself_ v)\nswitch costume to (none v)\n\nwhen flag clicked\nhide\nSet Zone [1] [0] [0] [90] [100]\nSet Zone [2] [600] [0] [90] [100]\nSet Zone [3] [1200] [0] [90] [100]\nSet Zone [4] [1680] [180] [90] [100]\nSet Zone [5] [2090] [500] [90] [100]\nSet Zone [6] [2550] [550] [60] [100]\nSet Zone [1] [3480] [0] [90] [100]\nSet Zone [7] [4400] [540] [90] [100]\nSet Zone [8] [4880] [540] [90] [100]\nSet Zone [9] [5360] [540] [90] [100]\nforever\n    switch costume to (none v)\nend\n\nSet Zone [Costume num] [X] [Y] [Direct] [Size]\n\nSet Zone [コスチューム#or名] [X座標] [Y座標] [向き] [サイズ]\n\n@Moving Zone\n\nwhen I receive [set zone v]\nif <not <(costume [number v]) = [1]>> then\n    go to x: (round ((Mov) + ((Zone_X) - (Player_X)))) y: (round ((Zone_Y) - (Player_Y)))\n    if <<(x position) = (round ((Mov) + ((Zone_X) - (Player_X))))> and <(y position) = (round ((Zone_Y) - (Player_Y)))>> then\n        show\n    else\n        hide\n    end\n    broadcast (Set Player v)\nend\n\nwhen I start as a clone\nhide\n\ndefine Set Zone (cosutume num) (x) (y) (direct) (size)\nswitch costume to ((cosutume num) + (1))\nset [zone_x v] to (x)\nset [zone_y v] to (y)\npoint in direction (direct)\nset size to (size) %\ncreate clone of (_myself_ v)\nswitch costume to (none v)\n\nwhen flag clicked\nhide\nSet Zone [1] [650] [0] [90] [100]\nSet Zone [1] [2800] [700] [90] [100]\nSet Zone [1] [2800] [0] [90] [100]\nSet Zone [1] [3800] [0] [90] [100]\nSet Zone [1] [3900] [100] [90] [100]\nSet Zone [1] [4000] [200] [90] [100]\nset [mov v] to [0]\nforever\n    repeat (50)\n        switch costume to (none v)\n        change [mov v] by (5)\n    end\n    repeat (50)\n        change [mov v] by (-5)\n        switch costume to (none v)\n    end\nend\n\n@Out\n\nwhen I receive [set zone v]\nif <not <(costume [number v]) = [1]>> then\n    go to x: (round ((Zone_X) - (Player_X))) y: (round ((Zone_Y) - (Player_Y)))\n    if <<(x position) = (round ((Zone_X) - (Player_X)))> and <(y position) = (round ((Zone_Y) - (Player_Y)))>> then\n        show\n    else\n        hide\n    end\n    broadcast (Set Player v)\nend\n\nwhen I start as a clone\nhide\n\ndefine Set Zone (cosutume num) (x) (y) (direct) (size)\nswitch costume to ((cosutume num) + (1))\nset [zone_x v] to (x)\nset [zone_y v] to (y)\npoint in direction (direct)\nset size to (size) %\ncreate clone of (_myself_ v)\nswitch costume to (none v)\n\nwhen flag clicked\nhide\nSet Zone [1] [1200] [0] [90] [100]\nSet Zone [2] [2090] [500] [90] [100]\nSet Zone [3] [4400] [540] [90] [100]\nforever\n    switch costume to (none v)\nend\n\n@Jumper\n\nwhen I receive [set zone v]\nif <not <(costume [number v]) = [1]>> then\n    go to x: (round ((Zone_X) - (Player_X))) y: (round ((Zone_Y) - (Player_Y)))\n    if <<(x position) = (round ((Zone_X) - (Player_X)))> and <(y position) = (round ((Zone_Y) - (Player_Y)))>> then\n        show\n    else\n        hide\n    end\n    broadcast (Set Player v)\nend\n\nwhen I start as a clone\nhide\n\ndefine Set Zone (cosutume num) (x) (y) (direct) (size)\nswitch costume to ((cosutume num) + (1))\nset [zone_x v] to (x)\nset [zone_y v] to (y)\npoint in direction (direct)\nset size to (size) %\ncreate clone of (_myself_ v)\nswitch costume to (none v)\n\nwhen flag clicked\nhide\nSet Zone [1] [1680] [0] [90] [100]\nforever\n    switch costume to (none v)\nend\n\n@サムネ\n\nwhen flag clicked\nset [ghost v] effect to (100)\nshow\nforever\n    go to x: (0) y: (0)\n    go to [front v] layer\n    if <<[5] < (current [hour v])> and <(current [hour v]) < [18]>> then\n        switch costume to (コスチューム1 v)\n    else\n        switch costume to (コスチューム3 v)\n    end\nend\n\n@Woods\n\nwhen I receive [set zone v]\ngo to [back v] layer\nif <not <(costume [number v]) = [1]>> then\n    go to x: (round ((Zone_X) - (Player_X))) y: (round ((Zone_Y) - (Player_Y)))\n    if <<(x position) = (round ((Zone_X) - (Player_X)))> and <(y position) = (round ((Zone_Y) - (Player_Y)))>> then\n        show\n    else\n        hide\n    end\n    broadcast (Set Player v)\nend\n\nwhen I start as a clone\nhide\n\ndefine Set Zone (cosutume num) (x) (y) (direct) (size)\nswitch costume to ((cosutume num) + (1))\nset [zone_x v] to (x)\nset [zone_y v] to (y)\npoint in direction (direct)\nset size to (size) %\ncreate clone of (_myself_ v)\nswitch costume to (none v)\n\nwhen flag clicked\nhide\nSet Zone [1] [0] [0] [90] [100]\nSet Zone [2] [600] [0] [90] [100]\nSet Zone [2] [1680] [0] [90] [100]\nSet Zone [3] [2090] [500] [90] [100]\nSet Zone [4] [2553] [708] [90] [100]\nSet Zone [1] [3480] [0] [90] [100]\nSet Zone [5] [4880] [540] [90] [100]\nforever\n    switch costume to (none v)\nend\n\nSet Zone [Costume num] [X] [Y] [Direct] [Size]\n\nSet Zone [コスチューム#or名] [X座標] [Y座標] [向き] [サイズ]\n\nSet Zone [5] [1900] [0] [90] [100]\n\n@Player\n\nwhen flag clicked\nbroadcast (Set Player v)\ngo to [front v] layer\ngo [backward v] (1) layers\nRe:Start [0] [50]\n\ndefine Re:Start (player_x) (player_y)\nswitch costume to (a v)\nclear graphic effects\nset [player_x v] to (player_x)\nset [player_y v] to (player_y)\nset [back_x v] to (player_x)\nset [back_y v] to (player_y)\nset [power_x v] to [0]\nset [power_y v] to [0]\nset [jumping? v] to [0]\npoint in direction (90)\nshow\n\ndefine Set Player\nset size to (120) %\nbroadcast (Set Zone v)\nswitch costume to (a v)\nSet Player's X&Y\nif <touching (zone v)?> then\n    change [back_y v] by (5)\n    Set Player's X&Y\n    if <not <touching (zone v)?>> then\n        stop [this script v]\n    end\n    change [back_y v] by (-5)\n    repeat until <not <touching (zone v)?>>\n        if <[0] < (Power_X)> then\n            change [back_x v] by (-1)\n        else\n            change [back_x v] by (1)\n        end\n        Set Player's X&Y\n    end\n    if <<<key (space v) pressed?> or <key (up arrow v) pressed?>> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>> then\n        set [power_x v] to (() - ((Power_X) * (2)))\n        set [power_y v] to [10]\n    else\n        set [power_x v] to [0]\n    end\n    Set Player's X&Y\nend\nif <<key (right arrow v) pressed?> or <<key (d v) pressed?> or <<mouse down?> and <(x position) < (mouse x)>>>> then\n    change [power_x v] by (2)\n    switch costume to (b v)\nend\nif <<key (left arrow v) pressed?> or <<key (a v) pressed?> or <<mouse down?> and <(mouse x) < (x position)>>>> then\n    change [power_x v] by (-2)\n    switch costume to (c v)\nend\nif <<<key (space v) pressed?> or <key (up arrow v) pressed?>> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>> then\n    if <(Jumping?) = [0]> then\n        set [power_y v] to [13]\n    end\nend\nchange [power_y v] by (-1)\nchange [back_y v] by (Power_Y)\nset [jumping? v] to [1]\nSet Player's X&Y\nSet Player's Y\nif <touching (jumper v)?> then\n    set [power_y v] to [18]\nend\nSet Player's X for Moving Zone\nif <<touching (out v)?> or <<[1000] < (Back_Y)> or <(Player_Y) < [-200]>>> then\n    if <[1499] < (Player_X)> then\n        if <[3249] < (Player_X)> then\n            if <[4199] < (Player_X)> then\n                Re:Start [4200] [500]\n            else\n                Re:Start [3250] [50]\n            end\n        else\n            Re:Start [1500] [50]\n        end\n    else\n        Re:Start [0] [50]\n    end\nend\nSet Player's X&Y\nchange [player_x v] by (round (((Back_X) - (Player_X)) / (5)))\nchange [player_y v] by (round (((Back_Y) - (Player_Y)) / (15)))\nset [power_x v] to ((Power_X) * (0.75))\nchange [back_x v] by (round ((Power_X) * (1.25)))\nSet Player's X&Y\n\ndefine Set Player's X&Y\ngo to x: (round ((Back_X) - (Player_X))) y: (round ((Back_Y) - (Player_Y)))\n\nwhen I receive [set player v]\nif <(Back_X) < [-210]> then\n    set [back_x v] to [-210]\nend\nif <(Power_Y) < [-9]> then\n    set [power_y v] to [-9]\nend\nif <[5550] < (Back_X)> then\n    set [back_x v] to [5550]\nend\nSet Player\n\ndefine Set Player's Y\nrepeat until <not <touching (zone v)?>>\n    if <[0] < (Power_Y)> then\n        change [back_y v] by (-1)\n    else\n        change [back_y v] by (1)\n        if <not <key (up arrow v) pressed?>> then\n            set [jumping? v] to [0]\n        end\n    end\n    Set Player's X&Y\n    set [power_y v] to [0]\nend\n\ndefine Set Player's X for Moving Zone\nif <<touching (moving zone v)?> and <not <touching (zone v)?>>> then\n    change [back_x v] by ([x position v] of [moving zone v])\n    change [player_x v] by ([x position v] of [moving zone v])\nend\nrepeat until <not <touching (moving zone v)?>>\n    if <[0] < (Power_Y)> then\n        change [back_y v] by (-1)\n    else\n        change [back_y v] by (1)\n        if <not <key (up arrow v) pressed?>> then\n            set [jumping? v] to [0]\n        end\n    end\n    Set Player's X&Y\n    set [power_y v] to [0]\nend\n\n@outro\n\nwhen I receive [outro v]\nset [α v] to [0]\nreset timer\npoint in direction (90)\ngo to x: (0) y: (0)\nhide\nswitch costume to (none v)\nset size to (100) %\nswitch costume to (background v)\ncreate clone of (_myself_ v)\nswitch costume to (background2 v)\ncreate clone of (_myself_ v)\nswitch costume to (thank you v)\ncreate clone of (_myself_ v)\nswitch costume to (for watching v)\ncreate clone of (_myself_ v)\nswitch costume to (flash v)\ncreate clone of (_myself_ v)\nswitch costume to (pinwheel v)\ncreate clone of (_myself_ v)\nswitch costume to (icon v)\ncreate clone of (_myself_ v)\nswitch costume to (name v)\ncreate clone of (_myself_ v)\nswitch costume to (指示1 v)\ncreate clone of (_myself_ v)\n\nwhen I receive [outro v]\nplay sound [Raven & Kreyn - So Happy \[NCS Release\]2 v] until done\nforever\n    play sound [Raven & Kreyn - So Happy \[NCS Release\] v] until done\nend\n\nwhen I start as a clone\nif <(costume [number v]) = [4]> then\n    show\n    set [ghost v] effect to (100)\n    repeat (40)\n        change [ghost v] effect by (-2.5)\n    end\n    wait until <[5.3] < (timer)>\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\nend\nif <(costume [number v]) = [3]> then\n    wait (3) seconds\n    go to [back v] layer\n    show\nend\nif <(costume [number v]) = [9]> then\n    point in direction (45)\n    go to x: (-420) y: (40)\n    set size to (120) %\n    show\n    wait (1) seconds\n    set [ghost v] effect to (80)\n    repeat (30)\n        change [ghost v] effect by (-5)\n        change x by (((0) - (x position)) / (5))\n        turn right (((90) - (direction)) / (5)) degrees\n    end\n    wait (1) seconds\n    set [α v] to [0]\n    repeat (30)\n        change x by (α)\n        turn right ((α) / (10)) degrees\n        change [α v] by (2)\n    end\n    delete this clone\nend\nif <(costume [number v]) = [10]> then\n    point in direction (135)\n    go to x: (420) y: (-40)\n    set size to (120) %\n    show\n    wait (1) seconds\n    set [ghost v] effect to (80)\n    repeat (30)\n        change [ghost v] effect by (-5)\n        change x by (((0) - (x position)) / (5))\n        turn right (((90) - (direction)) / (5)) degrees\n    end\n    wait (1) seconds\n    set [α v] to [0]\n    repeat (30)\n        change x by (α)\n        turn right ((α) / (10)) degrees\n        change [α v] by (-2)\n    end\n    delete this clone\nend\nif <(costume [number v]) = [11]> then\n    clear graphic effects\n    wait until <[8.8] < (timer)>\n    go to [front v] layer\n    show\n    forever\n        clear graphic effects\n        repeat (10)\n            change [ghost v] effect by (10)\n        end\n        wait (3.4) seconds\n    end\nend\nif <(costume [number v]) = [8]> then\n    wait until <[5.4] < (timer)>\n    show\n    set [ghost v] effect to (100)\n    switch costume to (none v)\n    switch costume to (pinwheel v)\n    point in direction (90)\n    set [α v] to [0]\n    repeat (5)\n        turn right (α) degrees\n        change [ghost v] effect by (-20)\n        change [α v] by (0.5)\n    end\n    repeat (15)\n        turn right (α) degrees\n        change [α v] by (0.5)\n    end\n    repeat (50)\n        turn right (((90) - (direction)) / (10)) degrees\n    end\n    forever\n        point in direction (90)\n        set [α v] to [0]\n        repeat (20)\n            turn right (α) degrees\n            change [α v] by (0.5)\n        end\n        repeat (50)\n            turn right (((90) - (direction)) / (10)) degrees\n        end\n    end\nend\nif <(costume [number v]) = [2]> then\n    wait until <[5.4] < (timer)>\n    set size to (150) %\n    go to x: (0) y: (0)\n    show\n    forever\n        point in direction ((90) + (([sin v] of ((timer) * (250)) ) * (10)))\n        set y to ((20) + (([sin v] of ((timer) * (125)) ) * (10)))\n    end\nend\nif <(costume [number v]) = [12]> then\n    wait until <[5.4] < (timer)>\n    set size to (100) %\n    point in direction (90)\n    go to x: (0) y: (-120)\n    show\n    forever\n        set y to ((-120) + (([sin v] of ((timer) * (125)) ) * (20)))\n        set x to ((0) + (([cos v] of ((timer) * (125)) ) * (50)))\n        set size to ((100) + (([sin v] of ((0) - ((timer) * (125))) ) * (20))) %\n        point in direction ((90) + (([sin v] of ((timer) * (250)) ) * (10)))\n    end\nend\nif <(costume [number v]) = [12]> then\n    wait until <[5.4] < (timer)>\n    set size to (100) %\n    point in direction (90)\n    go to x: (0) y: (-120)\n    show\n    forever\n        set y to ((-120) + (([sin v] of ((timer) * (125)) ) * (20)))\n        set x to ((0) + (([cos v] of ((timer) * (125)) ) * (50)))\n        set size to ((100) + (([sin v] of ((0) - ((timer) * (125))) ) * (20))) %\n        set [pixelate v] effect to ((10) - (([sin v] of ((0) - ((timer) * (125))) ) * (10)))\n        point in direction ((90) + (([sin v] of ((timer) * (250)) ) * (10)))\n    end\nend\nif <(costume [number v]) = [13]> then\n    wait until <[5.4] < (timer)>\n    forever\n        switch costume to (pick random (5) to (7))\n        set [α v] to (pick random (-180) to (180))\n        set [β v] to (pick random (-60) to (170))\n        パーン\n        switch costume to (circle v)\n        create clone of (_myself_ v)\n        wait (0.2) seconds\n    end\nend\nif <<<(costume [number v]) = [5]> or <(costume [number v]) = [6]>> or <(costume [number v]) = [7]>> then\n    go to x: (α) y: (β)\n    set size to (pick random (40) to (60)) %\n    show\n    set [α v] to (pick random (-15) to (15))\n    set [β v] to (pick random (5) to (17))\n    repeat until <<([abs v] of (x position) ) > [240]> or <([abs v] of (y position) ) > [200]>>\n        change x by (α)\n        change y by (β)\n        if <[1] < (α)> then\n            change [α v] by (-0.2)\n        end\n        if <(β) < [-1]> then\n            change [β v] by (0.2)\n        end\n        turn right ((costume [number v]) * (3)) degrees\n        change [β v] by (-1)\n    end\n    delete this clone\nend\nif <(costume [number v]) = [14]> then\n    go to x: (α) y: (β)\n    show\n    set [α v] to [20]\n    set size to (80) %\n    repeat (30)\n        set [ghost v] effect to (α)\n        change [α v] by (((100) - (α)) / (5))\n        change size by (((120) - (size)) / (2))\n    end\n    delete this clone\nend\n\nset [pixelate v] effect to (0)\n\ndefine パーン\nrepeat (5)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nforever\n    go to [front v] layer\nend\n\n