Tomb Raider Forums  

Go Back   Tomb Raider Forums > Tomb Raider Level Editor and Modding > Tomb Raider Level Editor > Software Development

Reply
 
Thread Tools
Old 07-08-21, 07:15   #91
Bergus
Member
 
Joined: Dec 2020
Posts: 52
Default

Quote:
Originally Posted by not again! View Post
That would be amazing! Thank you! Maybe name it Lara Outfit though, since that is the term that people use in the TRLE community.
Ok, option added! It was easy, I just apply transforms to the rig, clear parenting keeping transforms and then delete rig.
Hope it is what you asked. If it needs some modification or there are bugs please let me know
Bergus is offline   Reply With Quote
Old 07-08-21, 17:50   #92
not again!
Member
 
not again!'s Avatar
 
Joined: Feb 2008
Posts: 1,145
Default

Perfect! Thank you very much - it's exactly what I had hoped for!

Quote:
Originally Posted by Bergus View Post
If it needs some modification
This is definitely going to be a massive help in either case without any changes. The ultimate dream however would be to be able to import the outfit (and the enemy NPC models) into WadTool in one step instead of part by part (basically if it would be compatible with WadTools replace model function).

edit: thinking a bit more about this I'd like to add that making the models compatible with the replace model function as such is not part of the dream goal. Any solution you come up with would be awesome - I just assumed this would involve the least amount of work, but since I'm not a programmer I'm probably wrong about this, so I thought I should clarify.

Last edited by not again!; 07-08-21 at 18:46.
not again! is offline   Reply With Quote
Old 07-08-21, 19:07   #93
Bergus
Member
 
Joined: Dec 2020
Posts: 52
Default

I wanted to do something like that, so that one can design some meshes, make an armature, texture, animate, all in Blender and then save as wad. The skeleton can be imported more easily into Wad Tool using a wad rather then obj. I mean, I can more easily predict the result. Maybe I'm wrong, need to see better the Wad Tool code.

I need just to figure out something for the textures because I already have some ideas for the skeleton
Bergus is offline   Reply With Quote
Old 08-08-21, 07:25   #94
not again!
Member
 
not again!'s Avatar
 
Joined: Feb 2008
Posts: 1,145
Default

^^ This sounds both amazing and like an absolute behemoth of an undertaking. Being able to export things directly to wad format would certainly be amazing.
If you need anything tested during development let me know!

Quote:
Originally Posted by Bergus View Post
Maybe I'm wrong, need to see better the Wad Tool code.
Do you mean the latest build that is currently being worked on?
TE / WadTool etc are open source, but I don't know if the pre-release builds are also freely accessible - I assume you'd have to ask Lwmte.

edit: I just discovered what the issue was with importing models using the replace model option. It does apparently not work if the model has quads; the faces need to be triangulated, so this actually had nothing to do with WadBlender as such (I'm sorry , a million apologies!)
It worked with models exported as .3ds from WadViewer because the .3ds files get triangulated automatically (either on export from WadViewer or on import into Blender, I don't know). In addition to that WadTool imports the meshes with quads just fine if you import them one by one using the import mesh function.
edit2: Have to correct myself again - you can import models that have quads using replace model. I tried replacing all meshes of the bat model with the blender start cube, left the quads and could import that without problems, so let's just cautiously say that whatever the problem may be, in some cases triangulating the meshes helps? this is so wierd

Last edited by not again!; 08-08-21 at 20:27.
not again! is offline   Reply With Quote
Old 08-08-21, 16:04   #95
Bergus
Member
 
Joined: Dec 2020
Posts: 52
Default

More than Wad Tool, I worry about that ASSimp 3D library they use (the doc is a bit hermetic)
I need to see if I can somehow use their library to directly create a wad2 with proper skeleton. They built a library that can be used by external programs.

Anyway, I created an experimental branch on WADBlender github. There is a save as static button. Very experimental, just select a mesh and save as static from the wad blender tab in object mode. No ngons nor non grid aligned textures May be useful if you want to make simple changes to the textures of a mesh coming from a wad. I suggest not to try it, it is just for who is curious!!

Last edited by Bergus; 08-08-21 at 16:05.
Bergus is offline   Reply With Quote
Old 08-08-21, 20:23   #96
not again!
Member
 
not again!'s Avatar
 
Joined: Feb 2008
Posts: 1,145
Default

That was light-speed fast! Incredible.

People should straighten out their uv maps to grid-shape with "follow active quad" whenever possible anyway, so this should already be useful for newly created custom models too! Going to try it out right away.

Quote:
Originally Posted by Bergus View Post
I need to see if I can somehow use their library to directly create a wad2 with proper skeleton.
Do you plan to include support for inverse kinematics?
not again! is offline   Reply With Quote
Old 09-08-21, 12:46   #97
Bergus
Member
 
Joined: Dec 2020
Posts: 52
Default

Quote:
Originally Posted by not again! View Post
That was light-speed fast! Incredible.

People should straighten out their uv maps to grid-shape with "follow active quad" whenever possible anyway, so this should already be useful for newly created custom models too! Going to try it out right away.
Oh, I already had some code Thanks
I hope that keeping the uvs straight is feasible for the designer. There is also the possibility of using the lightmap method but, at that point, Tomb Editor would be a better way to import the object. I was trying to do something on the lines of lightmap + baking (without baking) but I'm getting some strange deformation. I need to find the right algorithms.

Quote:
Originally Posted by not again! View Post
Do you plan to include support for inverse kinematics?
I think it is possible to use ik and then bake the action to the rig, not sure though.


UPDATE: I added save as obj and save as movable. That's only for a single mesh. Now there's the difficult part: debugging/test
Bergus is offline   Reply With Quote
Old 10-08-21, 04:35   #98
not again!
Member
 
not again!'s Avatar
 
Joined: Feb 2008
Posts: 1,145
Default

I tried out the save to wad feature and have to say I'm definitely hyped!
I exported the (textured) Blender start cube: once as static and once as moveable and everything worked flawlessly. I could open the wad in WadTool and it also worked fine when used in a level. Congratulations on the fantastic work!


Quote:
Originally Posted by Bergus View Post
I hope that keeping the uvs straight is feasible for the designer.
It's good modelling practice in cases like architecture models and inventory items, but it's not really ideal for organic things like character models.
not again! is offline   Reply With Quote
Old 10-08-21, 12:09   #99
Caesum
Member
 
Caesum's Avatar
 
Joined: Aug 2008
Posts: 12,070
Default

Quote:
Originally Posted by Bergus View Post
Yes, I'm occasionally updating it. I made some changes last week, can you please try to see if the first problem is solved?

If there's only LARA_SKIN you need to choose the LARA_SKIN object from the choose object menu. 'import full Lara model' works only when LARA, LARA_SKIN and LARA_SKIN_JOINTS and are present.
The newest version works great! I have one more question though, is there a way to save the wad back? Or do you plan to add such feature? Because I would love to use it to modify some outfits. The way it loads up whole thing would be perfect for outfit editing/creation.
Caesum is offline   Reply With Quote
Old 10-08-21, 19:58   #100
Bergus
Member
 
Joined: Dec 2020
Posts: 52
Default

Quote:
Originally Posted by not again! View Post
I tried out the save to wad feature and have to say I'm definitely hyped!
I exported the (textured) Blender start cube: once as static and once as moveable and everything worked flawlessly. I could open the wad in WadTool and it also worked fine when used in a level. Congratulations on the fantastic work!
Thanks I added a bake button that duplicates the selected object and squares the uvs using the lightmap method. I want to do something better but it is good for now. No ngons (I forgot to autotriangulate them) and better to decimate the geometry of the object if it has too many faces. It is in the experimental GitHub branch.

Quote:
Originally Posted by Caesum View Post
The newest version works great! I have one more question though, is there a way to save the wad back? Or do you plan to add such feature? Because I would love to use it to modify some outfits. The way it loads up whole thing would be perfect for outfit editing/creation.
You can import the meshes as obj in tomb editor but you first need to move them back to the axis origin (0, 0, 0). See the not again post above. What moves the meshes to their right position is the mesh tree, so if you import the obj as it is, the meshes are moved two times.

I think next I'll see if I can make something to save the outfit as wad. This workflow is too much laborious and dangerous (vertex order problem when exporting obj to tomb editor, vertices groups to change, etc.)

Last edited by Bergus; 10-08-21 at 20:01.
Bergus 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 23:13.


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.