| 03-19-2005, 09:01 AM | #1 |
Disclaimer I am a newb playing around with things, so I really don't know as much as say Ari does about animations and geosets in MDL's (you can find his awesome tutorial here http://www.wc3campaigns.com/showthre...move+hero+glow) but I hope to one day learn some more. To tell you the truth I am quite satisfied that I found out how to effectively and completley remove hero glows, even when the hero attacks, casts, etc. Even Ari's somewhat comprehensive tutorial does not accomplish this. Tools you will need:
This tutorial starts off assuming that you are at the step where you have a MDX hero file on your harddisk that is not compressed somewhere in a god-forsaken MPQ. 1. Fire up Yobgul's file converter. You should receive NO errors at this point. Hit the "Load MDX file" and browse to your hero.MDX. Hit the "Convert to MDL" and you should receive an alert saying conversion was succesful. Open up the MDL with notepad. The MDL is a seperate file located in the same folder as the MDX with the same name except the MDL extension instead of the MDX extension. Close YobGul's. You should receive an error at this point. It is a result of bad programming and does not affect anything in WC3. Ignore it. 2. You should have an open MDL in notepad on your desktop, assuming you are using Windows of course, Mac's use something else and Linux, well you could be doing all this in terminal in linux and if your using linux then you don't need me anyways, your smart enough to figure out this on your own. Back to the tutorial, we will leave Windows bashing till late ;) Hit Ctrl+F, this will bring up a search prompt. Into the search prompt, type in "Alpha 1" without the quatation marks. This should bring you up to something that looks similar too: If you are an ernest reader of the WC3 campaigns forums then you have probably come across Ari's Hero Glow tutorial (link can be found in disclaimer.) If not, then I will just say that Ari, at this point in the tutorial, says to remove the Hero Glow you simply have to erase the whole section: Alpha 1 {and replace it with: Alpha 0THIS IS WRONG: you will come across many problems, one is that you will not be able to convert your file back to MDX, another is that if you get it working, it will do nothing. The right way is a bit more complex. First let us consider the headings importance. By heading I am refering to the line that says: Materials 3Materials is just a generic identifier of the objects using the textures found earlier in the Model file. The significant part is the number 3 in: Materials 3The number signals that there are ONLY 3 Materials in the model file. Each Material is given an identification automatically so that it can be refered to later on iin the model file. By automatic identication I mean that there are no lines in the file that specifiy the ID of each material, instead, MaterialID's are given based on the order they appear in the file, with the first one in the array given the ID of 0, the second given the ID of 1 and so on. This means that, in our example above, even though the number 3 signals 3 Materials, the highest MaterialID is in fact 2 and the lowest MaterialID is infact 0. What does all this mean? Well first let us examine what each MaterialID actually refers to. There are blocks of code in the file that look like: Material {These are two layer blocks that refers to one Material: Material {We know now that each Material is given an ID based on its order, so we should expect that each Texture is given an ID based on its order also. This is in fact true. We know that the texture we are interested in should be "replacable" since we know that the hero glow changes color in each game. "Replacable" textures cannot be found in one specific file, but instead in a directory. Looking at our code we see two such textures: and Looking at the order these textures are found: We know texture 1 has TextureID 1 and texture 2 has TextureID 3. Looking at our Materials, we can see now why I recommended to search for "Alpha 1": Material {The block refers directly to our TextureID 3, which is one of the replacable textures. This is, IN FACT, the texture and material that we are interested in. The other replacable texture identified earlier as texture 1, defines the color that the clothes and armor of a hero take on based on what player they are controlled by. This is, in fact, how people get the "ghost" effect. I can write another short addon to this tutorial describing the "ghost"effect if I see that people are interested. 3. Replace: Material {with Material {4. If you were to finish with editing the MDL at this point you will find a weird effect, your hero will have no glow when standing, but when doing any action he will have a glow. This is because we still haven't changed our animation information in the model file. This part of the tutorial is much more specific to the type of model your hero has but the general strategy to prevent this weird effect is to DELETE the animation information PERTAINING to the MaterialID of the Material that SPECIFIES your hero's glow effect covered in steps 2 & 3 of this tutorial. How do we do this? First look at your MaterialID, in the example: Materials 3 {Clearly, the MaterialID is 2. Ctrl+F to bring up your search prompt. Type in your MaterialID. In the example case it is MaterialID 2. It should bring up only 1 match. In the case of the example it brought up this: You can delete this WHOLE Geoset block of code, it just defines the animation of the hero glows. In the case of the example, the whole text above would be deleted. 5. Save the model file, you are almost done. Open up Yobgul's file converter. Load the MDL file and convert it to MDX. Your new MDX file has no hero glow, but you need to get it into your map. 6.Load up WorldEditor. Create a new SMALL TEST MAP. USe the import manager to import your new MDX file. Now the Model is available to you in the object editor. If you want this MDX to replace the MDX found in the war3.mpq, you must change the location of the MDX using import manager to the same location of the same name MDX found in war3. So for example, if I want to replace all Paladin Models in my map, I would change the location of the imported MDX from: war3Imported/HeroPaladin.mdxto Units\Human\HeroPaladin\HeroPaladin.mdxYou may still see the hero glow in WorldEditor. To test the model to be 100% sure, you must test the Map and Actually PLAY it! |
| 03-19-2005, 07:08 PM | #2 |
I have decided that the length of this tutorial might be overwhelming for someone who just wants to learn how to remove a hero glow quickly. I am going to write a summary. The danger in this is that people will not understand what they are doing and just will follow the steps, so if you find yourself in that situation please read the above post for more details.
|
| 03-21-2005, 04:30 PM | #3 |
awesome stuff. good thing you included the summary for the less-than-patient people like me. well written and worded. ill move this to the mdl forum. do we have an mdhell forum? i have no clue. i havent visited the tut section in a long time. ill see where it ends up. [MOVED] to somewhere. good job. |
| 04-14-2005, 06:28 PM | #4 |
There is an easier way - open up Vertex modify and find the geoset that contains glow. Delete all but three vertices and shrink them to nothingness. Done. |
| 04-14-2005, 08:08 PM | #5 |
actually you dont have to not delete 3 verticies. you can delete it all, then save it. if you have oinks new vertex modify, itll just get rid of that geoset... |
| 01-26-2006, 06:03 PM | #6 |
Great tutorial Linux. Been wanting to remove some hero glows off of some weapon mdls. Thanks for your contribution to the wc3 community. |
| 03-08-2006, 04:06 PM | #7 |
well.. i think i've found easier way for erasing glow color, if you don't like all that add/remove/replace-string thing.. no editing in notepad or converting .mdx to .mdl.. assuming that you have world editor, you only need War3 Model Editor, which can be found in HERE. after you downoad it and unzip it, start War3 Model Editor and open your .mdx file.. in menu click on window, and then open geoset manager and material manager. geoset manager should content something like this: Geoset 00DDBBA0 Geoset 00E14C70 Geoset 00E14E78 Geoset 00E20D60 Geoset 00E70238 Geoset 00E70440 and material manager like this: Material 00E29008 Material 00E29078 Material 00E332C0 Material 00E33820 Material 00E34AA8 Material 00E34FF0 Material 00E35060 geoset and material names on some model are temporary, and they change each time you load (same) model, so i think this is the only way to know which geoset is which. and the way is: each geoset represents a part of a model (head, weapon, glow...), and if you double-click any geoset, you'll see that each geoset uses one material. when you open any material, new window will pop-up with material layers (usualy one). double-click on that layer will show you it's properties, and the texture it uses.. what you need to do is - open every material (and it's layer) and find the one that uses Replaceable ID 2 texture (this texture is always the hero glow). if that material is (example) "Material 00E35060", then you have to find geoset that uses this "Material 00E35060" and simply delete it.. so, at the end: Replaceable ID 2 > MaterialLayer00E432C0 > Material00E35060 > Geoset00E14E78 when you erase Geoset 00E14E78, heero glow will dissappear.. i hope this helps, i don't think i've explained this very well, so, i'm sorry, i'm just a stupid foreigner.. ![]() |
