So I have finally come to spring break this semester, though it won't be much of one as I said that I would be available to work in the computer labs (which I anticipate that those labs will be empty). It will be nice to have a little break from new information though.
On the brighter side I finally got to the section of linear algebra that helps me figure out how to do the triangular tessellations that I was hoping to construct the landscape from. Standard Minecraft style games use the standard x = 1, y = 1, z =1 3d coordinate system, which makes a lot of sense since that is by far the easiest way to represent something in 3d. These are known as the unit vectors and are written as x = (1,0,0), y = (0,1,0), and z = (0,0,1). There is a lot more to it, but I won't bore you with the details. For games the screen will represent an x,y plane because well, lets face it, it is really a 2 dimensional space. Even "3d" monitors and TVs are just a combination of 2 2d planes which creates the illusion of 3d.
So taking the height component as the y, I have figured out that y will still remain a good old 1. The x component will need to be .5, but not on every line rather every other line. The z component is the nasty one as it will be the square root of 3 divided by 2 instead of 1. So my plan is to create a constant variable called DEPTH ( constants are supposed in all caps like that) which is equal to the square root of 3 divided by 2. The z can be expressed as a number of DEPTHS, then if there is an even amount of z the x component will be the normal 1, 2 ,3 etc. but if the amount of z is odd, then x will be 1.5, 2.5, 3.5, etc... Now I wish to clarify that this is just for finding the points which are the corners of each triblock.
Now many of you are probably thinking why not copy the cubic approach that everyone else is using, since it equates to much less work. I guess that the answer is that I am just stubborn, that and I don't wan this to be dismissed as yet another Minecraft ripoff ( which may happen anyway, but at least I can claim that it is different).
No comments:
Post a Comment