Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Local $s = _
- "!offset_x={x}" & @CRLF & _
- "!offset_y={y} + 10" & @CRLF & _
- "!offset_z={z}" & @CRLF
- Local $x = 0, $y = 0, $z = 0
- FileDelete('pyramid.txt')
- $iterations = 115 ; size of the pyramid
- $offset = 1
- $prefab = 'stone_wall_2x1'
- Do
- For $i = 1 To $iterations
- $s &= StringFormat('%s %s %s %s 0 180 0', $prefab, $x, $y, $z) & @CRLF
- $x += 2
- Next
- $x -= 0.5
- $z += 0.5
- For $i = 1 To $iterations
- $s &= StringFormat('%s %s %s %s 0 90 0', $prefab, $x, $y, $z) & @CRLF
- $z += 2
- Next
- $x -= 1.5
- $z -= 1.5
- For $i = 1 To $iterations
- $s &= StringFormat('%s %s %s %s 0 0 0', $prefab, $x, $y, $z) & @CRLF
- $x -= 2
- Next
- $x += 1.5
- $z -= 1.5
- For $i = 1 To $iterations - 1
- $s &= StringFormat('%s %s %s %s 0 -90 0', $prefab, $x, $y, $z) & @CRLF
- $z -= 2
- Next
- $x = $offset
- $y += 1
- $z = $offset
- $offset += 1
- $iterations -= 1
- Until $iterations < 0
- FileWrite('pyramid.txt', $s)
Add Comment
Please, Sign In to add comment