Created
November 9, 2018 12:44
-
-
Save haveyouwantto/8b9b69e1728a68867f7e2ac59b4ffe19 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //For Microsoft Makecode | |
| player.onChat("run", function () { | |
| let xpos = player.position().getValue(Axis.X) | |
| let ypos = player.position().getValue(Axis.Y) | |
| let zpos = player.position().getValue(Axis.Z) | |
| let z = 0 | |
| for (z = -50; z < 50; z++) { | |
| loops.runInBackground(function () { | |
| let zs = z | |
| draw(xpos, ypos, zpos, z) | |
| }) | |
| loops.pause(1000) | |
| } | |
| }) | |
| function draw(xpos: number, ypos: number, zpos: number, z: number) { | |
| for (let x = -50; x < 50; x++) { | |
| let y = x ^ z | |
| blocks.place(152, positions.createWorld(xpos + x, ypos + y, zpos + z)) | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment