It should used like Lego. There a definied blocks and the user simple set the blocks in the world. All Blocks have the same size. The World is a definited Raster in blocksize.
Code: Select all
Here a simple block:
____
/ /|
/ / |
+---+ |
| | /
| |/
+---+
The world also exist as blocks:
____________________________________
/ / / / / / / / / /|
/---/---/---/---/---/---/---/---/---/ |
/ / / / / / / / / /| |
/ / / / / / / / / / | |
+---+---+---+---+---+---+---+---+---| |/|
| | | | | | | | | | / |
| | | | | | | | | |/| |
+---+---+---+---+---+---+---+---+---+ |/|
| | | | | | | | | | / |
| | | | | | | | | |/| |
+---+---+---+---+---+---+---+---+---+ |/|
| | | | | | | | | | / |
| | | | | | | | | |/| /
+---+---+---+---+---+---+---+---+---+ |/
| | | | | | | | | | /
| | | | | | | | | |/
+---+---+---+---+---+---+---+---+---+
So i simple set a block in the World.
SetBlock(#nr,x,y,z,rotatex,rotatey,rotatez) ; Rotate in 90 deg.
SetBlockSize(#nr,pixel) ;- X-Y-Z-Axis have the same size.
CreateBlock(#nr)
addPolygon(#block,#polynr,x1,y1,z1,x2,y2,z2,x3,y3,z3,x4,y4,z4,texture)
(I know, Polygons in 3D are normaly triangles, but i can think simpler with 4 corners

ChangePolygon(#block,#polynr,x,y,z,texture) ; -1=no change.