Tomb Raider Forums  

Go Back   Tomb Raider Forums > Tomb Raider Level Editor and Modding > Tomb Raider Modding > XNALara

Reply
 
Thread Tools
Old 14-05-11, 16:15   #1
mariokart64n
Member
 
mariokart64n's Avatar
 
Joined: Jul 2006
Posts: 339
Default XnaLara for 3dsmax

Maxscript for importing and exporting geometry between 3dsmax and xnalara.
maxscripts tested on 3dsmax8-3dsmax2012 should work across all versions of max past v8(2005).

Videos are included below to give an idea of script operation. but are not made to teach you 3dsmax.
scripts are designed with the assumption that the user is already capable in 3dsmax.

Please leave feedback if you have an idea that would benefit the script.

-mariokart64n
"mario_kart64n(at)hotmail(dot)com"


MaxScript - XnaLara Import/Export
https://dl.dropbox.com/u/86746436/Ma...20Converter.ms (Updated: March 07, 2016)


VIDEO Complete Xnalara Import/Export Script:


VIDEO XNALara (Beginners Tutorial for 3dsmax):


[OUTDATED] VIDEO (Importing Models From XNALara to 3DSMAX):


[OUTDATED] VIDEO (Exporting Models From 3DSMAX to XNALara):





DeleteDoubleFaces: http://www.mediafire.com/?3dmab8ej93b9faw

OLD SCRIPTS
Quote:
MAXSCRIPTS:
Mesh Importer: http://www.mediafire.com/?z2vbc4lbbobtlwk
Ascii Exporter: http://pastebin.com/1p7GKNhg
Xnalara Converter (Updated: August 2, 2011):http://www.mediafire.com/?139hxd1wb2cbf4j

Features Yet to be added, will be included with UserInterface
Import:
- Ascii Import Support
- Ascii Editor (Reassign Textures/Rendering Group)

Export:
- Copy Materials on Export (Copies any textures used on the model to the export path)
- Fix Error with Reading Instanced Modifiers
- Multiple UV Support
- Actual Normal Recalulation
- Project CleanUp (Removes unused assets from the Project Folder)
- Add diffuse colour pickup on material gathering (export this if no diffuse map)

Notes / Research:
Mesh Spec:
http://xnalara.svn.sourceforge.net/v...=3&view=markup
http://xnalara.svn.sourceforge.net/v...=3&view=markup


EDIT2
DOWNLOAD SCRIPT: (May31,2011) OUTDATED
http://www.mediafire.com/?z2vbc4lbbobtlwk


DOWNLOAD DeleteDoubleFaces SCRIPT: (By Bobo)
http://www.mediafire.com/?3dmab8ej93b9faw

Last edited by mariokart64n; 08-03-16 at 03:34.
mariokart64n is offline   Reply With Quote
Old 15-05-11, 10:14   #2
Ventrue
Member
 
Ventrue's Avatar
 
Joined: Sep 2010
Posts: 676
Default

Quote:
Originally Posted by mariokart64n View Post
Bone Limit 59?
For just one meshpart... According to Dusan, that's the hardware limit, or s/t like that. If you separate the mesh you can have as many bones as you want. (My Bayonetta port has like 300 bones. )

Anyway... You can still contact XNAaraL on deviantART.

Last edited by Ventrue; 15-05-11 at 10:15.
Ventrue is offline   Reply With Quote
Old 15-05-11, 14:32   #3
mariokart64n
Member
 
mariokart64n's Avatar
 
Joined: Jul 2006
Posts: 339
Default

great, then its 59 per mesh piece. otherwise theres no limit, just as long as the persons hardware holds up to XXX amount of bones right?

next, are there mesh limits?

also important how are textures detected?

the paths are like: data/somewhere/mytexture_diffuse.png

1. can I ignore paths, and only state texture name.
2. can I assume that name descriptors are always present.
example: eye_diffuse.png, eye_lightmap.png
the only way I can determine a texture from each other is by reading the name "diffuse" of "lightmap"
without that, there is no other indicators in the mesh or ascii format.

I need more info on the generic format, i know that alot of the meshes are hardcoded.. so you cannot alter the meshes order or the bone order. however its possible the generic mesh type bypasses these limitations. and if it does not follow descriptors then I have to rethink the texture type detection
mariokart64n is offline   Reply With Quote
Old 15-05-11, 14:43   #4
sn00p
Member
 
sn00p's Avatar
 
Joined: Nov 2008
Posts: 1,281
Default

I doubt there's mesh limit, even if it's gotta be high, since some Lara models are with 40/50 meshes.

About the paths, I guess they can be ignored if they are in the same folder as the .mesh file, Blender export the file with the full path to texture but while editing the .mesh.ascii you can let just Texture_Diff.png and will work fine.

Uhm not everyone use _diffuse/_diff or w/e is it when they release something, but I guess wouldn't hurt to be a "standard" and it's aesthetic tho.
sn00p is offline   Reply With Quote
Old 15-05-11, 15:00   #5
Ventrue
Member
 
Ventrue's Avatar
 
Joined: Sep 2010
Posts: 676
Default

I was thinking about the textures' detection. I think it depends on the order in the mesh.ascii. For example: There's a meshpart with a diffuse, a specular, a bump and with a lightmap. It will start like this in the mesh.ascii:
Code:
25_meshname
1 # uv layers
4 # textures
diffuse_map.extension
0 # uv layer index
lightmap.extension
0 # uv layer index
bump_map.extension
0 # uv layer index
specular_map.extension
0 # uv layer index
There's a different order for every rendergroup though...

http://www.tombraiderforums.com/show...postcount=1735

Last edited by Ventrue; 15-05-11 at 15:11.
Ventrue is offline   Reply With Quote
Old 15-05-11, 15:11   #6
sn00p
Member
 
sn00p's Avatar
 
Joined: Nov 2008
Posts: 1,281
Default

Yea the order for each group can be found here http://www.tombraiderforums.com/show...postcount=1735
sn00p is offline   Reply With Quote
Old 15-05-11, 15:12   #7
Ventrue
Member
 
Ventrue's Avatar
 
Joined: Sep 2010
Posts: 676
Default

Quote:
Originally Posted by sn00p View Post
Yea the order for each group can be found here http://www.tombraiderforums.com/show...postcount=1735
Just added that link to my post... xD
Ventrue is offline   Reply With Quote
Old 15-05-11, 15:14   #8
mariokart64n
Member
 
mariokart64n's Avatar
 
Joined: Jul 2006
Posts: 339
Default

I don't understand what are these groups?

is this for the hardcoded mesh files or the generic format?

if I understand correctly group 1, which is mesh 1, does diffuse, bump, light
but mesh 2 only does diffuse, bump.. something to that effect?
mariokart64n is offline   Reply With Quote
Old 15-05-11, 15:39   #9
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default

These groups are used in generic meshes.
They tell how many textures go on one mesh part and wich ones. The order of the listed textures is quite important there^^

for eg render group 1_ wants 6 textures they have to be listed like : diffuse, lightmap, bump, mask, minibump1, minibump2

but this changes with the render groups for eg 6_ only needs 2 textures listed like: diffuse, bump

but well mesh 1 doesn't have to be render group 1. you can use every render group you want on any mesh you want....

Last edited by o0Crofty0o; 15-05-11 at 15:40.
o0Crofty0o is offline   Reply With Quote
Old 15-05-11, 15:42   #10
mariokart64n
Member
 
mariokart64n's Avatar
 
Joined: Jul 2006
Posts: 339
Default

ok so that list is only relating to the generic format. and what does groups mean?

a group of meshes..

mesh1, mesh2, etc..

or mesh1 is group1?

I'm scripting up the material section of the importer now, after thats done max import will be working.
mariokart64n is offline   Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT. The time now is 19:01.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Tomb Raider Forums is not owned or operated by CDE Entertainment Ltd.
Lara Croft and Tomb Raider are trademarks of CDE Entertainment Ltd.