XSI ZETools

How to create models in XSI and other 3D applications and make them work in Battlefront 1 & 2. Post models, tips for application usage and share anything XSI, 3DMax, SketchUp, etc.

Moderator: Moderators

Post Reply
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

Press the script/scroll button on the bottom of the screen. That opens the script editor. Then copy the red text and paste it here. Take a look at the guidelines. You can find a link to the guidelines on the first page of this thread/topic.

Without your msh info tool a lot of this would have taken a lot longer. I often have four different .msh files open at the same time to compare struucture.
sereja2
Command Sergeant Major
Command Sergeant Major
Posts: 253
Joined: Wed Aug 31, 2011 4:22 am
Projects :: Naboo Otoh Gunga
Games I'm Playing :: swbf 1
xbox live or psn: No gamertag set
Location: Ukraine

Re: XSI ZETools

Post by sereja2 »

I probably still missing something in guideline...

Code: Select all

XSIZETools
' ERROR : 2000 - File not found - C:\users\Serejenka\Autodesk\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Application\Logic\zetools.py
' ERROR : Traceback (most recent call last):
'   File "<Script Block >", line 468, in MSHExport_Execute
'     import andezetcore
' ImportError: No module named andezetcore
'  - [line 467 in C:\Softimage\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Application\Plugins\XSIZETools.py]
' ERROR : OLE error 0x80020101
MSHExport
MaterialEdit
' WARNING : 3000 - The file C:\users\Serejenka\Autodesk\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Resources\UI\material_icon_zetools.bmp could not be found or is not a valid .bmp file.
' ERROR : 2000 - File not found - C:\users\Serejenka\Autodesk\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Application\Logic\material_manager.py
' ERROR : Traceback (most recent call last):
'   File "<Script Block >", line 325, in ZETHelp_Execute
'     import andezetcore
' ImportError: No module named andezetcore
'  - [line 324 in C:\Softimage\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Application\Plugins\XSIZETools.py]
' ERROR : OLE error 0x80020101
ZETHelp
manageExpansions
' ERROR : 2000 - File not found - C:\users\Serejenka\Autodesk\Softimage_Mod_Tool_7.5\Addons\XSIZETools\Application\Logic\expansion_manager.py
User avatar
tirpider
Lance Corporal
Posts: 97
Joined: Fri Nov 25, 2011 3:58 pm

Re: XSI ZETools

Post by tirpider »

ANDEWEGET wrote:Without your msh info tool a lot of this would have taken a lot longer. I often have four different .msh files open at the same time to compare structure.
One of these days I will finish that program so that it actually translates all the structures instead of just identifying them. After that, I'll probably never touch GUI programming again. (hehe)
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

ANDEWEGET wrote:@sereja2: Make sure you unpacked the archive to C:\users\Serejenka\Autodesk\Softimage_Mod_Tool_7.5\Addons. Note that the last release might not work with the mod tool. It has some problems which hopefully will be fixed for the next release(that one will have animations).

Maybe I should add something to catch that problem and pop up a message...

@tirpider:
IIRC it only doesnt display animation chunks right. For every other chunk it displays unpacked data(which isn't always 100% correct but it does its job). It's, like, the perfect middle-'thing' between the MSH Viewer and my trusty XVI32. :D
Added the new version with animations to the first page. The dispatch problems should be fixed. I'm not certain tho.
Changelog:
1.1.11.02:
  • If ZETools is installed in the wrong dir(ie XSI factory addon dir)it will notice it. It can automatically copy the needed files to the right directory.
    Exporter: Animations done(until I find the next bug).
    Exporter: Option to only export current frame and next one as basepose for animations.
    Various smaller bug fixes(especially for the Mod Tool).
I didn't test animation a lot so there could still be problems. I can't think of any problems there might be but who knows... Batch export should be possible with animations(wouldn't be very useful as it always exports the same frame range). If someone has wishes for functions/options/jawas please post them.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

Awesome, thanks for sharing!

Wouldn't "Export current frame" only be a single frame? It sounds like you have it exporting 2 frames, the current and next? I think folks only use the 0-1 timeline advice for basepose export because XSI won't let you set it to 0-0 or 1-1.

I just created a test scene in Mod Tool for a simple animated prop which kept crashing ZE when trying to place it. As a simple prop it worked fine. The same scene worked fine when exported with the Pandemic Tools(animations and all). I have no errors to report here.

The scene was just a null(dummyroot) keyed on the first and last frame
a child null animated in a circular motion keyed on 28 frames(plotted from a path constraint)
a cube with cubic UVs enveloped to the animated null with 100% weighting
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

Yeah, I was too lazy to test if it works with just one frame so I export 2 frames... :D
I'll test it some day but I wanted to get it out for now to get more testers and have a backup online. The similar named check box in the Pandemic Exporter doesn't seem to do anything so I couldn't know without testing.

Did you place the .msh with the animation in ZE? I always only placed a .msh without animations(and nulls as bones, I only tested exporting animations with nulls)in ZE. I'll have a look at that this weekend.

My setup while testing:
DummyRoot, not keyed
----bone_root, keyed on last and first frame
--------bones(always nulls, didnt test bones yet)
----mesh(es)
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

ANDEWEGET wrote:Did you place the .msh with the animation in ZE?
It crashed when trying to load it, it never got far enough to be placed. The preliminary animation munge didn't spit out any errors. ZE doesn't care about the animations anyway, there is something about the main msh that it doesn't like.
ANDEWEGET wrote:My setup while testing:
DummyRoot, not keyed
----bone_root, keyed on last and first frame
--------bones(always nulls, didnt test bones yet)
----mesh(es)
Does your exporter expect this particular setup? I haven't tried using bone chains yet since I couldn't get the test scene to work with nulls. I'll mess around with it a bit more later.



EDIT
ANDEWEGET wrote:If ZETools is installed in the wrong dir(ie XSI factory addon dir)it will notice it. It can automatically copy the needed files to the right directory.
You might need to tweak this or suppress/remove it. I have everything installed in the correct location but this popup nags me everytime I launch Mod Tool.
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

ZE could crash because my exporter doesn't write the animation chunks perfectly so ZE can't read it. ZE's reader doesn't seem to be as robust as modelmunge. So it might work if you place a .msh without any animation chunks.

The exporter doesn't really expect anything... I didn't really test anything else tho.

EDIT: Could you give me the path you installed the plugin in?
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

ANDEWEGET wrote:ZE could crash because my exporter doesn't write the animation chunks perfectly so ZE can't read it. ZE's reader doesn't seem to be as robust as modelmunge. So it might work if you place a .msh without any animation chunks.
I'm not sure what you mean here, there is no animation in the msh to be placed, just the object hierarchy. Animations are in separate files which aren't read until runtime.
EDIT: Could you give me the path you installed the plugin in?
C:\users\Ace\Autodesk\Softimage_Mod_Tool_7.5\Addons\XSIZETools
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

No. :) Usually the .msh contains HEDR, then all meshes/cloth/nulls etc in the MSH2 header. If you export animation you have exactly the same but animation chunks like ANM2, SKL2 etc get added to the other stuff.
So 3d geometry etc are in the same .msh as the animations. In the .msh files there is no separation between them. If you export with animations the animations are in the .msh file.
The models you place in ZE should not be exported with Export Animation checked. That checkbox should only be used for the actual animations and the basepose.

About the path checking thing: It doesn't work right on yours because I only search for 'Users' not 'users'... I'll fix that in the next one.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

ANDEWEGET wrote:So 3d geometry etc are in the same .msh as the animations. In the .msh files there is no separation between them. If you export with animations the animations are in the .msh file.
Yes, but you shouldn't be exporting geometry along with the basepose and animations.
ANDEWEGET wrote:The models you place in ZE should not be exported with Export Animation checked. That checkbox should only be used for the actual animations and the basepose.
I know this, and they weren't. Like I said, these same files exported with the Pandemic Tools worked fine. The scenes were identical, but the msh exported with ZETools caused ZE to crash before it loaded. The msh to be placed in ZE was not exported with any other options ticked. I hope we're on the same page now. :)
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

As far as I could see in the munged animation files the anim munge ignores geometry anyways so it shouldn't be a problem to export geo with it.

I hope we are. :D
If the model crashes ZE without you having Export Animation checked tells me that it doesn't have to do with the actual animation export but something else(maybe left over chunk parts from the animation chunks or whatever).
I'll see if I can reproduce the problem. It would be nice if you could provide the .msh which crashes ZE tho. I might be doing something which prevents the exporter from breaking the .msh without knowing it...
Thanks for the testing BTW! ;)
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

ANDEWEGET wrote:As far as I could see in the munged animation files the anim munge ignores geometry anyways so it shouldn't be a problem to export geo with it.
Geometry will cause crashing during the preliminary animation munge under the right circumstances, you can eliminate this possibility by omitting the geometry from the export. Samples sent for comparison.

Edit
I just tried another attempt with a simpler up and down animation and this time it loaded into ZE and worked in game. I didn't do anything different regarding exporting from earlier, this is weird. I'll try some fresh scenes at different complexities and see if it still happens regularly.

Here's what I did when exporting:
Branch selected the entire hierarchy then exported as somename
while still branch selected, exported animation as idle(for animated prop) with only "Animation" ticked
while still branch selected, exported basepose with "Animation" and "Current frame as basepose" ticked


I'm interested in seeing the results from others who are testing this new version and if they encounter this too.
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

Hmm, interesting...
Did you make exactly the same keyframes(on the same frames)?
You said you used a path constraint for the first animation and then plotted it, how did you animate the second one? Ill try to get something with a plotted animation working in the next day(s).

EDIT: BTW, it's not necessary to branch select anything with my exporter. It's designed so that you only select the root and then export. It will automatically export all children.

EDIT2: I think I found the problem. Did you name the animated null bone_* or *_bone? Animated nulls need to have MTYP(model type) 3(bone) to work. My tests worked because I always named the bones bone*. That should be easily fixable, I just have to check if somethings enveloped to it.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: XSI ZETools

Post by AceMastermind »

Did you make exactly the same keyframes(on the same frames)?
You said you used a path constraint for the first animation and then plotted it, how did you animate the second one?
No, the test that worked only had 3 keys over 30 frames(1-15-30) and was hand keyed.
The test that didn't work had a key on 28 of 28 frames from the plotting.
Plotting shouldn't make a difference since the end result is the same as keying manually. I think I plotted "All Transformations" which were really only X and Y transforms. I'll try this again later today in a fresh scene.
BTW, it's not necessary to branch select anything with my exporter. It's designed so that you only select the root and then export. It will automatically export all children.
Yeah, this is a habit from using the Pandemic tools for so long. :)
Did you name the animated null bone_* or *_bone? Animated nulls need to have MTYP(model type) 3(bone) to work. My tests worked because I always named the bones bone*. That should be easily fixable, I just have to check if somethings enveloped to it.
The animated null was left named "null" in the test that didn't work.
The animated null was named "bone" in the test that did work.


Edit
Could you add support for lambert materials?

Edit2
I recreated the first test in a fresh scene and did everything the same except this time I named the animated null to "bone", and this worked. It was the naming that caused the export to bork which in turn broke the msh. Now i'll try animating some bone chains and see how that goes!
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

I didn't know that a null could break the .msh if it is enveloped to but not declared as bone. That's why I was lazy and just checked for 'bone' in the name of the null and declared it as bone if it found the substring.
Now I(would) check if the null is in a global list of deformers which are used in envelopes and then set the model type from there(if I hadn't broken the exporter somehow, weird error...). So naming shouldn't be a problem then.
The problem with the installation dir pop up is fixed.

AFAIK there's only one difference between the Phong and Lamber materials in XSI(which affect the exporter), the shiny/Spec Decay parameter. So exporting Lamberts shouldn't be a problem if I handle that right.
I hope I can get that done tomorrow. Otherwise I'll try to do it towards the end of the week.
User avatar
minilogoguy18
Master Bounty Hunter
Master Bounty Hunter
Posts: 1512
Joined: Wed Nov 09, 2005 11:12 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set

Re: XSI ZETools

Post by minilogoguy18 »

With the Pandemic exporter you can use geometry as bones even and it'll work, if it's something that has a mesh enveloped to it then the exporter recognizes it as a bone. Detail of the bone is irrelevant since it only takes the transform values and keyframe info.
User avatar
ANDEWEGET
Ancient Force
Ancient Force
Posts: 1266
Joined: Tue Apr 01, 2008 8:42 am
Location: Germany
Contact:

Re: XSI ZETools

Post by ANDEWEGET »

ANDEWEGET wrote:Yeah, that's what I'm gonna do now, too.
I think I fixed all problems(at least the ones I know of) and added support for Lamberts. If you get around to animating something more complex Ace, please report back how it goes!

EDIT: The path checking thing at startup now compares the path it should be installed in and the path it is installed in. If the path matches more than 14 characters I assume it's the right path.
Quick question(mostly to Ace): Did you test some more? I'll be off to Ireland for two weeks from tomorrow, if you didn't find any problems I'll just release the tweaked version tonight. That one will have to do for those two weeks.

EDIT: Uploaded the tweaked version. Most likely still has bugs but it should work. :)
sereja2
Command Sergeant Major
Command Sergeant Major
Posts: 253
Joined: Wed Aug 31, 2011 4:22 am
Projects :: Naboo Otoh Gunga
Games I'm Playing :: swbf 1
xbox live or psn: No gamertag set
Location: Ukraine

Re: XSI ZETools

Post by sereja2 »

It realy work's, but not exactly, how I may expect... Here is my "postmodern arts" sample:
Hidden/Spoiler:
Image
This interpritations of my doors look's fun, but totaly crash in game. Any other props crash too.
Well, there is no "red lines" errors, but, may be this script (from other scene) contain some error anyway?:

Code: Select all

SelectObj "null"
ToggleSelection "bottle_juma_juice"
MSHExport
CGA_GetNodeVertexPositions "polymsh", True
CGA_GetNodeNormals "polymsh"
CGA_GetNodeIndices "polymsh"
CGA_GetPolygonVerticesCount "polymsh"
CGA_GetUV0 "polymsh"
CGA_GetPolyIndicesPerMaterial "polymsh"
CGA_GetMaterialNames "polymsh"
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: XSI ZETools

Post by kinetosimpetus »

Just got it installed on my modtool.

Successfully exported a weapon msh, but got this error log on a unit animation.
Hidden/Spoiler:
[code]' INFO : XNA.xsitemplate is up-to-date
' INFO : 4034 - Loaded scene was created with build number: 7.5.2009.0409 - compatibility version: 1073742125
OpenScene "C:\Softimage\Softimage_Mod_Tool_7.5\Addons\ModTool_Database\Scenes\anims\carbine_stand_idle.exp"
SelectObj "DummyRoot"
MSHExport
SetValue "MSHExport.anim", True
' INFO : 4000 - Drive 'e:' marked as invalid for the next 300 seconds
'
SetValue "MSHExport.mshpath", "C:\Users\Kinetos\Desktop\ZETOOLSEXPORTS\1.msh"
CGA_GetNodeVertexPositions "polymsh", True
CGA_GetNodeNormals "polymsh"
CGA_GetNodeIndices "polymsh"
CGA_GetPolygonVerticesCount "polymsh"
CGA_GetPolyIndicesPerMaterial "polymsh"
CGA_GetMaterialNames "polymsh"
CGA_GetNodeVertexPositions "polymsh", True
CGA_GetNodeNormals "polymsh"
CGA_GetNodeIndices "polymsh"
CGA_GetPolygonVerticesCount "polymsh"
CGA_GetPolyIndicesPerMaterial "polymsh"
CGA_GetMaterialNames "polymsh"
CGA_GetNodeVertexPositions "polymsh", True
CGA_GetNodeNormals "polymsh"
CGA_GetNodeIndices "polymsh"
CGA_GetPolygonVerticesCount "polymsh"
CGA_GetPolyIndicesPerMaterial "polymsh"
CGA_GetMaterialNames "polymsh"
' ERROR : Traceback (most recent call last):
' File "<Script Block >", line 36, in exportbutton_OnClicked
' export.export()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 680, in export
' self.do_export()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 729, in do_export
' self.msh.animation = anim.convert()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 85, in convert
' bonecoll.add(boneconv.convert())
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 52, in convert
' for n in range(self.anim.anim.cycle.frames[0], self.anim.anim.cycle.frames[1] + 1):
' TypeError: range() integer end argument expected, got float.
' - [line 35 in C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZETools\Application\Logic\exporter.py]
' ERROR : Property Page Script Logic Error (Python ActiveX Scripting Engine)
' ERROR : [33] params.preview()
' ERROR : [34] export = andezetexport.Export(xsi, params)
' ERROR : >[35] try:
' ERROR : [36] export.export()
' ERROR : [37] except SystemExit:
' ERROR : [38] return
' ERROR : Traceback (most recent call last):
' File "<Script Block >", line 36, in exportbutton_OnClicked
' export.export()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 680, in export
' self.do_export()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 729, in do_export
' self.msh.animation = anim.convert()
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 85, in convert
' bonecoll.add(boneconv.convert())
' File "C:\Users\Kinetos\Softimage\Softimage_7.5\Addons\XSIZEtools\Application\Core\andezetexport.py", line 52, in convert
' for n in range(self.anim.anim.cycle.frames[0], self.anim.anim.cycle.frames[1] + 1):
' TypeError: range() integer end argument expected, got float.
'
[/code]
The skeleton is the one from the unit template beta that's been around as long as I can remember
Post Reply