• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Change Classifications in Game

Status
Not open for further replies.
Level 2
Joined
Apr 3, 2007
Messages
21
Hi,
Can someone help me? I'd tried to change the Classification of a Unit per Trigger, using the actions "Add Classification" and "Remove Classification".
This way I've told the Unit (a Ground-Unit targeted as "Ground" and attacks "Ground") to be only targeted as Air and to attack only Air.
But it doesn't works, the Unit still attacks Ground Units and is still attacked by this Ground Units. Can someone tell me why?

Thanx.
 
Level 11
Joined
Jul 12, 2005
Messages
764
A unit's classification does not contain what type of units can it attack, so i really don't know what you're talking about... If you want a groud unit to be a flying one, add the Storm Crow ability to, or replace the unit with a flying one (i suggest this one).
 
Level 8
Joined
Sep 13, 2006
Messages
431
A unit's classification does not contain what type of units can it attack, so i really don't know what you're talking about...

Actually it does. If you examine the classifications listed in GUI, you will see that you can enable and/or disable "attacks ground" and "attacks air," though it tends to have some quirks.

@Udsalg: Maybe just make sure you are referring to the unit correctly. I suggest using "triggering unit," as this reference is not discarded until after the end of the trigger (while others are gone after 0.10 seconds game time). Hope this helps...
 
Level 2
Joined
Apr 3, 2007
Messages
21
Thanks for your Reply's.
I've tried with "triggering Unit" and also with a specific Unit I'd placed in the Editor, but it still doesn't works in both ways. Could this problems result in having a hero as Unit I want to change?
 
Level 8
Joined
Sep 13, 2006
Messages
431
Thanks for your Reply's.
I've tried with "triggering Unit" and also with a specific Unit I'd placed in the Editor, but it still doesn't works in both ways. Could this problems result in having a hero as Unit I want to change?

I doubt it, but experiment to make sure. The best way to solve a problem like this is just plain trial and error, because in many cases, you will find things out that you didn't know before.
 
Level 2
Joined
Apr 3, 2007
Messages
21
Okay it doesn't works with normal Units too.
If somebody has an idea or solution please share it with me.
Thanx.
 
Level 8
Joined
Sep 13, 2006
Messages
431
Okay, so unfortunately, something has changed with newer patches, because a map that I used to work with these things no longer works. So, apparently, classifications now the classifications can't change the way that a unit targets other units or is targetted itself.

So, probably the best way you could work around this is just to use two seperate units, one that is ground/ground and one that is air/air. You can then switch between them to change attack type, etc. Sorry I couldn't be of mroe help...
 
Level 2
Joined
Apr 3, 2007
Messages
21
Mh, it's not good that this action doesn't works anymore.
I'd used this multiple Unit way in an other map, but the problem is I can't find a way to submit the Buffs/Debuffs from on Unit to the other and those very improtant for my map.
 
Level 8
Joined
Sep 13, 2006
Messages
431
Mh, it's not good that this action doesn't works anymore.
I'd used this multiple Unit way in an other map, but the problem is I can't find a way to submit the Buffs/Debuffs from on Unit to the other and those very improtant for my map.

Ya, that does present a problem... not sure that there really is a good way to do it then. Hmmmm.... you could use a morphing spell to keep the buffs but change into something else (like with storm crow form). I tested it and it works, though it looks a little funky, depending on the units you are switching between...
 
Level 2
Joined
Apr 3, 2007
Messages
21
Okay, I've used the Bearform Abb to realise the Abbility and it works in itself.
But the morphed Unit looses all Abb's in it's Basic/Normal-Spellbook-Abbility and also all Abbilities I'd given the Unit in Game. I know how to solve this problem by adding the lost spells via trigger's etc. but I want to put the Morph Abb into the Spellbook Abb of the Unit and so the metamorphose won't work if the spellbook is earased (so the Unit turns back in normal Form automaticly or Warcraft shutsdown). Do anyone know if there is a way to stop warcraft from earasing the Abbs when using Bearform/Crowform/... ?
 
Status
Not open for further replies.
Top