Home Dota 2

Dota 2 - Technical Thread

13
polycounter lvl 12
Offline / Send Message
Konras polycounter lvl 12
Here I propose to discuss matters connected with all kind of problems encountered during process of creation DOTA 2 items.

Ad for starters:
marre910 wrote: »
Can anyone help?
#4727

Its probably because some data in FBX file that is ignored by DOTA2 importer, however 3DS_MAX read theme and distort the model, so this data is than passed to exported items. Probably its related to scale.
Most of the time I use SMD files for importing reference stuff with bones.
Try use this plugin to load files:
http://www.wunderboy.org/3dapps.php#max_smd
You can also export directly to SMD using plugin found on that page.
Hope it will be some help to you :)

Replies

  • marre910
    Thanks man! The positioning is correct now when I use SMD
  • SandmanSeven
    Offline / Send Message
    SandmanSeven polycounter lvl 9
    (For anyone that didn't see my posts in the other thread) I'm importing a spear for Huskar and it isn't showing up, I've tried everything I can find online.

    I still can't get this spear to work, would you be willing to join a google hangout and walking me through it?
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    Hey SandmanSeven you could try to look into this tutorial that was created by our fellow polycounter Lennyagony
    http://steamcommunity.com/sharedfiles/filedetails/?id=123397498#
    There is very detailed process of item creation from start to previewing it in game.
    Give it a try.
    btw my memory fails me and there was an technical thread already, but it was never sticked :p
    http://www.polycount.com/forum/showthread.php?t=117899
    So if any moderator could stick one of those thread that would be most helpful :)
  • toby.rutter
    Offline / Send Message
    toby.rutter polycounter lvl 7
    Hi guys, I really pleased that a technical thread's been started, I've got a fair few questions to throw around that google has yet to give me answers for. At the moment I'm trying to add jiggle bones to one of the my items. I know this features been available for TF2 items and I'm fairly sure a couple of items in dota 2 make use of it. I've been following the method laid out here by editing the .qc file that was created when I imported the item into the workshop. But now I'm stuck trying to preview the effect to find out if the method works or not. I tried viewing the item as an additional item within the client but it didn't appear any different to when it was imported. I wondered if anyone else had tried this, or if anyone wants to bounce ideas back and forth about how to do this.
  • Coyo.Te
    Offline / Send Message
    Coyo.Te polycounter lvl 4
    Hey folks,
    since I am kinda stuck at texturing, more or less, I am redoing the same object over and over again, trying to improve and all that, I was wondering how you guys texture!

    Do you bake pointlights? and how does a good pointlight map look like, and why is a considered good a certain way and bad another. How do you paint certain materials color wise, how do you work in photoshop or else to get the look you want. Feel free to share details and examples.

    Couple o days ago someone posted a normal, ao and color map from one of his projects which helped me understand some new things I didnt consider before.

    PS: I read Dota2 Textureguide more than once, yes :)
  • SandmanSeven
    Offline / Send Message
    SandmanSeven polycounter lvl 9
    We are getting somewhere now! I can see the spear! even though its reallllyyyy small. Any ideas?

    HuskarBROKEN.JPG
  • DashXero
    Offline / Send Message
    DashXero polycounter lvl 11
    Did you import from the SMD or use the reference model provided from the workshop? Certain heroes' workshop maya files and/or objs are bigger/smaller than their in-game counterparts. For example (I don't know if this has been fixed or not), during the contest, I found that the in-game model for Crystal Maiden was 85% of the size of the model provided for reference in the maya file and fbx's.
  • SandmanSeven
    Offline / Send Message
    SandmanSeven polycounter lvl 9
    I modeled it from the FBXs provided, but then when I opened the smds they were much bigger, but I matched those sizes, reset all my transforms and everything and my model still imports the same size.
  • DashXero
    Offline / Send Message
    DashXero polycounter lvl 11
    Have you tried detaching the skin and re-weighting the item since you've adjusted its size?
  • SandmanSeven
    Offline / Send Message
    SandmanSeven polycounter lvl 9
    yep, even exported it as an obj re importing it, re skinning it and then trying, I think I'm just going to remodel my set from the smd files
  • penOr
    Offline / Send Message
    penOr polycounter lvl 7
    Does anyone know a fix for when the workshop is displaying your previous items display picture, even if you upload the correct one multiple times?
  • K-PAX
    Offline / Send Message
    K-PAX polycounter lvl 7
    anybody can preview ta items in game? i can't see anything since 20th February Patch.
    http://dev.dota2.com/showthread.php?t=74779
  • Paskie
    Testclient or the main client?
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    yep, even exported it as an obj re importing it, re skinning it and then trying, I think I'm just going to remodel my set from the smd files

    Try to open new scene. Import smd weapon file. Export that original weapon imported from smd and their bones. If that works you can attach your weapon to original one and delete geometry that you don't need (default geometry). And that should work :)
  • SandmanSeven
    Offline / Send Message
    SandmanSeven polycounter lvl 9
    So I made a new scene, imported the SMD spear for huskar and then modeled an a new spear from scratch in that scene, and it shows up perfectly, its not unwrapped or textured or anything but I'll get it there.

    It seems to me that if you model anything from the fbx files they provide you are shit out of luck. I'm going to spend the next few days remaking my whole set, but I did come up with a better spear concept so thats nice.
  • Pierate
    Offline / Send Message
    Pierate polycounter lvl 15
    To be fair I've had issues with some SMD's aswell, the FBX files that comes with the latest added heroes such as Keeper of the Light work really well. I always export as SMD though and I make sure to convert from inches to centimeters when importing an FBX to get the scale right.

    Good to see that your issue was solved, hopefully thing will go smoother for you the next time :)
  • MechBgum
    Konras wrote: »
    Its probably because some data in FBX file that is ignored by DOTA2 importer, however 3DS_MAX read theme and distort the model, so this data is than passed to exported items. Probably its related to scale.

    Import settings, units -> centimeters.
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    Coyo.Te wrote: »
    Hey folks,
    since I am kinda stuck at texturing, more or less, I am redoing the same object over and over again, trying to improve and all that, I was wondering how you guys texture!

    On the latest Darksiders Contest here on Polycount BoBo introduced great method for creating base for your textures. Here you can look from 02:10:00
    http://www.livestream.com/vigilnights/video?clipId=pla_69d386b0-0c57-444a-a1e5-4c820a55e9d2&utm_source=lslibrary&utm_medium=ui-thumb
    Still you could want to bake one more additional map with point light from single omni light and put it on top of that map. Later you can paint on top of that.
    Also I don't follow but I am pretty sure that Anuxi made some livestream with texturing process of her items :) Maybe someone can point it out :)

    Thanks MechBgum for pointing that out. I didn't suppose there was so simple fix to fbx. I was to worried that they were exported with scale parameter somehow. Thanks!
    I wonder if that will also help Maya users somehow? Still I trust SMD most :) even if I need to decompile them, however fbx files have mesh not triangulated which can be helpful sometimes.
  • iniside
    Offline / Send Message
    iniside polycounter lvl 6
    Coyo.Te wrote: »
    Hey folks,
    since I am kinda stuck at texturing, more or less, I am redoing the same object over and over again, trying to improve and all that, I was wondering how you guys texture!

    Do you bake pointlights? and how does a good pointlight map look like, and why is a considered good a certain way and bad another. How do you paint certain materials color wise, how do you work in photoshop or else to get the look you want. Feel free to share details and examples.

    Couple o days ago someone posted a normal, ao and color map from one of his projects which helped me understand some new things I didnt consider before.

    PS: I read Dota2 Textureguide more than once, yes :)


    http://steamcommunity.com/sharedfiles/filedetails/?id=123397498#19243

    This guide is quite useful. ptrP and ptrN maps are very nice for everything.
    Sometimes radiosity normal map is cool, but it take ages to bake so I personaly usually don't bake it.

    I don't bake any point light maps. I bake everything in xNormal.

    I really don't do anything facy. I take base color from original textures and just well, paint.
  • sdmaze
    Offline / Send Message
    sdmaze polycounter lvl 11
    Hi all, I am currently stuck on Rubick's head. I am working on a new mask and every time I go to import, it just simply is not here. I tried skinning the head to the head_0 and head_1 attachment but get nothing. but it shows up headless. -.- any help is much welcome, <no not final texture.>

    if it helps I build off the SMD and export as a FBX.

    a8FZWAGs.jpg

    ...well we all know what a headless rubick looks like
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    @sdmaze Dont know if thats the case, but models should be exported together with their bones in one file. If you export only model without bones it will be not visible.
  • Mr. Toodles
    Offline / Send Message
    Mr. Toodles polycounter lvl 11
    Trying to attach my bracers to his arms and the left arm goes really far back and wild like, I use blender and I can't find a bone I can use to fix this
  • Coyo.Te
    Offline / Send Message
    Coyo.Te polycounter lvl 4
    woops - double post
  • Coyo.Te
    Offline / Send Message
    Coyo.Te polycounter lvl 4
    Trying to attach my bracers to his arms and the left arm goes really far back and wild like, I use blender and I can't find a bone I can use to fix this


    I think you can bind most cosmetics to almost whatever bone you want to. watch the uncertainty in this sentence ^^

    I did this with a tidehunter back i am working on. It stretches over the whole back and looks weird if only bound to one bone. so I marked couple of vertices to spine 1, another couple to spine 2 and the rest to spine3, no the back moves along the spine when moving.

    Try to bind the left hand bracer to a bone in the left hand like the left wrist or so. your model will move in respect to that bone then.


    iniside wrote: »
    http://steamcommunity.com/sharedfiles/filedetails/?id=123397498#19243

    This guide is quite useful. ptrP and ptrN maps are very nice for everything.
    Sometimes radiosity normal map is cool, but it take ages to bake so I personaly usually don't bake it.

    I don't bake any point light maps. I bake everything in xNormal.

    I really don't do anything facy. I take base color from original textures and just well, paint.

    I knew that guide before but now gave it a closer look especialy with the texturing part, and finally my xnormal bakes work correct now, but what about that part with the nDo2 converting of normal into cavity map, seems important for later texturing cause mine isnt yet working out correctly with the highlights. How do I do that without nDo2 ? and what is done in the process ?
  • sdmaze
    Offline / Send Message
    sdmaze polycounter lvl 11
    I 'skin' to the head bone but with rubick i don't know what one i am looking for or is the proper bone to link to in the first place.

    LYminZNl.jpg <-list of all the head bones o.o;

    I have skined to Head_0 and exported the mask with Head_0 but get nothing.
  • bounchfx
    hey guys, i'm trying to do some light maps and AO maps, but I've been getting really weird results when trying to do them.. it's like, portions of my mesh bake inside out.

    the normals are all fine, no overlapping uv's, etc. not sure what's causing this, but I get REALLY shitty AO bakes too. Could it be my video card?

    dotabakingerrors.jpg
  • Coyo.Te
    Offline / Send Message
    Coyo.Te polycounter lvl 4
    Coyo.Te wrote: »
    I knew that guide before but now gave it a closer look especialy with the texturing part, and finally my xnormal bakes work correct now, but what about that part with the nDo2 converting of normal into cavity map, seems important for later texturing cause mine isnt yet working out correctly with the highlights. How do I do that without nDo2 ? and what is done in the process ?

    Found a tutorial which explains how to do that with xnormal aswell.
    http://www.donaldphan.com/tutorials/xnormal/xnormal_occ.html

    a bit scrolling and your there. nice for highlights it seems.
  • Midup
    Hello everybody,

    I'm having trouble with an item.
    I followed the tutorial created by Lennyagony. apparently everything was ok, but when I export to Dota this happens:

    pudge_hook2.jpg

    pudge_hook3.jpg

    The texture was strange in some positions and transparent.
    Does anyone have any idea what this could be?
  • Coyo.Te
    Offline / Send Message
    Coyo.Te polycounter lvl 4
    Overlapping UVs cause quite some distortion here and there. Some vertices from the original model not correctly deleted maybe? Flipped faces can mess up a compile. Could be quite alot. But it seems this problem with weird artifacts happens quite alot. There should be a solution around somewhere here as I recall.
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    bounchfx wrote: »
    hey guys, i'm trying to do some light maps and AO maps, but I've been getting really weird results when trying to do them.. it's like, portions of my mesh bake inside out.

    the normals are all fine, no overlapping uv's, etc. not sure what's causing this, but I get REALLY shitty AO bakes too. Could it be my video card?

    dotabakingerrors.jpg

    That's weird, because those shells seem to display incorrect shading on 1/2 of their width.
    You said that normals are ok and there are no overlaps.
    I don't know maybe check those thongs:
    - turn backface culling on object properties and see if whole mesh is displaying correctly.
    - in UV window select faces and from top drop down menu select inverted faces. Maybe there is no overlap, however some uv chunks can be inverted.
    - check if your model don't have minus scale on any axis
    - reset xform
    - attach it to newly selected item and than render and see if problem will occur then

    That's all I can come up with :)
  • Bigpet
    sdmaze wrote: »
    I 'skin' to the head bone but with rubick i don't know what one i am looking for or is the proper bone to link to in the first place.

    [snip] <-list of all the head bones o.o;

    I have skined to Head_0 and exported the mask with Head_0 but get nothing.

    Wow, what the hell? What are the 23 extra bones for? They're not bound to anything as far as I can tell.

    I'd bind the mask to Head_1 but it's weird that there's no default head cosmetic for Rubik? Wasn't the head slot meant to replace the head? I think Anuxi mentioned something like that. But the base model doesn't actually have a separate head. Something's amiss here

    Btw. just tested that out, the correct bone is indeed Head_1 and it does replace the full head as is apparently intended
  • bounchfx
    Konras wrote: »
    That's weird, because those shells seem to display incorrect shading on 1/2 of their width.
    You said that normals are ok and there are no overlaps.
    I don't know maybe check those thongs:
    - turn backface culling on object properties and see if whole mesh is displaying correctly.
    - in UV window select faces and from top drop down menu select inverted faces. Maybe there is no overlap, however some uv chunks can be inverted.
    - check if your model don't have minus scale on any axis
    - reset xform
    - attach it to newly selected item and than render and see if problem will occur then

    That's all I can come up with :)


    thanks dude, will give these a shot tonight. I had a few more things I wanted to try as well since I didn't really dig deep into this yet, but hopefully it's a straightforward solution.. it's killin' my bakes!
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    Bigpet wrote: »
    Wow, what the hell? What are the 23 extra bones for? They're not bound to anything as far as I can tell.

    I'd bind the mask to Head_1 but it's weird that there's no default head cosmetic for Rubik? Wasn't the head slot meant to replace the head? I think Anuxi mentioned something like that. But the base model doesn't actually have a separate head. Something's amiss here

    Probably files on the technical requirement page for Rubik are out of date.
    The best guess in my opinion would be to decompile his up to date files from game to SMD format using this tutorial:
    http://wyksblog.com/getting-started-dota-2-cosmetics/
  • Bigpet
    Konras wrote: »
    Probably files on the technical requirement page for Rubik are out of date.
    The best guess in my opinion would be to decompile his up to date files from game to SMD format using this tutorial:
    http://wyksblog.com/getting-started-dota-2-cosmetics/

    I already did and they're basically the same ones as the ones on the requirements page. But the reason for that is probably that the decompiler doesn't support all the newer features of *.mdl files. It doesn't extract *.dmx files and also can't deal with vertex animations on the dota2 models.
  • mrpresident
    Offline / Send Message
    mrpresident polycounter lvl 10
    For Rubick, the head slot ends at the seam where his neck meets the green vest. Just duplicate the poly's at the very base of the neck and then build your new head up from there.
  • Vrav
    Offline / Send Message
    Vrav polycounter lvl 11
    Hey chaps, the other day I was extracting some files with GCFScape and wanted to convert a ton of vtf textures to tga. So I wrote some windows batch file commands that let you drag a directory full of vtfs onto the bat and runs vtf2tga on each item.

    The original one I wrote uses forfiles, but apparently that doesn't work in XP, so there's another one with the 'for' command as well. I don't think it makes a difference which you use. Make sure you double check the hardcoded short-path for vtf2tga.exe - atm it's looking at the alien swarm directory in Program Files (x86). If you're on win32 you need to change it to say Progra~1; if you installed Steam somewhere else you need to figure that out, etc.
    @echo off
    
    SET SOURCENAME=%~s1
    SET VTF2="C:\Progra~2\Steam\steamapps\common\aliens~1\bin\vtf2tga.exe"
    
    forfiles /P %SOURCENAME% /m *.vtf /c "cmd /c %VTF2% -i @file -o @fname.tga"
    
    pause
    
    and the one for XP (and 32 bit... just 'cause!)
    @echo off
    
    SET SOURCENAME=%~s1
    SET VTF2="C:\Progra~1\Steam\steamapps\common\aliens~1\bin\vtf2tga.exe"
    
    for %%G in (%SOURCENAME%\*.vtf) do %VTF2% -i %%G -o %%~pnG.tga
    
    pause
    
    ... basically you save that as vtf_convert.bat or whatever and drag a folder onto the file, profit.
  • Hawt Koffee
    Offline / Send Message
    Hawt Koffee polycounter lvl 13
    If it hasn't been mentioned yet
    for BLENDER USERS when baking normal maps, the Green channel is inverted for some reason, so be sure to go into Photoshop and fix it
    the best way is to go to your channels
    click on Green and press ctrl + I
  • Bigpet
    If it hasn't been mentioned yet
    for BLENDER USERS when baking normal maps, the Green channel is inverted for some reason, so be sure to go into Photoshop and fix it
    the best way is to go to your channels
    click on Green and press ctrl + I

    That's weird, which version are you using and what settings for baking? Because to me it looks like the normal map is fine without inverting y 2Q9Ka0F.png
  • Spudnik
    Offline / Send Message
    Spudnik polycounter lvl 11
    So this just popped up on the Source Film Maker patch notes.
    Maya:
    improved Maya startup scripts that are version-specific and take no arguments
    added sfmValveSetup.mel script that can be run if you're not using the startup scripts
    added new vstShrinkWrap command in the vstUtils.mll plugin
    added new DMX Export Manager to simplify the process of exporting and compiling models

    Could any of that find any application for Dota 2 ?
  • bozza
    Has anyone done much with cloth physics? Im creating a staff for warlock who's default one has 3 bits of cloth hanging from the top. I just wanted to have 1 similar bit of cloth but in a different position towards the middle of the staff.

    I tried just skinning it to the same bones as one of the default cloths and just left the bones in the same position, that didnt really work i guess because the bones werent anywhere near the geometry?

    I tried moving the bones themselves down to the same position as my cloth, the cloth physics work great except my bit of cloth just flew up to where the default one is.

    Are we not allowed to move the bones around, or does the ingame importer just use the default bone locations and only imports geometry?

    Some screenshots below might help show what i mean.

    jp91THG.png
    YEFtbcT.png
  • Mark.N
    bozza wrote: »
    Has anyone done much with cloth physics? Im creating a staff for warlock who's default one has 3 bits of cloth hanging from the top. I just wanted to have 1 similar bit of cloth but in a different position towards the middle of the staff.

    I tried just skinning it to the same bones as one of the default cloths and just left the bones in the same position, that didnt really work i guess because the bones werent anywhere near the geometry?

    I tried moving the bones themselves down to the same position as my cloth, the cloth physics work great except my bit of cloth just flew up to where the default one is.

    Are we not allowed to move the bones around, or does the ingame importer just use the default bone locations and only imports geometry?

    Some screenshots below might help show what i mean.

    jp91THG.png
    YEFtbcT.png

    You are correct in assuming that the engine only uses the bones from their default position. This is because you are only adding a new weapon .smd and not updating the warlock.smd (this actually contains the overall skeletal rig). You'd have to modify warlock.smd and place the bones in a new location, thus creating an entirely new rig.

    For this reason, cloth tends to go unutilized on custom content, since it requires a ton of extra back end work.

    TL/DR: If you're going to use cloth, use what's already there, don't add your own.
  • bozza
    Mark.N wrote: »
    You are correct in assuming that the engine only uses the bones from their default position. This is because you are only adding a new weapon .smd and not updating the warlock.smd (this actually contains the overall skeletal rig). You'd have to modify warlock.smd and place the bones in a new location, thus creating an entirely new rig.

    For this reason, cloth tends to go unutilized on custom content, since it requires a ton of extra back end work.

    TL/DR: If you're going to use cloth, use what's already there, don't add your own.
    Ah of course, that makes complete sense, thanks Mark! I'll just leave out cloth for now unless i'm putting it in the same default position.
  • Insaneophobia
    Offline / Send Message
    Insaneophobia polycounter lvl 5
    Is it possible if anyone can give me a quick tut on how to apply textures to a imported dota 2 hero in 3ds max? I imported axe from the .obj file and when I try to import the texture it doesn't change. I will be really happy if anyone can help me. :)
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    @Insaneophobia Here that will help you. https://www.youtube.com/watch?v=EuBIkPcTH3g Although if you have newer version of max maybe you will have to change view of material window from slate to compact (fist tab in material editor window). However your question in very basic and not DOTA2 specific. You should grab some basic 3DSMax tutorials to get you on right track first, than start modeling DOTA2 items.
  • Insaneophobia
    Offline / Send Message
    Insaneophobia polycounter lvl 5
    Konras wrote: »
    @Insaneophobia Here that will help you. https://www.youtube.com/watch?v=EuBIkPcTH3g Although if you have newer version of max maybe you will have to change view of material window from slate to compact (fist tab in material editor window). However your question in very basic and not DOTA2 specific. You should grab some basic 3DSMax tutorials to get you on right track first, than start modeling DOTA2 items.

    Haha I know, but the problem is I do know how to put texture on things usually, and that techniques works most times, but for some reason it doesn't work at all with the dota 2 models. For me anyways, it could be something with my computer, but I just thought it had something to do with the dota 2 models and only them. This is why I posted it here.
  • MdK
    Offline / Send Message
    MdK polycounter lvl 9
    If anyone has any advice on how I can knock another 100 tris from this low poly while keeping the shape of the high poly, I would be eternally grateful!

    64306025.jpg
  • reverendK
  • Konras
    Offline / Send Message
    Konras polycounter lvl 12
    Also you could think about mirror symmetry here, because both sides of bow are the same, so you will get allot more from your UVs. As reverendK showed you can decimate bow ends to single sphere and it will be cool. Also horns can be not attached to main bow mesh, it will save some geometry.
  • MdK
    Offline / Send Message
    MdK polycounter lvl 9
    Thanks for the replies guys, that has really helped! I've given it another go and I'm down to 343. I've tried it ingame and it seems to keep the silhouette nicely, I just hope the normal bake works correctly now =/ fingers crossed:

    63450139.jpg
  • Andyk125
    Offline / Send Message
    Andyk125 polycounter lvl 4
    Like ReverendK said: Most important thing is make the sphere and wood from 1 part and let the normals do the work, that will save you enough tri's.

    Not sure why you would change the middle line from the sphere, that keeps the same amount of tri's and it's making it more flat. I wouldn't remove the horns from the model, that wouldn't save so much tri's, just collapse the other ends of it like ReverendKsaid.

    Also you can collapse one edge from the horns because they are pretty small and you won't even notice it!
13
Sign In or Register to comment.