Importing/Re-Assigning Custom Model Materials

A Tutorial for Dota 2

This tutorial may or may not become obsolete through future updates to the Dota 2 Workshop Tools Alpha/Source 2 Model Editor.


Static Model vs. Animated Model (Supported model formats)


You will need a model preferably in .OBJ or .FBX format. .SMD and .DMX formats are also supported, but require some knowledge to export and subsequently import into Source 2. Most modeling programs support .OBJ format exporting so .OBJ is recommended (though, for static props only; otherwise use .FBX if your model has animations).

Importing the model/re-assigning the model's textures:


  • Open Vconsole (this is important for debugging the texture-loading issue).
  • Import your .OBJ/.FBX. Make sure you have the model somewhere in dota_ugc/content/dota_addons/<addon name>/models/<model name> (ie. dota_addons/mygamemode/models/potofgold.obj) before you import it. Texture should be in a similar folder structure, but replace \models\ with \materials\.
  • Look through Vconsole and find the name of the texture that the model is looking for (and subsequently can't load). From here, you'll need to create a .vmat in the material editor, of the same name as the missing texture. More on that below.

Creating a VMAT for your model:


  • Go to the material editor and create a new file.
  • "Save as" as the texture name that's required by the model (under dota_ugc/content/dota_addons/<addon name>/materials/<model name>).
  • In the "Variables" tab (in the middle of the material editor, under the "Color" tab) browse to the model's source (.tga or .psd) texture (should also be under dota_ugc/content/dota_addons/<addon name>/materials/<model name>, as pointed out earlier). Your texture should appear in the preview viewport, on the model. If not, hit ctrl+s to save, and it should appear.
  • Now, your model should have the texture appear on it! If not, you'll need to add a Material Group onto the .vmat and add the texture from there. More on that below.

Creating a Material Group for your model/material:


  • In your model editor window, go to the "Model" tab at the top, and then select "Add Material Group".
  • Go to the Outliner on the left and expand the "Material Group List".
  • There should be 2 materials there, default and materialGroup_1. Do not touch default, leave it as it is. Select materialGroup_1 instead.
  • On the opposite side of the model editor window, there should be a "Materials (1 items)" tab. If not, click the blue "+" on the very right.
  • From here, expand the tab and browse for your .VMAT file that you made earlier from the source texture, if it's not already there.
  • If it IS already there, you might need to take the .vmat and put it in your root addon folder (move it up to dota_ugc/content/dota_addons/<addon name>, instead of dota_ugc/content/dota_addons/<addon name>/materials/<model name>)

Posts

None found

Embed

Share banner
Image URL:
HTML embed code:
BB embed code:
Markdown embed code:

Credits

Key Authors
Toyoka
Writer

Submitter

natko avatar
natko username pic Joined 17y ago
Ripe Supporter Admin
Offline
279,817 points Ranked 11th
59 medals 11 legendary 15 rare
  • Achieved Admin clearance Medal icon
  • 10 years a member Medal icon
  • Submitted 100 Skins Medal icon
  • Submitted 15 Tools Medal icon
  • Submitted 50 Gamefiles Medal icon
  • Submitted 30 Tutorials Medal icon

natko avatar
natko

Redistributor
Are you the owner? Request Ownership
Sign up to access this!
Sign up to access this!
Sign up to access this!

Game

Sign up to access this!

Category

Details

Difficulty Level
Intermediate

Attributes

Share

  • Share on Reddit
  • Share on Twitter
  • Share on Facebook
  • Share on Google+

Stats

  • 4,976 Views
  • 0 Posts
  • 4y Submitted
  • 4y Modified

Scores

  • Not yet rated
Sign up to access this!

More from Submitter

More Other/Misc Tutorials

bcp.crwdcntrl.net tracking pixel