Please login or register.

Login with username, password and session length
Advanced search  

News:

IRC channel - server: waelisch.de  channel: #wme (read more)

Author Topic: Problem with 3d actor position  (Read 3568 times)

0 Members and 1 Guest are viewing this topic.

HelLRaiseR

  • I don't want to make a Monkey Island clone :(
  • Wiki editor
  • Frequent poster
  • ****
  • Karma: 4
  • Offline Offline
  • Posts: 270
    • View Profile
    • Adventure Box Studios
Problem with 3d actor position
« on: January 09, 2009, 04:37:55 PM »

 I have a problem with a character. I've been created a .x character from max exported with Panda, the problem is that the character is not in the correct position.

I try to explain it better:

If I specify the position with actor.Direction (DI_UP), the result is the same as actor.Direction (DI_LEFT). The character is rotated 90º to the right

If I put a light in the geometry file, the shadow is projected 90 degrees to the right, but instead of placing the light in the geometry file, I put the light in code with actor.SetLightPosition (x, y, z), where x, y, z as the same position that in the .3ds file, the shadows is display correctly.

I thought that maybe the character had to be in a exactly position respect to the z axis, we have rotated the character 90 degrees to the left, but the result is the same.

Any ideas?

This is a scene with actor.Direction(DI_UP) and the light in the 3ds geometry file:



This is a scene with actor.Direccion(DI_UP) and the light is in the script with actor.SetLightPosition(x,y,z):




« Last Edit: January 09, 2009, 04:40:15 PM by HelLRaiseR »
Logged
Regards,

    Fernando

Jyujinkai

  • Global Moderator
  • Frequent poster
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 352
    • View Profile
    • Jyujinkai's WME Development Blog
Re: Problem with 3d actor position
« Reply #1 on: January 09, 2009, 07:24:44 PM »

you need to build your toon at 0,0,0 and facing teh default directions... so when you look in the front viewport you see the front of teh file.

Make sure you use the tools panel to reset the xforms of the model before you skin and export. Then animate form there...

So if you doign a walk he need to walk foreard facing the front view port.
« Last Edit: January 09, 2009, 07:44:09 PM by Jyujinkai »
Logged
<Antoine de Saint-Exupéry> In any thing at all, perfection is finally attained not when there is no longer anything to add, but when there is no longer anything to take away...
<Carl Sagan> If you want to make a apple pie from scratch. You must first... invent the universe

HelLRaiseR

  • I don't want to make a Monkey Island clone :(
  • Wiki editor
  • Frequent poster
  • ****
  • Karma: 4
  • Offline Offline
  • Posts: 270
    • View Profile
    • Adventure Box Studios
Re: Problem with 3d actor position
« Reply #2 on: January 11, 2009, 03:22:48 PM »

The actor is in x=0 and y=0, but the z value not is 0 becouse the 0 is the middle of the character height. The position is correct, the character front face is in the same direction that the max front indicator. Could be that the problem is the z value?

Logged
Regards,

    Fernando

Jyujinkai

  • Global Moderator
  • Frequent poster
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 352
    • View Profile
    • Jyujinkai's WME Development Blog
Re: Problem with 3d actor position
« Reply #3 on: January 11, 2009, 05:57:07 PM »

I would make sure that the animation is also in the correct direction first. So just check that when he walks "forward" in max he is still facing forward.

If that dose not work... I would same a copy of the file, strip off the skin (remember to save the skin info mation to a file first), make sure you toon is zeroed out.. as in have the pivot a 0,0,0 and all the scales at 100% and the rotations all at 0,0,0 You do this by getting the model in place and pivot in place then resetting the Xform. Then collapsing the stack. You now should have a working mesh that faces the correct direction... test it now.. by exporting it to a .X file... even though you have no skin or animation on it.. just define the idle and walk animations... you should now be able to walk around in wme and stuff... everything should be in the correct positions. After you get that working put back on a skin and then load in the vertex info mation..... This will get it all working.
Logged
<Antoine de Saint-Exupéry> In any thing at all, perfection is finally attained not when there is no longer anything to add, but when there is no longer anything to take away...
<Carl Sagan> If you want to make a apple pie from scratch. You must first... invent the universe
 

Page created in 0.035 seconds with 23 queries.