Tomb Raider Forums  

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

Reply
 
Thread Tools
Old 23-11-10, 15:34   #1
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default How to get a Umodel File work in XNALara - Full Tutorial

How to get a Umodel File work in XNALara

(Don't use this, when you don't know anything about such things!)


Stuff you need:
- A Game wich is supported by ''Mesh'' and ''Tex'' on this list, if you're totally new to this kind of stuff please use this file instead.Since it's the one where I'll explain evrything on.
- The Unreal Model Viewer (by Gildor, you can get it here
- Blender (From here, please take the older Verson (2.49))
- The following scripts and converters (by XNAaraL): Theswe tools aren't available on TRF anymore I think you still fid them on ************************* (hosted by AtlantiB)
- 3ds Max (DEMO available here)
- ActorX Import Scripts for 3ds Max (Download here, I think it's a installer. Say that it should run the script by startup.)
- Blender .SMD Importer (here, slightly altered by my dad xD to get it work with some files^^ Dunno what exactly he altered but they work better now)
- 3ds Max .SMD Exporter Scripts (here, put into plugin folder)
- Total Commander (here, if you can perfectly deal the ''Command'' window, you don't need it, but sometime the cmd window gives strange errors, wich don't appear if you use this. My tutorial will be made with this.)




First of all, make a new folder somewhere where you'll find it again easily.
Extract the ''char_lilith.zip'' into that folder, so you'll get file with the extension ''.upk''.
Also place the 3 files of umodel in that folder.

Now run Total Commander. Open your folder in it:

(Should look somehow like this. (left side, right is just my always opened, messy data folder ))

Type in ''cmd'' in the bottom bar of the window:


Hit enter, a command window will popup, type in the following:

(It's a umodel command, noAnim just means that it won't extract animation files, because we don't need them.)

Once again, hit enter and some stuff will happen in the command (cmd) window. Wait until it stops doing anything and take a look into your folder. Umodel created a new folder with all extracted files:


This is what's in there:

We'll only work with the ''Skeletal Mesh'' and ''Texture2D'' files.

Now open 3ds Max. (If you don't have it, but want models anyway, feel free to give me the .psk files and i'll convert them for you =))
If you did evrything like i said above, a ActorX Importer window should pop up right when you start 3ds Max.
Click on ''Import .psk'' and search for your ''SkeletalMesh'' folder. Select the file in there. And hit ''Open''.


Your model will be in there. Please don't edit anything, since that MIGHT cause errors later. Now click ''Rendering''> ''Render'' until a window with ''Mising Map files'' will pop up:



Rename ''lilith_body_d.tga'' and ''lilith_head_d.tga'' to the names listed in the ''Missing map files'' window:


Click ''File''> ''Export'' and search for your Texture2D folder. As extension take .SMD:


Hit ''Save''. Just hit ''Ok'' on evry of the following windows. It's really important that all the textures are in the same folder as the .smd file. Open Blender.
Click ''File''> ''import''> ''Half Life 2 Mesh *.smd'' .
Select ''Static .smd with textures, and search for your .smd file. Click ''Import'' and wait (this can take up to 4 minutes, but not that long for the mesh i uploaded) When it's imported you can zoom out with the mouse wheel, turn the camera around by using 8, 4, 6 and 2 on the notepad, and shift and ctrl + mousewheel to move upwards/downwards and right/left-wards.
get a good front view of your model and turn the textures on:


Select (by right click) one of the little black points underneath her feet. That's the skeleton. When it gets pink, it is selected and you get some options in the bottom toolbar. Set it to ''X-ray'':



Switch to ''Pose Mode'':



Zoom, until you get a pretty good view on the arm areas. Select the elbow bone by right clicking. Also select the ''rotate'' tool. You can see it on the image below. Rotate the bone by click, hold and move one of the ''lines'' of the round thingy around the bone (the rotate tool). You se that it gets kinda weird (IMPORTANT NOTE: This doesn't happen to ALL Umodel models! Mass Effect 2 ones work right! So skip this part! Bioshock 2 ones do aswell^^):


But we can see that the ''broken'' area moves with this twist bone:


So we need that bone to move when the other does. We'll change the father bone of this. Let it selected and switch to ''Edit Mode'' (in the same list as ''Pose Mode''). In the bottom toolbar you'll do the following:


After that it moves just fine:


* repeat these steps to the right side. But don't forget to choose ''Bip01_R_Forearm'' instead of the left one!

In ''Pose Mode'' hit ''W''. That'll reset all bones.

(All following has to be done for the Mass Effect 2, Bioshock 2,... models aswell!)

Go back to ''Object Mode''. Hit ''A''. After that select the mesh. (right click, you know) and click ''File''> ''Export''> Wavefront *.obj''. Export it to your Texture2D folder with these settings:


Right after that Import that .obj again with these settings (IMPORTANT is that the ''Clamp Scale'' is set to 0.00''):


The .obj will be at the exact same position like your .smd mesh. But just don't move anything. Only hit ''A'', until all has a pink stroke. Then click ''Object''> ''Scripts''> ''Bone weight copy'' in the lower toolbar:

(That'll take a bit time. You can see it's process in the right upper corner. It's ready if that ''www.blender.org'' bar gets all green again and actual says ''www.blender.org''.)

After that is done, select the .smd mesh. (ONLY mesh) you can see the mesh's name in the left lower corner. When it says ''model'' hit ''X'' and erase it.

XNALara has a ''bones per mesh part'' limit. I think it's by 69, but i'm not sure.
Actual we don't have to know. We only have to seperate a few things on the mesh. So. Select one of the two model parts. I'll show how it work on the body one. Well you select it and enter ''Edit Mode''. After that you hit ''A'' so evrything gets deselected. Now press ''B'' and draw that box over the half of the mesh part:



Now press ''P'' and select ''Selected''. The selected part gets seperated. Do this process also to the other mesh part. (Face one)


After that click ''File''> ''Export'' > ''MeshAsciiExt (*.mesh.ascii)'' and place it in your Texture2D folder. Name it ''generic_item.mesh.ascii''. It should export just right.

Before we go on now.....create a new folder in your XNALara data folder with the name of the model. (For example ''Lilith_Borderlands'').
Copy these files in that folder:


Now we can start editing in Notepad.
Open the generic_item.mesh.ascii in notepad.
An change the bone number from 61 to 59:


Now hit CTRL + F and type in ''Tex''. It'll direct you to lines wich say ''Textures''. Our mesh parts have two textures and no transparency that means we add a 4_ in front of the name. Also remove every underscore in the name (''_''). Type _0.1_0_0 at the end of the part's name.
And change 1 # Textures to 2 # Textures:


After that we have to apply the bump maps. ''lilith_body_n.tga'' is the body bump map.
Under the ''0 # uv layer index'' type in:
lilith_body_n.tga
0 # uv layer index :



Well do that to all results that searching for ''Tex'' gives you.
But take care! There are parts that need the head bumps and not the body ones.

When all is done. Open your generic_item.mesh.ascii with ''GeMeshAsciiToBin.exe'' and let it convert.

Now you can open the model in XNALara. It'll appear very huge so just scale it to 0.01 and export it as .mesh.ascii by hitting F11. Convert it again and it'll work.



Before you release such a model, please rename the bones, since there are people out there that want to load poses on your model. (I personally don't care about unrenamed bones).

A note to renaming bones: You can do it in notepad. Evry bone is listed there and you just chang it to Lara's ones. bones that are useless get a ''unused_'' in front of them. So they won't appear in XNALara.


A note to Batman Arkham Asylum models: These models are extremely fuued up. So don't take such models if you do this the first time. I can give you instructions if you get errors of that models, but only if you at least did this one time.


Also i have to thank two persons here:
CarbinT - who told me about the .smd format (and YES i asked him and i AM allowed to talk about that here)
Sn00p - for telling me about the Unreal Model Viewer (Umodel)





IMPORTANT: This is no request thread. Feel free to ask questions about the process, but please don't about the Command window. I don't know anything about it at all, and well, it works in the method i explained.

o0Crofty0o - 23.11.2010

Last edited by o0Crofty0o; 20-06-11 at 11:00.
o0Crofty0o is offline   Reply With Quote
Old 23-11-10, 15:42   #2
dizzydoil
Inactive
 
Joined: Oct 2006
Posts: 11,312
Default

Beautiful tutorial, lovely setup and easy to understand.
dizzydoil is offline   Reply With Quote
Old 23-11-10, 18:36   #3
KamilM_93
Member
 
KamilM_93's Avatar
 
Joined: Jul 2007
Posts: 7,755
Default

Unreal Model Viewer doesn't work on Windows 7
KamilM_93 is offline   Reply With Quote
Old 23-11-10, 18:36   #4
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default

Quote:
Originally Posted by dizzydoil View Post
Beautiful tutorial, lovely setup and easy to understand.
Thank you
I'm glad that it's understandable somehow XD
o0Crofty0o is offline   Reply With Quote
Old 23-11-10, 18:46   #5
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default

Quote:
Originally Posted by KamilM_93 View Post
Unreal Model Viewer doesn't work on Windows 7
Uhm i have windows 7 and it just works right^^
Is there any error?
o0Crofty0o is offline   Reply With Quote
Old 23-11-10, 18:49   #6
KamilM_93
Member
 
KamilM_93's Avatar
 
Joined: Jul 2007
Posts: 7,755
Default

Quote:
Originally Posted by o0Crofty0o View Post
Uhm i have windows 7 and it just works right^^
Is there any error?
Nope... I open UMV and closes... without error... I extrac this file to:

"G:\Program Files\EA Games\Mirror's Edge\Binaries"
KamilM_93 is offline   Reply With Quote
Old 23-11-10, 18:54   #7
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default

Quote:
Originally Posted by kamilm_93 View Post
nope... I open umv and closes... Without error... I extrac this file to:

"g:\program files\ea games\mirror's edge\binaries"
uvm?
o0Crofty0o is offline   Reply With Quote
Old 23-11-10, 18:56   #8
KamilM_93
Member
 
KamilM_93's Avatar
 
Joined: Jul 2007
Posts: 7,755
Default

Quote:
Originally Posted by o0Crofty0o View Post
uvm?
Unreal Model Viewer :P

Where I must extract this file ?
KamilM_93 is offline   Reply With Quote
Old 23-11-10, 18:59   #9
o0Crofty0o
Member
 
o0Crofty0o's Avatar
 
Joined: Sep 2009
Posts: 6,726
Default

Quote:
Originally Posted by KamilM_93 View Post
Unreal Model Viewer :P

Where I must extract this file ?
I explained the extraction of such files kinda well above^^
You don't extract a file just by open the umodel.exe.
Read the steps. It's all on there^^
o0Crofty0o is offline   Reply With Quote
Old 23-11-10, 19:05   #10
KamilM_93
Member
 
KamilM_93's Avatar
 
Joined: Jul 2007
Posts: 7,755
Default

Quote:
Originally Posted by o0Crofty0o View Post
I explained the extraction of such files kinda well above^^
You don't extract a file just by open the umodel.exe.
Read the steps. It's all on there^^
And now I know what's the problem :P I only move .upk file(Celesta.upk) and uvm files to folder xd
KamilM_93 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 10:45.


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.