Jump to content
  • Advertisement
Sign in to follow this  
suliman

3Dstudio max question, plz help...

This topic is 4878 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

Hi I know this isn't really a programming question but maybe someone can help me out anyway. I've got lots of units, for example: I got one tankmesh, and one turretmesh. The turretmesh has its center a bit above the "total center" in the program. So when I place it at the same location as the tank in my game, it sits nively on top of the tank. Fine, now: I want the turret to rotate around its own center, not around the "total-center" in 3DMax. I got the tip to use the privot. As default the privot is placed in the objects own center, seemes what I want couse it rotates around the privot right? But it doesnt. And if I move the privot, that effect where the mesh is placed in my game, not around which point it rotates... Can I solve this without placing each turret manually at its correct position in relation to the tanks? Thank you Suliman

Share this post


Link to post
Share on other sites
Advertisement
Its a little off topic i suppose but one way to handle your problem is use an attachment polygon, an invisible face that has a counterpart on the other mesh. Then the turret's attachment face (and therfore the turret itself) is aligned with that of the tanks attachment face. You can also use the centre of the face as a rotator.

If you mean rotating within max why not put an invisible cylindar (or any geometry really) at your desired rotation point and then using kinematics to make the turret rotate around the cylindar as it is rotated.

By total centre do you mean x=0, y=0, z=0 (the origin point in max?)

Share this post


Link to post
Share on other sites
yes I speak of the origin point.

rotating within Max is no problem, it's in the game.

t=tank
u=turret

u
t

this is obviously how they are placed together (seen from the side, not from above). I model them together to get the right placement of the turret, then save them as two 3ds (for my 3d-engine). This means my turret-mesh is empty at the origin point, the geometry is a bit above. When I place it at the same location as my tank in my game, it is correctly placed, but when the turret is raised it will rotate around the origin point, not its own center (the center of the turret-mesh itself).

Moving the privot seems to not solve my problem. Can you not set a rotating point other then the origin point or achive the result in any way?

Thanks for the help

Share this post


Link to post
Share on other sites
Its just a guess, but it sounds like your transformations are out of order.
The proper order should be rotation and then translation for the turret. From what you describe, the turret is being translated and then rotated.

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!