• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Making 3-D Weapons from Scratch

Level 12
Joined
Aug 31, 2008
Messages
1,121
Hello!
This is a tutorial about making cool weapon attachments!

This tut uses but is not required to:
Oinkerwinkles Vertex Modifier (On the link page) http://www.wc3c.net/showthread.php?t=85804
Mago's Model Editor http://www.hiveworkshop.com/forums/tools-560/war3-model-editor-62876/
Notepad (Comes with Windows. You may use most other text-editing programs in it's place.)

TIP: Also on Oinkerwinkle page, get the Eprims. They are very useful for advanced shapes.
First Open vertex modifier.
View attachment 65366


It should look like this.
View attachment 65396



Now hit open. Look around in the folder(s).
You may use any of the primatives included with the Vertex modifier, or any of the eprims (If you got them.)
I use a cube.
View attachment 65397

Now....
The part where the the hand goes is the origin
Before you start, I suggest you play around with the program, so you get comfortable.

Left click'n'dragging add to to your selection box.
"Add" adds to your selection (the dots will turn red)
"Deselect" removes any selected dots from your selection.
"Select" is a little less annoying but less precise. Everytime you drag, it deselects all previous dots, and selects all new ones. This is good for quick editing, but you can't go around objects.

"Move" moves the selected dots with a RIGHTclick'n'drag.
"Rotate" rotates the selected dots around the center of mass.
"Scale" expands or shrinks all the gaps between selected dots.
"Extrude" (Which you must get VERY comfortable with in this tut.) Recreates the selected dots at the point you drag you mouse to. This very useful in making a cube, into a beautiful sword (Sounds impossible? Think again!)

The X-Y-Z access buttons are very useful, in keeping your dots lined up when moving and extruding. Rotating and scaling with them can cause some unexpected results.


From here on out, "dots" will be called by their true name: "Vertices".

Now, open your cube back up.
The first thing were going to is make a "hilt".
Do some stuff like this... (Pay most attention to the bottom-left for now. The top-right is for the side view, and the top-left is the top-view.)

TIP: Save Often! This tool is very unexpected sometimes.
TIP: Undo! This is not an easy process!


Move the shape...

Here I use the extrude tool...
View attachment 65379

Scale the points using only y access (which means only the x and z buttons is pressed in... (the Y access is not required, but can create an easier to edit side view, and make the model seem more round.
HINT: If your your worried about what is happening to your top-right image [Why is it so fat?] Just scale it to a reasonable width, but be careful what axis you choose! (Scale, but the origin is going to off only from that side, so move the origin so it lines up right on both bottom and top-right views.)

Now to extend to the hilt, with the same model still!
Extrude from the end of your model and then scale it out...
HINT: You may notice that mine is very fancy, because I extruded off to the side for a curved hilt. Else you got a kinda pointy one.
View attachment 65380

Now in real wc3 view, mine looks like this...
View attachment 65381

Now too great yet heh? We'll get to that later.
Now to extrude out to the sword!
Give yourself quite a few vertices if you REALLY want a defined looking blade...
View attachment 65382
Use snap on the top to vertices to place them on top of eachother (it automatically centers them for you. Nice heh?)..

OPTIONAL STEP:
If you gave your self some extra vertices, use scale to make them awesome!!!...

View attachment 65383

Now...
Look at your top-right view.
You may scale there aswell, to make the sword thicker at the base etc.
It is the SIDE view of your sword. Make your sword's hilt nice while your at it...
TIP: If it helps, select the vertices in the other viewports to make sure you have the right ones. It will select them in others aswell.
HINT: Also disable the x-axis to affect only the side thickness, and not the overall thickness...


Now you got a large part of the hard work done!
If you were by chance to view it in Magos, you would see the sword is white!
Now time for "UV-Mapping"
Open Magos and in the windows tab hit "Mpq browser"
View attachment 65367
Up in the top of the new window, hit 'War3.mpq' or 'War3x.mpq'
HINT: For those of you new to these mpq's, War3.mpq contains all of the RoC data.
War3x.mpq contains all of the expansion data.
War3Patch.mpq contains data received over B.net (Like Firelord and stuff.)
War3Local.mpq contains data mostly linked to your PC.



Now open one of them and think of one of a model with a sword...
View attachment 65398
TIP: Use the filters to select 'none' then 'images' to improve your search.
You will notice that a lot of unit textures are not stored in the unit's section.
The majority are in the 'Textures' folder.
I'm gonna use a captain's sword.
Get your texture, and double-click it.
It will appear in the main window.
View attachment 65369
Now open the texture manager and find your texture.
right-click on it, and hit "export"
Name it "Yourtexurename.jpg" without the quotes and Yourtexturename may be what ever you wish.
It MUST be saved as a .jpg though.

Now back to Vertex Modifier.
In the pull-down menu called "tools", select "UV Mapping"
View attachment 65368

You will see a square on a white background.
View attachment 65385
There is a pop-out window that says "Front", "Top", or "Left".
Choose Left (Recommended)
Select all the vertices, and Press "remap"
NOTE: That button is Satan himself. It will often have errors, so save your file. It often doesn't work.
You will know it worked when you see what looks like your sword.
View attachment 65370

Now hit "Load Image"
Get your .jpg file.
View attachment 65371
After you select it, it will appear, with your UV-map on it.
View attachment 65372
Drag the whole thing over the area with texture. This takes practice.
View attachment 65388
View attachment 65391
View attachment 65390
View attachment 65391
TIP: Try to keep inside your shape, for when the Alpha layer is taken away (The black space in the picture) You may be able to see "inside" your model, and technically, that may allow you to "through" it. (Unless the material is twosided. If you don't know what I mean, just keep inside the damn shape.
HINT: Also, to make it easier for you position your shape, rotate and scale until it 'kinda' fits the appropiate shape, and then map it presisely. ZOOM IN ONCE YOU ARE ABLE TO!
OR: Just be a good skinner and make your own skin. Probably the easiest, but takes time.
HINT: Another tactic for getting a very easy colored area, is to mash ALL of the vertices in the hilt (you don't gotta do the hilt, I just would suggest you do it for that.) in one little area, or just scale it even more and then assign it. In a way, this can ruin quality, but not if you do it right. =D

When You are done, hit save changes.
Save your model.

Now if you were to open you model in Magos or Wc3 (Don't try Wc3 yet.) You would notice that it is still white.
Why?
Because the texture you used in your UV-Map isn't the actual texture. It is just used for giving you a guide.
Remember how you found your texture? Find it again, but instead of opening it in the MPQ viewer, right-click on it and hit "Copy path to clipboard".
Now take your .mdl (model file) and open it in notepad.
Look for this line...
View attachment 65374
Delete what is inside the quotes and paste your texture name there...
View attachment 65375
Now if you were to open it in Magos, it would have the right texture on the model.
BUT, It might not work in Wc3.
Why?
The material is not assigned to any filter.
How to do that?
View attachment 65392
View attachment 65376
View attachment 65377


Set it to Transparent.
View attachment 65378
Save it in Magos, as a .mdx (IMPORTANT!)
Test it in Wc3.
If it works, Congratulations!:thumbs_up: You made a weapon model!
If yours looks better than the one I made in this tut, Congrats again!
One common error you are going to have is size.
A sword should be anywhere fomr 40 to 90 units long
To measure it in the vertex editor, at the bottom are numbers. The difference from the number at the left of the sword to the right or vice-versa is the length.

Be inspired, and you don't have to make sword.
You could make anything, but certain things (like spheres) can cause your UV-map to get kinda messy.



HINT: If you were to make a gun, you might have to postition it in the viewports a bit differently.
HINT: Practice makes perfect!
HINT: If you want to learn how to attach your weapon. Read this tut: http://www.hiveworkshop.com/forums/...o-attach-a-model-or-an-effect-to-a-unit-7314/
HINT: If you want to learn how to import this, read this tut: http://www.hiveworkshop.com/forums/3d-modeling-tutorials-282/how-to-import-custom-models-32237/
HINT: If you read some of the tut's in Magos (or maybe I will add later), you could make your sword be on fire!
HINT: Using the "Mirror feature, you can make half the sword and make it a whole one!

TIP: Need to separate your UV on the same texture? Need your sword to look like it has more defined shape. (Not one giant shape, but several?) Use the "Merge geoset button" and import another Primative! It allows you to move arround the UV-map, as 2 separate models.
NOTE: Using two separate textures is a COMPLETELY different procedure. I could show you, but it is very complicated (This tut is made for nubs), and you would need a more complete knowledge of models, and another one of Oinkerwinkles tools. (Geoset Merger.)

FAQ:
Just ask questions, and they will be answered!

I hope you learned something from this tut!
Screens of all your cool work is always appreciated!


A special thanks to:
My friend George (Not a Hiver, but an ok guy): For helping me create an awesome model.
Archian: For his tut on how to make units use the weapons (I didn't need that, but it helps the rest of you.
PurgeandFire111: For his tut on how to import this stuff.
 
Top