• 🏆 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!

How to put custom objects into units?

Status
Not open for further replies.
Level 25
Joined
Sep 26, 2009
Messages
2,373
I think he means various models meant as attachments.
Usually you use an aura I think - like Devotion Aura, that affects no unit, has no effect, etc. but instead of Devotion Aura visual effect (the rune on the ground), you put the hat model there and set it's attachment point to head.

Or you do it via trigger editor by attaching special effects to unit - that way you don't have to create millions of auras for various attachments.
 
Level 14
Joined
Nov 17, 2010
Messages
1,265
There are a few different options. You can attach them as a special effect. (Create special effect on unit) and just use the appropriate attachment point.
Chest; Head; Overhead; Origin; Foot,left; Foot,right; Hand,left; Hand,right; Etc.

You can also do this by adding the attachment to an ability and giving it to the unit. In the abilities tab in the object editor there is a field Art - Target. Just add the attachment you want there and set Art - Target Attachment Point 1 to the correct attachment point.

As far as replacing weapons you would either need to find a weaponless model or do a little model editing to remove the old weapon before attaching a new one. Otherwise it would look like he was holding two weapons overlapping in the same hand.

I hope this was clear enough. Good luck!
 
Level 4
Joined
Jul 23, 2014
Messages
73
hm a bit, I'm sorry, it's my fault... Iì'm quite new to this kind of editing.
maybe the best thing is to make a concrete example!
teach me the method you prefer: so take that shield and the peasant.
thanks!
 
Level 14
Joined
Nov 17, 2010
Messages
1,265
Ok go to your object editor

Find the Abilities tab and then look on the left side for a folder that says Special.
Go to the next Folder that says Items
Find the ability called Item Armor Bonus (+1) (I like this ability because it doesn't have an icon.)

Now find the field that says Art - Target
This is where you want to put your shield model
In the field where it says Art - Target Attachment Point 1 you want to double click and it will say add string.
Click add string and type hand and press Ok
Now click add string again and type right (or left depending on which hand you want the shield in) and press ok

You may also want to set Data - Defense Bonus to 0 and change the name to something like attachment shield.
Next go down to where it says Stats - Item Ability and make it false. Now it will be a unit ability.

Now go to the Units tab in the Object Editor and find the Peasant. All you have to do is double click his Abilities - Normal field and add the ability you just made.
Be warned that this means every peasant will have a shield.
If you only want one peasant to have a shield you can use a trigger to add the ability to your unit.
(Unit > Add Ability > choose your ability and your unit. I believe this can be done at Map Initialization.)
 
Level 4
Joined
Jul 23, 2014
Messages
73
kudos to you man, you're awesome

... and what if I want to change the filesize? or weapon? I said about the king etc. can he use a sword for ex?
 
Last edited by a moderator:
Level 14
Joined
Nov 17, 2010
Messages
1,265
For the Mountain King I think you would have to find a weaponless model. A lot of them can be found here

There is also a tool that can help you disarm any unit you would like here
 
Status
Not open for further replies.
Top