The Runner - 3D Platformer (100% Pen)
@Stage\n\nwhen I receive [intro v]\nset volume to (100) %\nbroadcast (Music v)\n\nwhen I receive [music v]\nforever\n    play sound [Freedom Fighters - TSFH v] until done\nend\n\nwhen I receive [ending v]\nrepeat (50)\n    change volume by (-2)\nend\nstop [other scripts in stage v]\nstop all sounds\nset volume to (100) %\nstart sound [Freedom Fighters \(REMIX\) - TSFH v]\n\n@Pen\n\ndefine None\ndelete (all) of [list storage v]\nset [face visible? v] to [0]\nset [count 2 v] to [-2]\nrepeat (4)\n    change [count 2 v] by (3)\n    set [storage v] to []\n    if <(letter (Count 2) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    if <(letter ((Count 2) + (1)) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    if <(letter ((Count 2) + (2)) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    Go to X: ((join (letter (1) of (Storage)) [1]) * (Cube Size)) Y: ((join (letter (2) of (Storage)) [1]) * (Cube Size)) Z: ((join (letter (3) of (Storage)) [1]) * (Cube Size))\n    add ((PointZ) * (sign)) to [list storage v]\n    if <((PointZ) * (sign)) > [0]> then\n        change [face visible? v] by (1)\n    end\nend\nset [count 2 v] to [0]\nset [storage v] to [1]\nrepeat (4)\n    change [count 2 v] by (1)\n    if <(item (Count 2) of [list storage v]) < (item (Storage) of [list storage v])> then\n        set [storage v] to (Count 2)\n    end\nend\ndelete (Storage) of [list storage v]\nset [count 2 v] to [0]\nset [storage v] to [1]\nrepeat (3)\n    change [count 2 v] by (1)\n    if <(item (Count 2) of [list storage v]) < (item (Storage) of [list storage v])> then\n        set [storage v] to (Count 2)\n    end\nend\ndelete (Storage) of [list storage v]\nif <(item (1) of [list storage v]) < (item (2) of [list storage v])> then\n    delete (1) of [list storage v]\nelse\n    delete (2) of [list storage v]\nend\nadd (item (1) of [list storage v]) to [cube face average layer v]\n\ndefine Draw Triangles\nset [count v] to [1]\nrepeat ((length of [triangles v]) / (9))\n    if <(Level) = (item ((Count) + (7)) of [triangles v])> then\n        if <(item (item ((Count) + (6)) of [triangles v]) of [visible faces v]) = [1]> then\n            if <(item ((Count) + (8)) of [triangles v]) = [3]> then\n                set pen color to ((200) * (65536))\n            else\n                if <(item ((Count) + (8)) of [triangles v]) = [2]> then\n                    set pen color to ((200) * (256))\n                else\n                    set pen color to ((0) + (0))\n                end\n            end\n            ADJUST fill (item (Count) of [triangles v]) (item ((Count) + (1)) of [triangles v]) (item ((Count) + (2)) of [triangles v]) (item ((Count) + (3)) of [triangles v]) (item ((Count) + (4)) of [triangles v]) (item ((Count) + (5)) of [triangles v]) resolution: (3) Face: (item ((Count) + (6)) of [triangles v])\n        end\n    end\n    change [count v] by (9)\nend\nset pen color to ((0) + (0))\n\ndefine None\nset pen color to (Cube Color)\nset pen size to (3)\nset [count 2 v] to [-2]\nrepeat (5)\n    change [count 2 v] by (3)\n    set [storage v] to []\n    if <(letter (Count 2) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    if <(letter ((Count 2) + (1)) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    if <(letter ((Count 2) + (2)) of (item (face) of [cube face data v])) = [+]> then\n        set [storage v] to (join (Storage) [0])\n    else\n        set [storage v] to (join (Storage) [-])\n    end\n    Go to X: ((join (letter (1) of (Storage)) [1]) * (Cube Size)) Y: ((join (letter (2) of (Storage)) [1]) * (Cube Size)) Z: ((join (letter (3) of (Storage)) [1]) * (Cube Size))\n    pen down\nend\npen up\n\ndefine None\nif <(res) > [1]> then\n    set [lena v] to ([sqrt v] of ((((bx) - (cx)) * ((bx) - (cx))) + (((by) - (cy)) * ((by) - (cy)))) )\n    set [lenb v] to ([sqrt v] of ((((ax) - (cx)) * ((ax) - (cx))) + (((ay) - (cy)) * ((ay) - (cy)))) )\n    set [lenc v] to ([sqrt v] of ((((ax) - (bx)) * ((ax) - (bx))) + (((ay) - (by)) * ((ay) - (by)))) )\n    set [peri v] to ((1) / (((lena) + (lenb)) + (lenc)))\n    set [incx v] to (((((lena) * (ax)) + ((lenb) * (bx))) + ((lenc) * (cx))) * (peri))\n    set [incy v] to (((((lena) * (ay)) + ((lenb) * (by))) + ((lenc) * (cy))) * (peri))\n    set [ind v] to ([sqrt v] of ((((((lenb) + (lenc)) - (lena)) * (((lenc) + (lena)) - (lenb))) * (((lena) + (lenb)) - (lenc))) * (peri)) )\n    set [aox v] to ((incx) - (ax))\n    set [aoy v] to ((incy) - (ay))\n    set [box v] to ((incx) - (bx))\n    set [boy v] to ((incy) - (by))\n    set [cox v] to ((incx) - (cx))\n    set [coy v] to ((incy) - (cy))\n    if <<(lena) < (lenb)> and <(lena) < (lenc)>> then\n        set [td v] to ([sqrt v] of (((Aox) * (Aox)) + ((Aoy) * (Aoy))) )\n    else\n        if <<(lenb) > (lena)> or <(lenb) > (lenc)>> then\n            set [td v] to ([sqrt v] of (((Cox) * (Cox)) + ((Coy) * (Coy))) )\n        else\n            set [td v] to ([sqrt v] of (((Box) * (Box)) + ((Boy) * (Boy))) )\n        end\n    end\n    set [rate v] to ((((td) * (2)) - (ind)) / ((td) * (4)))\n    set [td v] to ((1) + (0))\n    go to x: (round (incx)) y: (round (incy))\n    set pen size to (ind)\n    pen down\n    repeat ([ceiling v] of (([log v] of ((res) / (ind)) ) / ([log v] of (rate) )) )\n        set [td v] to ((td) * (rate))\n        set pen size to ((ind) * (td))\n        go to x: (((Aox) * (td)) + (ax)) y: (((Aoy) * (td)) + (ay))\n        go to x: (((Box) * (td)) + (bx)) y: (((Boy) * (td)) + (by))\n        go to x: (((Cox) * (td)) + (cx)) y: (((Coy) * (td)) + (cy))\n        go to x: (((Aox) * (td)) + (ax)) y: (((Aoy) * (td)) + (ay))\n    end\n    set pen size to (res)\n    go to x: (ax) y: (ay)\n    go to x: (bx) y: (by)\n    go to x: (cx) y: (cy)\n    go to x: (ax) y: (ay)\n    pen up\nend\n\ndefine Draw Player\nset pen size to ((Cube Size) / (10))\nif <(Player Face) = [1]> then\n    Go to X: (((PlayerX) * (Cube Size)) / (50)) Y: (((PlayerY) * (Cube Size)) / (50)) Z: ((1) * (Cube Size))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\nif <(Player Face) = [2]> then\n    Go to X: ((1) * (Cube Size)) Y: (((PlayerY) * (Cube Size)) / (50)) Z: (((PlayerX) * (Cube Size)) / (-50))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (-50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\nif <(Player Face) = [3]> then\n    Go to X: (((PlayerX) * (Cube Size)) / (-50)) Y: (((PlayerY) * (Cube Size)) / (50)) Z: ((-1) * (Cube Size))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (-50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\nif <(Player Face) = [4]> then\n    Go to X: ((-1) * (Cube Size)) Y: (((PlayerY) * (Cube Size)) / (50)) Z: (((PlayerX) * (Cube Size)) / (50))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\nif <(Player Face) = [5]> then\n    Go to X: (((PlayerX) * (Cube Size)) / (50)) Y: ((1) * (Cube Size)) Z: (((PlayerY) * (Cube Size)) / (-50))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\nif <(Player Face) = [6]> then\n    Go to X: (((PlayerX) * (Cube Size)) / (50)) Y: ((-1) * (Cube Size)) Z: (((PlayerY) * (Cube Size)) / (50))\n    set [player visual x v] to (((PlayerX) * (Cube Size)) / (50))\n    set [player visual y v] to (((PlayerY) * (Cube Size)) / (50))\nend\npen down\npen up\n\ndefine None\ndelete (all) of [tristorage v]\nif <(face) = [1]> then\n    Go to X: (((ax) / (50)) * (Cube Size)) Y: (((ay) / (50)) * (Cube Size)) Z: ((1) * (Cube Size))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((bx) / (50)) * (Cube Size)) Y: (((by) / (50)) * (Cube Size)) Z: ((1) * (Cube Size))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((cx) / (50)) * (Cube Size)) Y: (((cy) / (50)) * (Cube Size)) Z: ((1) * (Cube Size))\nend\nif <(face) = [2]> then\n    Go to X: ((1) * (Cube Size)) Y: (((ay) * (Cube Size)) / (50)) Z: (((ax) * (Cube Size)) / (-50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: ((1) * (Cube Size)) Y: (((by) * (Cube Size)) / (50)) Z: (((bx) * (Cube Size)) / (-50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: ((1) * (Cube Size)) Y: (((cy) * (Cube Size)) / (50)) Z: (((cx) * (Cube Size)) / (-50))\nend\nif <(face) = [3]> then\n    Go to X: (((ax) * (Cube Size)) / (-50)) Y: (((ay) * (Cube Size)) / (50)) Z: ((-1) * (Cube Size))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((bx) * (Cube Size)) / (-50)) Y: (((by) * (Cube Size)) / (50)) Z: ((-1) * (Cube Size))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((cx) * (Cube Size)) / (-50)) Y: (((cy) * (Cube Size)) / (50)) Z: ((-1) * (Cube Size))\nend\nif <(face) = [4]> then\n    Go to X: ((-1) * (Cube Size)) Y: (((ay) * (Cube Size)) / (50)) Z: (((ax) * (Cube Size)) / (50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: ((-1) * (Cube Size)) Y: (((by) * (Cube Size)) / (50)) Z: (((bx) * (Cube Size)) / (50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: ((-1) * (Cube Size)) Y: (((cy) * (Cube Size)) / (50)) Z: (((cx) * (Cube Size)) / (50))\nend\nif <(face) = [5]> then\n    Go to X: (((ax) * (Cube Size)) / (50)) Y: ((1) * (Cube Size)) Z: (((ay) * (Cube Size)) / (-50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((bx) * (Cube Size)) / (50)) Y: ((1) * (Cube Size)) Z: (((by) * (Cube Size)) / (-50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((cx) * (Cube Size)) / (50)) Y: ((1) * (Cube Size)) Z: (((cy) * (Cube Size)) / (-50))\nend\nif <(face) = [6]> then\n    Go to X: (((ax) * (Cube Size)) / (50)) Y: ((-1) * (Cube Size)) Z: (((ay) * (Cube Size)) / (50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((bx) * (Cube Size)) / (50)) Y: ((-1) * (Cube Size)) Z: (((by) * (Cube Size)) / (50))\n    add (x position) to [tristorage v]\n    add (y position) to [tristorage v]\n    Go to X: (((cx) * (Cube Size)) / (50)) Y: ((-1) * (Cube Size)) Z: (((cy) * (Cube Size)) / (50))\nend\nFill (item (1) of [tristorage v]) (item (2) of [tristorage v]) (item (3) of [tristorage v]) (item (4) of [tristorage v]) (x position) (y position) Resolution: (res)\n\ndefine None\npen up\nif <(Text Fade) > [0]> then\n    set pen color to (((((round (r)) * (65536)) + ((round (g)) * (256))) + (round (b))) + ((round ((Text Fade) * (2.55))) * (16777216)))\n    set pen size to ((0.1) * ((size) * (weight)))\n    set [_x v] to ((x) - ((size) / (3)))\n    set [_y v] to ((y) - ((size) / (3)))\n    set [_i0 v] to ((size) / (6))\n    set [_i1 v] to ((space) * ((0.3) * (size)))\n    set [_i2 v] to (length of (text))\n    if <(align) = [c]> then\n        set [_i3 v] to [1]\n        set [_i4 v] to [0]\n        repeat (_i2)\n            change [_i4 v] by (((_i0) * (letter (1) of ([\['letter:of:', \['readvariable', '_i3'\], \['getparam', 'text', 'r'\]\] v] of [efpte v]))) + (_i1))\n            change [_i3 v] by (1)\n        end\n        change [_x v] by ((-0.5) * ((_i4) - (_i1)))\n    end\n    if <(align) = [r]> then\n        change [_x v] by (_i1)\n        set [_i3 v] to (_i2)\n        repeat (_i2)\n            set [_i4 v] to ([\['letter:of:', \['readvariable', '_i3'\], \['getparam', 'text', 'r'\]\] v] of [efpte v])\n            change [_x v] by ((-1) * (((_i0) * (letter (1) of (_i4))) + (_i1)))\n            set [_i5 v] to (((length of (_i4)) - (1)) / (2))\n            set [_i6 v] to [2]\n            repeat (_i5)\n                if <(letter (_i6) of (_i4)) = [u]> then\n                    pen up\n                else\n                    go to x: ((_x) + ((_i0) * (letter (_i6) of (_i4)))) y: ((_y) + ((_i0) * (letter ((_i6) + (1)) of (_i4))))\n                    pen down\n                end\n                change [_i6 v] by (2)\n            end\n            pen up\n            change [_i3 v] by (-1)\n        end\n    else\n        set [_i3 v] to [1]\n        repeat (_i2)\n            set [_i4 v] to ([\['letter:of:', \['readvariable', '_i3'\], \['getparam', 'text', 'r'\]\] v] of [efpte v])\n            set [_i5 v] to (((length of (_i4)) - (1)) / (2))\n            set [_i6 v] to [2]\n            repeat (_i5)\n                if <(letter (_i6) of (_i4)) = [u]> then\n                    pen up\n                else\n                    go to x: ((_x) + ((_i0) * (letter (_i6) of (_i4)))) y: ((_y) + ((_i0) * (letter ((_i6) + (1)) of (_i4))))\n                    pen down\n                end\n                change [_i6 v] by (2)\n            end\n            pen up\n            change [_x v] by (((_i0) * (letter (1) of (_i4))) + (_i1))\n            change [_i3 v] by (1)\n        end\n    end\nend\n\ndefine Control Cube Visibility\ndelete (all) of [cube face average layer v]\nset [count v] to [0]\nrepeat (6)\n    change [count v] by (1)\n    Check Face (Count) Average on [Z] Axis With Sign: (1)\n    replace item (Count) of [visible faces v] with [0]\nend\nrepeat (3)\n    set [count v] to [0]\n    set [storage v] to [1]\n    repeat (6)\n        change [count v] by (1)\n        if <(item (Storage) of [cube face average layer v]) < (item (Count) of [cube face average layer v])> then\n            set [storage v] to (Count)\n        end\n    end\n    replace item (Storage) of [cube face average layer v] with [0]\n    replace item (Storage) of [visible faces v] with [1]\nend\n\ndefine None\nif <(face) = [1]> then\n    if <(edge) = [1]> then\n        set [player face v] to [4]\n        set [playerx v] to [50]\n    else\n        if <(edge) = [2]> then\n            set [player face v] to [5]\n            set [playery v] to [-50]\n        else\n            if <(edge) = [3]> then\n                set [player face v] to [2]\n                set [playerx v] to [-50]\n            else\n                set [player face v] to [6]\n                set [playery v] to [50]\n            end\n        end\n    end\nelse\n    if <(face) = [2]> then\n        if <(edge) = [1]> then\n            set [player face v] to [1]\n            set [playerx v] to [50]\n        else\n            if <(edge) = [2]> then\n                set [player face v] to [5]\n                set [playery v] to (PlayerX)\n                set [playerx v] to [50]\n                if <([abs v] of (Player Orientation) ) = [1]> then\n                    set [player orientation v] to ((-2) * (Player Orientation))\n                else\n                    set [player orientation v] to ((0.5) * (Player Orientation))\n                end\n            else\n                if <(edge) = [3]> then\n                    set [player face v] to [3]\n                    set [playerx v] to [-50]\n                else\n                    set [player face v] to [6]\n                    set [playery v] to ((PlayerX) * (-1))\n                    set [playerx v] to [50]\n                    if <([abs v] of (Player Orientation) ) = [1]> then\n                        set [player orientation v] to ((2) * (Player Orientation))\n                    else\n                        set [player orientation v] to ((-0.5) * (Player Orientation))\n                    end\n                end\n            end\n        end\n    else\n        if <(face) = [3]> then\n            if <(edge) = [1]> then\n                set [player face v] to [2]\n                set [playerx v] to [50]\n            else\n                if <(edge) = [2]> then\n                    set [player face v] to [5]\n                    set [playerx v] to ((-1) * (PlayerX))\n                    set [player orientation v] to ((Player Orientation) * (-1))\n                else\n                    if <(edge) = [3]> then\n                        set [player face v] to [4]\n                        set [playerx v] to [-50]\n                    else\n                        set [player face v] to [6]\n                        set [playerx v] to ((-1) * (PlayerX))\n                        set [playery v] to [-50]\n                        set [player orientation v] to ((Player Orientation) * (-1))\n                    end\n                end\n            end\n        else\n            More Process Transition Face: (face) Edge: (edge)\n        end\n    end\nend\n\ndefine None\nif <(face) = [4]> then\n    if <(edge) = [1]> then\n        set [player face v] to [3]\n        set [playerx v] to [50]\n    else\n        if <(edge) = [2]> then\n            set [player face v] to [5]\n            set [playery v] to ((PlayerX) * (-1))\n            set [playerx v] to [-50]\n            if <([abs v] of (Player Orientation) ) = [1]> then\n                set [player orientation v] to ((2) * (Player Orientation))\n            else\n                set [player orientation v] to ((-0.5) * (Player Orientation))\n            end\n        else\n            if <(edge) = [3]> then\n                set [player face v] to [1]\n                set [playerx v] to [-50]\n            else\n                set [player face v] to [6]\n                set [playery v] to (PlayerX)\n                set [playerx v] to [-50]\n                if <([abs v] of (Player Orientation) ) = [1]> then\n                    set [player orientation v] to ((-2) * (Player Orientation))\n                else\n                    set [player orientation v] to ((0.5) * (Player Orientation))\n                end\n            end\n        end\n    end\nelse\n    if <(face) = [5]> then\n        if <(edge) = [1]> then\n            set [player face v] to [4]\n            set [playerx v] to ((PlayerY) * (-1))\n            set [playery v] to [50]\n            if <([abs v] of (Player Orientation) ) = [1]> then\n                set [player orientation v] to ((-2) * (Player Orientation))\n            else\n                set [player orientation v] to ((0.5) * (Player Orientation))\n            end\n        else\n            if <(edge) = [2]> then\n                set [player face v] to [3]\n                set [playerx v] to ((-1) * (PlayerX))\n                set [player orientation v] to ((Player Orientation) * (-1))\n            else\n                if <(edge) = [3]> then\n                    set [player face v] to [2]\n                    set [playerx v] to (PlayerY)\n                    set [playery v] to [50]\n                    if <([abs v] of (Player Orientation) ) = [1]> then\n                        set [player orientation v] to ((2) * (Player Orientation))\n                    else\n                        set [player orientation v] to ((-0.5) * (Player Orientation))\n                    end\n                else\n                    set [player face v] to [1]\n                    set [playery v] to [50]\n                end\n            end\n        end\n    else\n        Even More Process Transition Face: (face) Edge: (edge)\n    end\nend\n\ndefine None\nif <(edge) = [1]> then\n    set [player face v] to [4]\n    set [playerx v] to (PlayerY)\n    set [playery v] to [-50]\n    if <([abs v] of (Player Orientation) ) = [1]> then\n        set [player orientation v] to ((2) * (Player Orientation))\n    else\n        set [player orientation v] to ((-0.5) * (Player Orientation))\n    end\nelse\n    if <(edge) = [2]> then\n        set [player face v] to [1]\n        set [playery v] to [-50]\n    else\n        if <(edge) = [3]> then\n            set [player face v] to [2]\n            set [playerx v] to ((PlayerY) * (-1))\n            set [playery v] to [-50]\n            if <([abs v] of (Player Orientation) ) = [1]> then\n                set [player orientation v] to ((-2) * (Player Orientation))\n            else\n                set [player orientation v] to ((0.5) * (Player Orientation))\n            end\n        else\n            set [player face v] to [3]\n            set [playerx v] to ((-1) * (PlayerX))\n            set [playery v] to [-50]\n            set [player orientation v] to ((Player Orientation) * (-1))\n        end\n    end\nend\n\nwhen [r v] key pressed\nif <(Ending?) = [0]> then\n    set [cube size v] to [100]\n    repeat (16)\n        change [cube size v] by (((Cube Size) - (101)) / (3))\n    end\n    Position Player\n    repeat (16)\n        change [cube size v] by (((101) - (Cube Size)) / (3))\n    end\n    set [cube size v] to [100]\nend\n\ndefine Draw Background\nif <(Background Mode) = [1]> then\n    Fill Screen (((65536) * (245)) + (((256) * (215)) + (190)))\n    set pen color to ((16777215) + ((20) * (16777216)))\n    set pen size to (200)\n    set [count 2 v] to [80]\n    repeat (3)\n        set [count v] to [0]\n        change [count 2 v] by (10)\n        repeat (13)\n            change [count v] by (30)\n            go to x: (([sin v] of (Count) ) * (Count 2)) y: (([cos v] of (Count) ) * (Count 2))\n            pen down\n        end\n        pen up\n    end\nelse\n    Fill Screen (((65536) * (255)) + (((256) * (250)) + (240)))\nend\n\nwhen I receive [die v]\nset [transition v] to [1]\nset [cube size v] to [100]\nrepeat (16)\n    change [cube size v] by (((Cube Size) - (101)) / (3))\n    Fill Screen (((65536) * (200)) + ((16777216) * (round ((68) - ((Cube Size) / (1.5))))))\nend\nPosition Player\nrepeat (16)\n    change [cube size v] by (((101) - (Cube Size)) / (3))\n    Fill Screen (((65536) * (200)) + ((16777216) * (round ((68) - ((Cube Size) / (1.5))))))\nend\nset [cube size v] to [100]\nset [transition v] to [0]\n\ndefine Update Player\nif <(Textbox Fade) = [0]> then\n    Player Physics <<key (a v) pressed?> or <key (left arrow v) pressed?>> <<key (d v) pressed?> or <key (right arrow v) pressed?>> <<key (w v) pressed?> or <<key (up arrow v) pressed?> or <key (space v) pressed?>>>\n    if <(PlayerX) < [-50]> then\n        set [playery v] to (PastY)\n        Process Transition Face: (Player Face) Edge: (1)\n    end\n    if <(PlayerX) > [50]> then\n        set [playery v] to (PastY)\n        Process Transition Face: (Player Face) Edge: (3)\n    end\n    if <(PlayerY) > [50]> then\n        set [playerx v] to (PastX)\n        Process Transition Face: (Player Face) Edge: (2)\n    end\n    if <(PlayerY) < [-50]> then\n        set [playerx v] to (PastX)\n        Process Transition Face: (Player Face) Edge: (4)\n    end\nend\n\ndefine None\nif <(X1) = (X2)> then\n    if <<<<(Y1) > (y)> and <(Y2) < (y)>> or <<(Y2) > (y)> and <(Y1) < (y)>>> and <([abs v] of ((x) - (X1)) ) < (Triangle Distance)>> then\n        set [touching? v] to [1]\n    end\nelse\n    if <<<<(X1) > (x)> and <(X2) < (x)>> or <<(X2) > (x)> and <(X1) < (x)>>> and <([abs v] of ((y) - (((((Y1) - (Y2)) / ((X1) - (X2))) * ((x) - (X1))) + (Y1))) ) < (Triangle Distance)>> then\n        set [touching? v] to [1]\n    end\nend\n\nwhen I receive [intro v]\nFill Screen (16777215)\nwait (2) seconds\nset [text fade v] to [0]\nrepeat (100)\n    change [text fade v] by (1)\n    Fill Screen (16777215)\n    Print Text: [-Yodasaurus- Presents...] (X, Y): (0) (0) Size: (20) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\nend\nwait (4) seconds\nrepeat (101)\n    Fill Screen (16777215)\n    Print Text: [-Yodasaurus- Presents...] (X, Y): (0) (0) Size: (20) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\n    change [text fade v] by (-1)\nend\nwait (2) seconds\nset [text fade v] to [0]\nrepeat (100)\n    change [text fade v] by (1)\n    Fill Screen (16777215)\n    Print Text: [The Runner] (X, Y): (0) (0) Size: (25) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\nend\nwait (2) seconds\nset [count v] to [0.01]\nrepeat (250)\n    Intro Text Effect\nend\nrepeat (50)\n    Intro Text Effect\n    change [text fade v] by (-2)\nend\nFill Screen (16777215)\nwait (2.5) seconds\n\nwhen [l v] key pressed\nif <(Background Mode) = [1]> then\n    set [background mode v] to [0]\nelse\n    set [background mode v] to [1]\nend\n\nwhen I receive [next level v]\nset [transition v] to [1]\nset [scrollx v] to [0]\nrepeat (17)\n    change [scrollx v] by ((0.25) + ((ScrollX) / (2)))\nend\nchange [level v] by (1)\nPosition Player\nset [scrollx v] to ((ScrollX) * (-1))\nrepeat (17)\n    change [scrollx v] by (((ScrollX) / (-2)) - (0.25))\nend\nset [transition v] to [0]\nif <(Level) = [2]> then\n    Text Fade In\n    Text: [Why do you run?]\n    Text Fade Out\nend\nif <(Level) = [3]> then\n    Text Fade In\n    Text: [All that you need is here.]\n    Text Fade Out\nend\nif <(Level) = [4]> then\n    Text Fade In\n    Text: [There is no purpose...]\n    Text: [...in continuing to run.]\n    Text: [And yet, you do.]\n    Text Fade Out\nend\nif <(Level) = [5]> then\n    Text Fade In\n    Text: [There are reasons why you go on.]\n    Text: [Adventure.]\n    Text: [Curiosity.]\n    Text: [Freedom.]\n    Text Fade Out\nend\nif <(Level) = [6]> then\n    Text Fade In\n    Text: [Those things do not exist here.]\n    Text: [What you see now...]\n    Text: [...is all that there is.]\n    Text Fade Out\nend\nif <(Level) = [7]> then\n    Text Fade In\n    Text: [Now, you will stop and rest.]\n    Text: [There is no escape.]\n    Text: [Do not bother searching for one.]\n    Text Fade Out\nend\nif <(Level) = [8]> then\n    Text Fade In\n    Text: [You have shown much persistence.]\n    Text: [Look where it has gotten you.]\n    Text Fade Out\nend\nif <(Level) = [9]> then\n    Text Fade In\n    Text: [You are exactly where you started.]\n    Text: [Nothing you do...]\n    Text: [...will bring about any change.]\n    Text Fade Out\nend\nif <(Level) = [10]> then\n    Text Fade In\n    Text: [Stop now.]\n    Text: [It is pointless to resist.]\n    Text Fade Out\nend\n\ndefine Intro Text Effect\nif <(Count) > [2]> then\n    change [count v] by (1.1)\nelse\n    change [count v] by (Count)\nend\nFill Screen (16777215)\nrepeat (3)\n    if <(pick random (1) to (500)) < (Text Fade)> then\n        Print Text: [The Runner] (X, Y): (pick random (-20) to (20)) (pick random (-20) to (20)) Size: ((25) + ((Count) / (20))) RGB: (225) (225) (225) Weight: (1.5) Spacing: ((1) + ((Count) / (400))) Alignment: [c]\n    end\nend\nPrint Text: [The Runner] (X, Y): (0) (0) Size: ((25) + ((Count) / (20))) RGB: (0) (0) (0) Weight: (1.5) Spacing: ((1) + ((Count) / (400))) Alignment: [c]\n\ndefine More Player Physics <> <> <>\nif <(Wall Jump) > [0]> then\n    change [wall jump v] by (-1)\nelse\n    set [x velocity v] to ((X Velocity) * (0.85))\n    if <left?> then\n        change [x velocity v] by (-0.5)\n    end\n    if <right?> then\n        change [x velocity v] by (0.5)\n    end\nend\nif <(X Velocity) < [-0.25]> then\n    Walk (-90) (X Velocity) <up?>\nend\nif <(X Velocity) > [0.25]> then\n    Walk (90) (X Velocity) <up?>\nend\nif <up?> then\n    if <<(jump key) = [0]> and <(falling?) < [3]>> then\n        set [y velocity v] to [5.5]\n        set [falling? v] to [6]\n        set [jump key v] to [1]\n    end\nelse\n    set [jump key v] to [0]\nend\n\nwhen I receive [ending v]\nset [transition v] to [1]\nText Fade In\nset [ending? v] to [1]\nText: [There once was a runner.]\nText: [It yearned for something.]\nText: [Freedom.]\nText: [Despite challenges...]\nText: [...the runner persisted.]\nText: [And it finally got what it wanted.]\nText: [The runner broke free.]\nset [y velocity v] to [-10]\nText Fade Out\nrepeat (254)\n    change [cube size v] by (0.25)\n    change [y velocity v] by (-0.1)\n    set [scrollx v] to (pick random ((Cube Size) - (100)) to ((100) - (Cube Size)))\n    set [scrolly v] to (pick random ((Cube Size) - (100)) to ((100) - (Cube Size)))\n    if <(pick random (100) to (250)) < (Cube Size)> then\n        Fill Screen (16777215)\n    else\n        Fill Screen (((round ((((Cube Size) - (100)) * (4)) + (1))) * (16777216)) + (16777215))\n    end\nend\nstop [other scripts in sprite v]\nFill Screen (16777215)\nwait (3) seconds\nset [text fade v] to [0]\nrepeat (100)\n    change [text fade v] by (1)\n    Fill Screen (16777215)\n    Print Text: [Thanks for playing!] (X, Y): (0) (-12.5) Size: (25) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\nend\nset [count v] to [-250]\nrepeat (50)\n    change [count v] by (10)\n    Fill Screen (16777215)\n    Print Text: [Thanks for playing!] (X, Y): (0) (-12.5) Size: (25) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\n    set pen size to (10)\n    go to x: (Count) y: (-35)\n    pen down\n    pen up\nend\n\ndefine Text: []\nset [text fade v] to [100]\nset [text y v] to [-220]\nrepeat (20)\n    change [text y v] by (((Text Y) / (-2)) - (0.25))\n    set pen color to (((200) * (16777216)) + (16777215))\n    set pen size to (60)\n    go to x: (-280) y: (Text Y)\n    pen down\n    change x by (540)\n    pen up\n    Print Text: (text) (X, Y): (0) ((Text Y) - (7.5)) Size: (15) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\nend\nset [text y v] to [0]\nrepeat until <<(Text Y) > [0.0085]> or <<<key (any v) pressed?> or <mouse down?>> and <(Ending?) = [0]>>>\n    set pen color to (((200) * (16777216)) + (16777215))\n    set pen size to (60)\n    go to x: (-280) y: (Text Y)\n    pen down\n    change x by (540)\n    pen up\n    Print Text: (text) (X, Y): (0) ((Text Y) - (7.5)) Size: (15) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\n    change [text y v] by (0.0001)\nend\nset [text y v] to [0]\nrepeat (20)\n    change [text y v] by (((Text Y) / (2)) + (0.25))\n    set pen color to (((200) * (16777216)) + (16777215))\n    set pen size to (60)\n    go to x: (-280) y: (Text Y)\n    pen down\n    change x by (540)\n    pen up\n    Print Text: (text) (X, Y): (0) ((Text Y) - (7.5)) Size: (15) RGB: (0) (0) (0) Weight: (1.5) Spacing: (1) Alignment: [c]\nend\n\ndefine Text Fade In\nset [textbox fade v] to [0]\nrepeat (20)\n    change [textbox fade v] by (3)\nend\n\ndefine None\nif <([abs v] of (Player Orientation) ) = [1]> then\n    change [playerx v] by ((speed) * (Player Orientation))\nelse\n    change [playery v] by ((speed) * ((Player Orientation) / (-2)))\nend\nset [slope v] to [0]\nset [touching? v] to [0]\nTouching Triangle? X: (PlayerX) Y: (PlayerY) Type: (1)\nTouching Triangle? X: (((PlayerX) + (PastX)) / (2)) Y: (((PlayerY) + (PastY)) / (2)) Type: (1)\nrepeat until <<(Slope) = [8]> or <(Touching?) = [0]>>\n    if <([abs v] of (Player Orientation) ) = [1]> then\n        change [playery v] by (Player Orientation)\n    else\n        change [playerx v] by ((Player Orientation) * (0.5))\n    end\n    change [slope v] by (1)\n    set [touching? v] to [0]\n    Touching Triangle? X: (PlayerX) Y: (PlayerY) Type: (1)\n    Touching Triangle? X: (((PlayerX) + (PastX)) / (2)) Y: (((PlayerY) + (PastY)) / (2)) Type: (1)\nend\nif <(Slope) = [8]> then\n    if <([abs v] of (Player Orientation) ) = [1]> then\n        change [playerx v] by (((-1) * (Player Orientation)) * (speed))\n        change [playery v] by ((-8) * (Player Orientation))\n    else\n        change [playerx v] by ((-4) * (Player Orientation))\n        change [playery v] by (((Player Orientation) / (2)) * (speed))\n    end\n    if <<<up?> and <([abs v] of (speed) ) > [1.5]>> and <(Level) < [10]>> then\n        if <(Wall Jump) = [0]> then\n            set [x velocity v] to ((-1) * (speed))\n            if <([abs v] of (Player Orientation) ) = [1]> then\n                set [y velocity v] to [4]\n            else\n                if <([abs v] of (Player Orientation) ) = [2]> then\n                    set [y velocity v] to [4]\n                else\n                    set [y velocity v] to [-4]\n                end\n            end\n            set [falling? v] to [6]\n            set [wall jump v] to [5]\n        end\n    else\n        set [x velocity v] to [0]\n    end\nelse\n    set [x velocity v] to ((X Velocity) * ((1) - ((Slope) * (0.1))))\nend\n\ndefine Adjust Camera\nif <(Player Orientation) = [1]> then\n    set [zrotate1x v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate1y v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate1z v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\n    set [zrotate2x v] to (item (((letter (4) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate2y v] to (item (((letter (4) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate2z v] to (item (((letter (4) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\nend\nif <(Player Orientation) = [2]> then\n    set [zrotate1x v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate1y v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate1z v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\n    set [zrotate2x v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate2y v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate2z v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\nend\nif <(Player Orientation) = [-1]> then\n    set [zrotate1x v] to (item (((letter (3) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate1y v] to (item (((letter (3) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate1z v] to (item (((letter (3) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\n    set [zrotate2x v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate2y v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate2z v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\nend\nif <(Player Orientation) = [-2]> then\n    set [zrotate1x v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate1y v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate1z v] to (item (((letter (1) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\n    set [zrotate2x v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (2)) of [pointcodes v])\n    set [zrotate2y v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (1)) of [pointcodes v])\n    set [zrotate2z v] to (item (((letter (2) of (item (Player Face) of [sidecodes v])) * (3)) - (0)) of [pointcodes v])\nend\nif <(Player Face) = [1]> then\n    set [rotposx v] to (PlayerX)\n    set [rotposy v] to (PlayerY)\n    set [rotposz v] to [50]\nend\nif <(Player Face) = [2]> then\n    set [rotposx v] to [50]\n    set [rotposy v] to (PlayerY)\n    set [rotposz v] to ((-1) * (PlayerX))\nend\nif <(Player Face) = [3]> then\n    set [rotposx v] to ((-1) * (PlayerX))\n    set [rotposy v] to (PlayerY)\n    set [rotposz v] to [-50]\nend\nif <(Player Face) = [4]> then\n    set [rotposx v] to [-50]\n    set [rotposy v] to (PlayerY)\n    set [rotposz v] to (PlayerX)\nend\nif <(Player Face) = [5]> then\n    set [rotposx v] to (PlayerX)\n    set [rotposy v] to [50]\n    set [rotposz v] to ((-1) * (PlayerY))\nend\nif <(Player Face) = [6]> then\n    set [rotposx v] to (PlayerX)\n    set [rotposy v] to [-50]\n    set [rotposz v] to (PlayerY)\nend\nif <(RotPosZ) < [0]> then\n    set [roty v] to (([atan v] of ((RotPosX) / (RotPosZ)) ) - (180))\nelse\n    set [roty v] to ([atan v] of ((RotPosX) / (RotPosZ)) )\nend\nRotate Point X: (RotPosX) Y: (RotPosZ) Degrees: (RotY)\nset [rotposx v] to (RotatedX)\nset [rotposz v] to (RotatedY)\nRotate Point X: (ZRotate1X) Y: (ZRotate1Z) Degrees: (RotY)\nset [zrotate1x v] to (RotatedX)\nset [zrotate1z v] to (RotatedY)\nRotate Point X: (ZRotate2X) Y: (ZRotate2Z) Degrees: (RotY)\nset [zrotate2x v] to (RotatedX)\nset [zrotate2z v] to (RotatedY)\nif <(RotPosZ) < [0]> then\n    set [rotx v] to (([atan v] of ((RotPosY) / (RotPosZ)) ) - (180))\nelse\n    set [rotx v] to ([atan v] of ((RotPosY) / (RotPosZ)) )\nend\nRotate Point X: (ZRotate1Y) Y: (ZRotate1Z) Degrees: (RotX)\nset [zrotate1y v] to (RotatedX)\nset [zrotate1z v] to (RotatedY)\nRotate Point X: (ZRotate2Y) Y: (ZRotate2Z) Degrees: (RotX)\nset [zrotate2y v] to (RotatedX)\nset [zrotate2z v] to (RotatedY)\nif <((ZRotate2Y) - (ZRotate1Y)) < [0]> then\n    set [final rotation 2: the final rotation strikes back v] to ([atan v] of (((ZRotate2X) - (ZRotate1X)) / ((ZRotate2Y) - (ZRotate1Y))) )\nelse\n    set [final rotation 2: the final rotation strikes back v] to (([atan v] of (((ZRotate2X) - (ZRotate1X)) / ((ZRotate2Y) - (ZRotate1Y))) ) - (180))\nend\nif <([abs v] of ((Final Rotation) - (Final Rotation 2: The Final Rotation Strikes Back)) ) < [3]> then\n    set [final rotation v] to (Final Rotation 2: The Final Rotation Strikes Back)\nelse\n    if <((Final Rotation) - (Final Rotation 2: The Final Rotation Strikes Back)) > [180]> then\n        change [final rotation v] by (-360)\n    end\n    if <((Final Rotation) - (Final Rotation 2: The Final Rotation Strikes Back)) < [-180]> then\n        change [final rotation v] by (360)\n    end\n    set [final rotation v] to ((Final Rotation) + (((Final Rotation 2: The Final Rotation Strikes Back) - (Final Rotation)) * (0.5)))\nend\n\ndefine Player Physics <> <> <>\nset [touching? v] to [0]\nif <(Level) = [10]> then\n    if <(Ending?) = [1]> then\n        set [triangle distance v] to [-1]\n    else\n        set [triangle distance v] to [2]\n    end\nelse\n    set [triangle distance v] to [5]\nend\nTouching Triangle? X: (PlayerX) Y: (PlayerY) Type: (3)\nif <(Touching?) = [1]> then\n    if <(Transition) = [0]> then\n        if <<(Y Velocity) < [-5.5]> and <(Level) = [10]>> then\n            broadcast (Ending v)\n        else\n            broadcast (Die v)\n        end\n    end\nelse\n    set [triangle distance v] to [2]\n    Touching Triangle? X: (PlayerX) Y: (PlayerY) Type: (2)\n    if <(Touching?) = [1]> then\n        if <(Transition) = [0]> then\n            broadcast (Next Level v)\n        end\n    else\n        set [pastx v] to (PlayerX)\n        set [pasty v] to (PlayerY)\n        set [triangle distance v] to [5]\n        if <(Level) = [10]> then\n            change [y velocity v] by (-0.05)\n        else\n            if <[6] > ([abs v] of (Y Velocity) )> then\n                if <<(Y Velocity) < [2]> or <up?>> then\n                    change [y velocity v] by (-0.5)\n                else\n                    change [y velocity v] by (-1)\n                end\n            end\n        end\n        if <([abs v] of (Player Orientation) ) = [1]> then\n            change [playery v] by ((Y Velocity) * (Player Orientation))\n        else\n            change [playerx v] by ((Y Velocity) * ((Player Orientation) / (2)))\n        end\n        set [touching? v] to [0]\n        Touching Triangle? X: (PlayerX) Y: (PlayerY) Type: (1)\n        Touching Triangle? X: (((PlayerX) + (PastX)) / (2)) Y: (((PlayerY) + (PastY)) / (2)) Type: (1)\n        if <(Touching?) = [1]> then\n            repeat until <(Touching?) = [0]>\n                if <(Y Velocity) > [0]> then\n                    if <([abs v] of (Player Orientation) ) = [1]> then\n                        change [playery v] by ((-0.5) * (Player Orientation))\n                    else\n                        change [playerx v] by ((-0.25) * (Player Orientation))\n                    end\n                else\n                    if <([abs v] of (Player Orientation) ) = [1]> then\n                        change [playery v] by ((0.5) * (Player Orientation))\n                    else\n                        change [playerx v] by ((0.25) * (Player Orientation))\n                    end\n                    set [falling? v] to [0]\n                end\n                set [touching? v] to [0]\n                Touching Triangle? X: (PlayerX) Y: (PlayerY) Type: (1)\n                Touching Triangle? X: (((PlayerX) + (PastX)) / (2)) Y: (((PlayerY) + (PastY)) / (2)) Type: (1)\n            end\n            set [y velocity v] to [0]\n        end\n        More Player Physics <left?> <right?> <up?>\n    end\nend\n\ndefine None\nset [count v] to [1]\nrepeat ((length of [triangles v]) / (9))\n    if <(item ((Count) + (7)) of [triangles v]) = (Level)> then\n        if <(item ((Count) + (6)) of [triangles v]) = (Player Face)> then\n            if <(item ((Count) + (8)) of [triangles v]) = (type)> then\n                set [x1 v] to (item (Count) of [triangles v])\n                set [y1 v] to (item ((Count) + (1)) of [triangles v])\n                set [x2 v] to (item ((Count) + (2)) of [triangles v])\n                set [y2 v] to (item ((Count) + (3)) of [triangles v])\n                Check X: (x) Y: (y)\n                set [x1 v] to (item ((Count) + (2)) of [triangles v])\n                set [y1 v] to (item ((Count) + (3)) of [triangles v])\n                set [x2 v] to (item ((Count) + (4)) of [triangles v])\n                set [y2 v] to (item ((Count) + (5)) of [triangles v])\n                Check X: (x) Y: (y)\n                set [x1 v] to (item ((Count) + (4)) of [triangles v])\n                set [y1 v] to (item ((Count) + (5)) of [triangles v])\n                set [x2 v] to (item (Count) of [triangles v])\n                set [y2 v] to (item ((Count) + (1)) of [triangles v])\n                Check X: (x) Y: (y)\n            end\n        end\n    end\n    change [count v] by (9)\nend\n\ndefine None\nset [rotatedx v] to (((x) * ([cos v] of (degrees) )) - ((y) * ([sin v] of (degrees) )))\nset [rotatedy v] to (((x) * ([sin v] of (degrees) )) + ((y) * ([cos v] of (degrees) )))\n\ndefine Update\nchange [frame v] by (1)\nControl Cube Visibility\nUpdate Player\n\ndefine None\nset pen color to (color)\nset pen size to (180)\ngo to x: (-420) y: (-180)\nrepeat (3)\n    pen down\n    change x by (660)\n    pen up\n    change x by (-660)\n    change y by (180)\nend\n\nwhen I receive [zoom in v]\nset [cube size v] to [0]\nrepeat (28)\n    change [cube size v] by (((105) - (Cube Size)) / (10))\nend\nset [cube size v] to [100]\n\ndefine Init\nset [scrollx v] to [0]\nset [scrolly v] to [0]\nset [level v] to [1]\nset [frame v] to [0]\nPosition Player\nset [cube color v] to [0]\nset [cube size v] to [0]\nset [transition v] to [0]\nset [background mode v] to [1]\nset [textbox fade v] to [0]\nset [ending? v] to [0]\nbroadcast (Zoom In v)\nbroadcast (Loop v)\n\ndefine Position Player\nset [playerx v] to (item (((Level) * (2)) - (1)) of [start data v])\nset [playery v] to (item ((Level) * (2)) of [start data v])\nset [pastx v] to (item (((Level) * (2)) - (1)) of [start data v])\nset [pasty v] to (item ((Level) * (2)) of [start data v])\nset [x velocity v] to [0]\nset [y velocity v] to [0]\nset [player face v] to [1]\nset [player orientation v] to [1]\n\ndefine Redraw\nerase all\nDraw Background\nset [count v] to [0]\nrepeat (6)\n    change [count v] by (1)\n    if <(item (Count) of [visible faces v]) = [1]> then\n        Draw Face (Count)\n    end\nend\nDraw Triangles\nDraw Player\nAdjust Camera\nif <<[50] > (Frame)> and <[100] > (Cube Size)>> then\n    Fill Screen (((round (((100) - (Cube Size)) * (2.55))) * (16777216)) + (16777215))\nend\nif <(Textbox Fade) > [0]> then\n    Fill Screen (((round ((Textbox Fade) * (2.55))) * (16777216)) + (16777215))\nend\n\ndefine None\nRotate Point X: (x) Y: (z) Degrees: (RotY)\nset [pointx v] to (RotatedX)\nset [pointz v] to (RotatedY)\nRotate Point X: (y) Y: (PointZ) Degrees: (RotX)\nset [pointy v] to (RotatedX)\nset [pointz v] to (RotatedY)\nRotate Point X: (PointX) Y: (PointY) Degrees: (Final Rotation)\ngo to x: ((RotatedX) - (ScrollX)) y: ((RotatedY) - (ScrollY))\n\nwhen I receive [loop v]\nforever\n    Update\n    Redraw\nend\n\nwhen flag clicked\nbroadcast (Intro v) and wait\nInit\n\ndefine Text Fade Out\nset [textbox fade v] to [60]\nrepeat (20)\n    change [textbox fade v] by (-3)\nend\n\ndelete (all) of [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [50] to [pointcodes v]\nadd [-50] to [pointcodes v]\nadd [-50] to [pointcodes v]\ndelete (all) of [sidecodes v]\nadd [1243] to [sidecodes v]\nadd [2684] to [sidecodes v]\nadd [6578] to [sidecodes v]\nadd [5137] to [sidecodes v]\nadd [5621] to [sidecodes v]\nadd [3487] to [sidecodes v]\n\n@EFPTE\n\nwhen flag clicked\ngo to x: (0) y: (0)\nhide\n\n