• Advertisement
Sign in to follow this  

Rolling Block

This topic is 1739 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have a block that's 1x2x1 units (x, y, z), and I'd like to roll it around a grid as shown in Cubicman:

 

 

My box is going to be decorated, and the programming for it is just a mess, and about half way completed. What I'm doing right now is keeping track of which of the six possible directions the box currently is facing UP (standing tall), DOWN (upside-down), LEFT (facing negative x-axis), RIGHT (facing position x-axis), FORWARD (facing negative z-axis), or BACK (facing positive z-axis).

 

-If UP, I figure out if it's going LEFT, RIGHT, FORWARD, or BACK, then animate

-If DOWN, I figure out if it's going LEFT, RIGHT, FORWARD, or BACK

-If LEFT, rotate left, rotate right, etc etc...

 

I'm pretty confused up to this point. Does anyone have any other ideas on how this could be done? I'm sure there's a simple solution, but I think my matrix transformation system needs some work.

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement