• Welcome to Battlezone Universe.
 

News:

Welcome to the BZU Archive dated December 24, 2009. Topics and posts are in read-only mode. Those with accounts will be able to login and browse anything the account had access granted to at the time. No changes to permissions will be made to be given access to particular content. If you have any questions, please reach out to squirrelof09/Rapazzini.

Main Menu

Animation question about 3DEX 1.5.5 XSI format verses X2XSI XSI format.

Started by BNG Da BZ Fool, May 18, 2008, 11:25:52 PM

Previous topic - Next topic

BNG Da BZ Fool

When I was able to convert X files to XSI using version 1.5.5 of 3DEX (don't waste your time with it after 30 days it stops working for converting files) I made a simple animated box looking thing. It animated just fine in the 3DEX player. Then after it stopped converting I fell back to using X2XSI which better preserves the XSI output format way better then BZ2ME ever did.

Anyways, the X2XSI utility was used to convert the same X file and it created an almost identical XSI conversion to that created by the 1.5.5 XSI converter it uses. It apparently translates animationset keys quite well compared to BZ2ME which does little more then add a template entry but no actual numerical data where its suppose to go in the file.

I noticed after doing a side by side compare of the 2 files in notepad that with the exception of a few numerical differences the layout looked almost the same. The major difference was that the 1.5.5 version actually animated but not the X2XSI version. Using the 1.5.5 version for reference I began to systematically make changes to the file in an effort to get it to animate, but to no avail. No matter how much I modified the X2XSI version I wasn't able to get it to conform to the animated 1.5.5 version to get it moving so to speak.

Does anybody know of a file comparison utility that I can use to analize the 2 files to log the differences between them? Something minor seems to be absent from the X2XSI version when compared to the 1.5.5 XSI version preventing it from actually showing the animation sequence as I see in the X2XSI version. What I do notice is the playback slider moves back and forth, but no actual animation is visable as with the 1.5.5 XSI file.

Like I said earlier, I made selective changes in notepad to get the 2 files to match as closely as possible and then saved the changes as I went along. Notepad, doesn't really format/wrap, but could the issue be that I need to use a pure text editor like Crimson? Tanks for any feedback guys...BNG.   
When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

General BlackDragon




*****General BlackDragon*****

OvermindDL1

For comparing text files, nothing beats a standard diff application, for windows get something like WinMerge.

And X2XSI is, as avatar put it, little more than a find/replace text app.

Generated by OvermindDL1's Signature Auto-Add Script via GreaseMonkey


BNG Da BZ Fool

If I wanted to try this file out in the map editor what data pack ODF file could I modfiy to test out my X2XSI file to see if it will animate? I think it'll work, but I always seem to be 2 cans short of a 6 pack in understanding how such things work as far as animation is concerned. Tanks, BNG. PS: Tanks OM. I'll checkout WinMerge.
When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

BNG Da BZ Fool

WinMerge is an intensely useful utility for not only comparing 2 different XSI files, but it also allows whole blocks of lines to be copied to either of the 2 files to make them identical if you wish. Kudos, OM and thank you very much for pointing me in the right direction. I plan to do quite a few file comparisons amongst the different X and XSI file formats. Now I can easily compare and modify known working XSI animated files to those created by X2XSI to maybe get them to animate properly. I think MTS would probably love this utility too as it's works quite well for text files in general.

I may be able to convert the current DOTXSI format back to the BZII version with some experimentation using the two Blender exporters; your version and the one that originally came with Blender. Still need read up on the capabilities of WinMerge, but it all looks promising overall...BNG.
When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

BNG Da BZ Fool

It appears that this XSI section is not required, but added by X2XSI by default:

SI_Angle {
   0;
}

SI_Camera  Camera1 {
   -6.311365; -0.886205; 0.415669;;
   0.000000; 0.000000; 0.000000;;
   0.000000;
   39.561378;
   0.100000;
   32768.000000;
}

SI_Ambience {
   0.000000; 0.000000; 0.000000;;

This section has extra spaces added in front of it unlike the animated XSI version produced by the 1.5.5 3DEX version:

  1;
  0;
  1;
  0;
  2;
  5;
  }

Copying the 1.5.5 version in it's entirety across to the X2XSI version using WinMerge produces an animated model, but does not tell me anything useful about why the X2XSI behaves differently then the working version at this point. I'm selectively modifying different sections to see which will eventually lead to a reason why it won't animate. It's just got to be something relatively minor yet correctable as the files look almost identical in WinMerge with a few exceptions
When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

BNG Da BZ Fool

This is interesting. As a test I only changed the following section in the X2XSI version and the cube actually started to animate:

AnimationSet {
   Animation {
      {CubeMesh-0}
    SI_AnimationKey {
        0;
        2;
        0; 4; 1.000000, 0.000000, 0.000000, 0.000000;;,
        10; 4; 1.000000, 0.000000, 0.000000, 0.000000;;;
    }
    SI_AnimationKey {
        1;
        1;
        0; 3; 1.000000, 1.000000, 1.000000;;;
    }
    SI_AnimationKey {
        2;
        2;
        0; 3; 0.000000, 0.000000, 0.000000;;,
        10; 3; -2.877881, 0.000000, 0.000000;;;
    }
  }
}

The problem seems to be in this section as all the other sections appear to be just fine without any modifications, so I'm guessing that X2XSI with modifications to the animationset section can make the model actually work.

I still need to take a closer at this section to determine what's going on that makes it not work when an X file with animation is converted using X2XSI. I'm going to spent the next few days basically just tinkering with the issue and I'll post again as I try to figure it all out. Kudos to Avatar for making this little gem in the rough...rough...LOL.

PS: It also appears the extra SI_Angle section (that X2XSI creates) can be left in the file along with the extra spaces in the header section as I mentioned the problem lies in the animationset section. A nice feature in WinMerge is that it also supports an UNDO feature, so if you screw up just hit the undo button to restore any changes you make to the X2XSI XSI file that you want to modify...BNG
When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

mrtwosheds

AnimationSet {
   Animation {
      {CubeMesh-0}
    SI_AnimationKey {
        0;
        2;
        0; 4; 1.000000, 0.000000, 0.000000, 0.000000;;,
        10; 4; 1.000000, 0.000000, 0.000000, 0.000000;;;
    }
This is a rotation animation,first value after SI_AnimationKey { = 0; it does not move, as there are no values changing.
    SI_AnimationKey {
        1;
        1;
        0; 3; 1.000000, 1.000000, 1.000000;;;
    }
This is a Scale Animation, first value after SI_AnimationKey { = 1; It will not work in BZ2.
    SI_AnimationKey {
        2;
        2;
        0; 3; 0.000000, 0.000000, 0.000000;;,
        10; 3; -2.877881, 0.000000, 0.000000;;;
    }
This is a Translation Animation, first value after SI_AnimationKey { = 2; It should move -2.877881 in some direction.
  }
}
All of these are being applied to CubeMesh-0, only the ones that work are really actually required.
The main issues I can  see are,
It has no name.(really useful if you want it script controlled)
eg

AnimationSet {
   Animation anim-spider {

It does not use frm- to identifiy the frame
eg

      {frm-spider}

AnimationSet {
   Animation anim-spider {
      {frm-spider}
      SI_AnimationKey {
         2;
         8;
         1; 3; 0, 3, 0;;,
         3; 3; 0, 3, 0;;,
         6; 3; 0, 3, 0;;,
         9; 3; 0, 3, 0;;,
         12; 3; 0, 3, 0;;,
         15; 3; 0, 3, 0;;,
         18; 3; 0, 3, 0;;,
         21; 3; 0, 3, 0;;;
      }
      SI_AnimationKey {
         0;
         8;
         1; 4; 1, 0, 0.0, 0;;,
         3; 4; 1, 0, 0.0, 0;;,
         6; 4; 1, 0, 0.0, 0;;,
         9; 4; 1, 0, 0.0, 0;;,
         12; 4; 1, 0, 0.0, 0;;,
         15; 4; 1, 0, 0.0, 0;;,
         18; 4; 1, 0, 0.0, 0;;,
         21; 4; 1, 0, 0, 0;;;

So I would make your example animation like this.

AnimationSet {
   Animation anim-bng {
      {frm-CubeMesh-0}
    SI_AnimationKey {
        2;
        2;
        0; 3; 0.000000, 0.000000, 0.000000;;,
        10; 3; -2.877881, 0.000000, 0.000000;;;
    }
  }
}



General BlackDragon

   SI_AnimationKey {
        1;
        1;
        0; 3; 1.000000, 1.000000, 1.000000;;;
    }
This is a Scale Animation, first value after SI_AnimationKey { = 1; It will not work in BZ2.


It doesnt work? :'(



*****General BlackDragon*****

mrtwosheds

I experimented, scale animations that work in 3dex have no effect at all in bz2, presumably scale animation was not implemented in bz2 as vertex animation could achieve the same result...

OvermindDL1

Exactly, vertex animation can emulate any other form of animation.  Although that does not really fully explain why rotation and such is and scale is not, just an old ancient design decision, probably a holdover from one of the older engines BZ2 engine came from.

Generated by OvermindDL1's Signature Auto-Add Script via GreaseMonkey


Nielk1

Sure glad rotation animation is possible as I have not found a way to vertex animate with max.

Click on the image...

BNG Da BZ Fool

As I also mentioned earlier, I'd like to try a simple animation test in the map editor using a simple modified ODF file to check things out for myself. Could someone please suggest a single animation file to use for this purpose? Something like say the ISDF power generator or other simple one animation ODF file. Nothing personal, but I don't initially accept the can not do in the game thingy statement, and would like to see for my self whether or not it can be done.

I also have a lot to learn about animation and still don't quite understand what I'm doing at present, and considering the very few animation options currently available to the average modeler; would like to see where this leads. I'm sure there are other modelers that feel the same way as well. Most of us are just looking for another alternative way to make animated models for the game.

I see Directx as a more viable option then working with the current Dotxsi format which sadly isn't back wards compatible with the version supported by BZII. My searching for alternatives always seems to lead full circle back to the X format converted somehow to several versions of XSI variants. Each with some desirable qualities, but all missing the mark of actually working in the game. Truly frustrating overall, yet intriguingly worthy of more experimentation. It's almost like the search for the Holy Grail...I must possess it, or crash-n-burn in the attempt to obtain it...BNG 



When I'm not in hot water with the community I'm usually making models for BZII. I've made a few models for other peeps. BNG.

mrtwosheds

In my experimentations, the most common reasons for an animation not working are usually just simple things like the animation frame name not being exactly as it is in the model, you might call a frame and animation  {CubeMesh} but the modeling program decides it should be     {CubeMesh-0}. Not getting the odf entrys right is another frequent mistake I make, just forgetting to change the animCount is one of my usual errors.
It is also important to make sure that the right number of {} are present, loosing one will stop it working.

The odf you use would depend on what you want the anim to do, the pwrgen is good for a static building loop type anim.
A GT would be good for a deploy type anim. There are limitations on what animations each class will do, buildings do not do forward, back strafe...


QuoteNothing personal, but I don't initially accept the can not do in the game thingy statement, and would like to see for my self whether or not it can be done.
It is good to be inquisitive, I hope you find a way to do it, as I would really like to use them. There are no scale Animations in any of the stock models, or others that I have seen. I do not think that their presence will cause a problem however.


Nielk1

And remember, if an animation is not working correctly try including position key frames into more of the model.

Click on the image...