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

[Solved] Peon Classification Via Trigger Doesn't Hide Idle Worker Icon Anymore?

Status
Not open for further replies.
Level 2
Joined
Aug 3, 2018
Messages
13
Hello,

I'm not sure if I've done something incorrectly, it has been a while since I've tried this method.

I've tried to add the peon classification via trigger to my hero but the idle worker icon displays.

I then tried adding a trigger to remove the peon classification under the add peon classification. It removes the icon but it no longer disables my hero's auto attack (which is what I want it to do originally).

Lastly, I tried to add the worker classification to my hero through the object editor and then use trigger to remove the classification - again, it removes the icon but it no longer disables my hero's auto attack.

Can someone help me solve how to disable auto acquire enemy to attack? I want the hero to only attack when I command it to attack a certain unit (I've also tried setting both teams to treat each other as allies but that makes it difficult to identify who is the enemy).
 
Level 2
Joined
Aug 3, 2018
Messages
13
Go to Peon in Object editor and scroll all the way down until you find Unit Classification : Worker and put it to empty. just like this.

Screenshot - d0fab0acb4b1f2dfef0cf61522d32349 - Gyazo
I don't think you understood what I was trying to achieve. I know that removing it from the object editor will remove the idle worker icon but that's not the thing I'm trying to get at.

I want my hero unit (which isn't a peon) to take the classification of a peon without the idle worker icon. The reason for this is because it will stop auto attacking units that within range.

But the problem is, when I give it the classification through trigger, although it makes the unit (my hero) stop auto attacking units nearby, it also displays the idle worker icon. There used to be a way where you can still apply the peon classification but not have the idle worker icon so that it won't auto attack - the question is, has this glitch been removed from the recent patch updates or have I been missing something?
 
Level 18
Joined
Nov 21, 2012
Messages
835
I can confirm that in 1.29.2 game version UnitAddType(whichUnit, UNIT_TYPE_PEON) works. Auto-attack is disabled and no idle worker icon in left corner. I don't know how it behaves in 1.30

If it doesnt work in 1.30 try maybe
To create a unit that ignores all enemies except when it is being attacked you can use 'Apiv' (Permanent Invisibility) with the duration set to -1 and auto acquire attack targets to false. Now the unit won't be invisible but still not auto acquire targets.
its from The Warcraft III Ability Guide - Wc3C.net
 
Level 2
Joined
Aug 3, 2018
Messages
13
I can confirm that in 1.29.2 game version UnitAddType(whichUnit, UNIT_TYPE_PEON) works. Auto-attack is disabled and no idle worker icon in left corner. I don't know how it behaves in 1.30

If it doesnt work in 1.30 try maybe

its from The Warcraft III Ability Guide - Wc3C.net
Thank you, I'll have a check of the permanent invisibility one but doesn't that mean that they are not visibility to the enemy? Do I have to add vision to the enemy for them to see me?
 
Level 2
Joined
Aug 3, 2018
Messages
13
Becouse of duration set to "-1" unit will be visible, so no need to add vision. You have 1.30 ver ?
Turns out it might have been because I had it on map initialization so that the classification was added before the loading screen therefore making it show the icon. It now works, thanks so much! :)

I think I'm planning on making abilities that apply invisibility so that's why I don't want to approach the permanent invisibility method in case it bugs with wind walk or whatever spell that I might base my invisibility spells off of.
 
Status
Not open for further replies.
Top