• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Porting Heroes of the Storm (and Starcraft 2) Models to Warcraft 3

Level 20
Joined
Apr 12, 2018
Messages
494
Not a Tutorial

Tools: Blender 2.8x 2.80 — blender.org
This plugin: MDL Exporter for Blender3D!
This plugin: GitHub - SC2Mapster/m3addon: Blender Addon to import and export m3 files
This tool: Retera's Model Studio
Any CASC tool such as CASC View or CASC Explorer

Optional: for Classic porting
BLP Lab Your favorite modern digital painting tool

==================

CASC

1. Open Heroes of the Storm CASC

2. Every asset is in folder mods\heroes.stormmod\base.stormassets\Assets

3. Models are in .m3 format. Animations are in .m3a format (which is functionally the same as .m3). Textures are in .dds format (same as in Reforged)


Blender

For .m3 models
1. Make sure Blender's scene is devoid of anything in it (especially default materials)

2. Import .m3 model with m3addon

3. Make sure every geoset has its own texture (the exporter has a quirk where it will merge everything with the same texture and you dont want that).

4. Export model as .mdl with mdl-exporter (by default it will export at 60% size... LEAVE THIS ALONE; the models are HUGE and you want everything a consistent size)

5. Change texture path in the model to what you are going to use

For .m3a animations
1. Make sure Blender's scene is devoid of anything in it (especially default materials)

2. Import .m3a model with m3addon

3. Find an animation you want to export (it will be listed in m3addons own menu items, not blender's) and set Markers to define their bounds (for mdl-exporter, see documentation for addon)

4. Export model as .mdl with mdl-exporter one animation at a time

5. Repeat from 3 for as many animations you want as separate files

===============

(OPTIONAL) BLP converting
1. Convert .dds textures to BLP1 if you are planning to use in Classic

2. If you need to resize, do so (use .tga as a transitional state as it will preserve any existing alpha fields, although most .dds textures will not have this)


(OPTIONAL) Baking a texture

I use Photoshop for this purpose (layer styles may differ in other paint programs).

There are usually four textures for a given layer: Diffuse, Normal, Specular, Emissive. Discard Normal because it is not used for this purpose.

Copy and paste these textures into one file and arrange the layers as such:
Emissive (Layer Style- Screen)
Specular (Layer Style- Color Dodge)
Diffuse (Layer Style- Normal)

You may need to adjust the Specular layer if it turns out too bright (transparency percentage 50-75% helps if it is too bright).

Save as .tga and then convert to .blp1 format in BLP Lab.

===============

Retera Model Studio

1. Open your ported .m3 model

2. Go to Add Single Animation and add one of your ported .m3a animation files

3. Repeat until all desired animations are imported

4. Save as .mdx


You now have a basic model. Now you can fix it up however you please.

I have no idea how to use Blender save for a transitional state tool and 90% of any fixing is done in Retera Modeling Studio.
 
Level 20
Joined
Apr 12, 2018
Messages
494
Public Notes on converting Diablo 3 models (unfinished).

Typing this out so all the information is actually in one place instead of all over the internet (your welcome) and using 5+ old information. There's a distinct lack of porting of Diablo 3 models, and the only ones I know of floating around came from Warcraft Underground, but there's still a lot out there and some interesting things to be had.

So, this is my current research notes. It may not get updated later because of lack of actual interest.


==================

App to OBJ converter from Xentax forum Diablo III .app - Page 10 - XeNTaX

Texture converter from here: [Tool] D3TexConv - Page 3 - The Phrozen Keep

Had to compile it myself in Code Blocks Code::Blocks

Could not figure out how to use the compiled version without putting it in the Code Blocks folder.

Managed to get .Tex to .DDS and everything was smooth sailing from there.


======

Above version of App to Obj converter appears to work on current version of D3. Imported .Obj in Blender. Exported with War3 .mdl exporter (had to do it one mesh at a time and recompile them in Retera Model Studio). Model is boneless, but it's there.

No good way to transfer animations without 3ds Max 2011 (Taylor Mouse script only one seem to be able to do this). Going to have to rig the model by hand.

Wanted to use Taylor Mouse's Model Viewer 3.0 to export to Obj, but apparently it doesn't work (at least, not for Diablo 3 models).
 

Attachments

  • d3rs_app2obj_102_experimental.zip
    10.8 KB · Views: 32
  • D3TexConv v0.91.zip
    11 KB · Views: 40
  • D3TexConv_v0.91_compiled.7z
    9.8 KB · Views: 33
Level 1
Joined
Oct 15, 2021
Messages
2
Do you know how to make video tutorial for this, making HotS Models for Warcraft 3? If you do, can you make us one? I think many people will be thankfull an many good looking stuff will appear here on Hive. Thank you.
 
Level 12
Joined
Jun 17, 2023
Messages
36
Confirmed porting works on Blender 3.4.0 using Twilac's fork of mdl-exporter and m3addon. Used the June 14, 2023 build of mdl-exporter and March 31, 2023 build of m3addon both available on Github.

Update 2/28/24 - The action exporter on Twilac's mdl-exporter works. No need to mess with the actions in blender if you follow the rest of the instructions (1 through 8) the animations should carry over with minimal cleanup needed post export. Mostly minor rigging corrections. Step 9 should not be necessary.

The HoTS porting process has may pitfalls. After many hours of trial and error I've compiled the following tips using Blender so you can save yourself a lot of time:
1 - Import the .m3a (animation file) first

2 - Import the .m3 without any animations. Pick the option that says Mesh, vertex groups & materials.

3 - For every mesh imported add an armature modifier (blue spanner icon) and select the Armature from the Object drop down menu. The armature should have imported when you imported the .m3a file.

4 - Transform the armature (bones) if it does not line up with the model and the animations look wrong. Use animation preview to fine tune this. In blender 3.4.0 you can do this by selecting the Armature, clicking the Orange Box icon (Object Properties) and messing with the location fields until the animations look good.

5 - Make sure the model is facing X axis (Forward on default view in Blender). The global rotate in Layout view is good for rotating everything without messing up the bones.

6 - In Layout view in Blender select each mesh and click Material Properties (Red Sphere Icon). Under the MDL Material Settings section click the Plus sign to add a dummy material to each mesh. This step is required for the model to open in Twilac's Retera's Model Studio. If you're using the June 16th, 2023 build of mdl-exporter this may not be required? Looks like Twilac is trying to auto map the materials based on the m3 information. I'd still suggest double checking just in case.

7 - Before exporting make sure Blender is set to Modeling View and not Layout or Animation. If your animations look great in Blender and off in your WC3 model editing program this is probably why. A telltale sign is the model isn't its T-Pose after export or the bones are otherwise misaligned with the mesh.

8 - I had to export at 60 Scale (not 0.60) for the model to be scaled properly in game. Used settings Y Forward, Z Up, and Optimize Keyframes, Use Actions, and use SkinWeights unchecked.

9 - You don't have to repeatedly export the model for each animation you want to use (Thank God). You can copy and paste the frames (the little dots) from each action into a singular master action. Mark the start and end of each animation with a marker and rename both markers to the name of the animation. I spaced each animation by 10 frames just to make it easier to differentiate each one. If you did it right you should see the animation appear in the MDL Sequences section of the scene menu in blender. I've attached a screenshot for reference:

screen.jpg
 
Last edited:
Top