Major scale issues

Baddcog

09-08-2008 03:13:10

Alright, I'm working on getting some objects in game (an indie game I'm getting a chance to test parts of).

I can get the objects in game, worked around the animation errors I was getting, got the icons working.

One object I can get into game, I can see it but it's very large, I did manage to make it smaller but it's still very large. The other object was already larger and the only indication it is loading is that the item it replaces dissappears when I choose it from the menu. Also the ogre.log in the client folder shows that it loaded along with it's materials.

I have Max 7 and am using O Fusion exporter.

Here's the weird thing.
The Devs are using Maya, thier engine uses a meter as one unit.
I import one of their objects, built mine the same exact size and exported using generic units, it was WAY too big. I have since tried using centimeters, meters and kilometers in both the
customize:
Display Unit Scale and
System Unit set-up.

Also manually shrinking the object. Somehow I managed to shrink one object enough to see it in game although it is still WAY too big. Now I've shrunk it in Max so small I can barely see it, but the scale in game hasn't changed.

I have deleted all the files and closed the engine in between each step. But it remains the same size.

There is no help file for o fusion I can find except a 'pro' version.chm which I have but it won't connect to the internet page (I don't have Pro)

I wish I could try another exporter but this is the only one I have found that works with my vers of Max (7)

Any ideas what I'm doing wrong? I'm kindof a guinee pig on this.
EDIT----------------------

Have messed with this more. It seems the only way I can get the correct scale it to skin it, add a bone, then scale the bone down.

However this seems to have bad reactions with anims even though the scaling was done before any animation or keyframes.

If I scale the object by itself it doesn't get any smaller.

If I reset the scale of the bones with bone tools it doesn't work.

Lioric

09-08-2008 16:04:26

Is the mesh scaled in any way? (see if your mesh contains non-unit scale)

As you seem to be using the mesh directly and not loading it using the osm scene file (where the node and its object scale is), the mesh will be of the same size, as the scale is in the node, but you are not using it, you are using the mesh data directly

For using the mesh data directly, you must set the desired object scale to be the 'unit scale' (1, 1, 1), this actualy 'bakes' the mesh size in the world, to do this set the object to the desired scale size and you can either 'Reset XForm' or from the Hierarchy panel 'Reset Scale'

After you do this process, the object scale (in its current size) should display the 'unit scale' and when exporting the mesh will be of the correct size

Evak

09-08-2008 16:24:24

3dsmax system unit size by default has the wrong system unit scale for 1:1 with Ogre. can't remember how I changed it now. Think I set mine to generic units and in system unit settings 1 unit = 10cm.

By default I think it was 1 unit = 1m and everything was 10x bigger.

Baddcog

10-08-2008 03:44:14

Thanks, I figured this out a little while ago.

I was doing everything to reset the scale. X-Form, reset scale in the hiearchy tab... the only way I was getting close was to attach a bone and scale the bone. But then the animations would rescale the bone when they ended. Weird stuff.

I have my units set to meters now as that's what the game calls for.

I ended up solving it by creating a cube, attaching, deleting the cube. It was a pain though, everytime I adjusted the scale or position even a fraction I had to attach a box again.
Now I have some objects at correct scale so it'll be easy in the future.

But I ended up having to delte some rigs and anims and start over from scratch, that was the ugliest part.

Thanks for the suggestion.

Evak

10-08-2008 18:31:47

yeah, Ofusion is reliable so long as you build your models correctly or reset xforms etc before rigging. I don't usualy bother with collapsing the stack or anything till right at the end these days. Just required modeling to scale from the beginning and almost never using the scale functions.

Baddcog

11-08-2008 00:10:14

Yeah, I'm deffinately starting close to sale now. I will probably always run through this process before export now.

Maybe i'm using X-form worng but it seems simple, I add the modifier and collapse the stack. Is that wrong? When I select the 'center' from Xform mod drop down the yellow cross is on the mid of grid.

Lioric

11-08-2008 13:58:39

The Reset X-form process must be used on non skeletal animated objects only, on objects that uses skeletal animation, you need to use the 'box trick' (search the articles in the support-center if you want a movie of this process or more details), as the animation modifier will mantain its own matrix after the reset xform has changed it and it might produce the incorret results