• 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.

Abilities changing the Defense Type ?

Status
Not open for further replies.
Level 9
Joined
Apr 28, 2009
Messages
538
Could someone help me?
I'm making an ability that adds +2 to armor.

The thing is i want that ability to change the unit's Defense Type too. (for exaple form Defense Type: Large to Medium

Is this possible?
 
Level 8
Joined
Aug 23, 2007
Messages
491
Probably not possible to unit data so you have to do it with triggers. You can get ur ability that adds 2 armor. Then make your trigger.
Event-A unit casts a spell or if its passive, a unit gets the ability
Condition the spell or ability is equal to ......
Action Change the unit's defense type to ......
Hold on 1 sec lemme see if I can do it for you.
 
Level 9
Joined
Apr 28, 2009
Messages
538
Restor, i don't think it would work, but could you tell me the name of that ability to try?
I will let you know if it works.
 
Level 8
Joined
Aug 6, 2008
Messages
451
Use Chaos. It can change unittype from one to another, so you can basicly do anything with it.

I think it has some problems though, like loosing some bonus stuff that old unit had and stuff like that. That can luckily be solved by triggering all that shit. Using systems like UnitProperties for example.
 
Level 9
Joined
Apr 28, 2009
Messages
538
graystuff111, until now, your ideea seems to be the only one that could help.
I don't see any other way of changing a unit's defense type except for using root.
However i do not know how to make it work.

EDIT: Chaos uses "Data - New Unit Type" so it's useless because i have to much units and to much abilities to do such thing.
 
Last edited:
Level 8
Joined
Nov 9, 2008
Messages
502
Using Chaos is likely to be your best bet. This is the ability Blizzard created explicitly for such a purpose.

I used such a method for 'equiping weapons' system and encounted no hassles (bar having to make near duplicates of your units).
 
Level 3
Joined
Jul 14, 2008
Messages
41
Changing units armor is possible, cause Island Defense made such thing with Demon (You research one upgrade and Demon armor is changed to fortified).
So yea changing units armor is possible.

That's an upgrade, it's even used in w3 Ladder, they are talking about spells here.
 
Level 9
Joined
Apr 28, 2009
Messages
538
i have already told you: "Chaos" it's not the solution because this ability uses "Data - New Unit Type" wich meams that when this ability is activated, the unit will change in another unit (the unit will be replaced, it won't just chage it's stats and defense type, attack type, etc)
It's same thing as "Call To Arms", "Bear Form", etc

The reason i cannot use one of this abilities as base ability is because i have a lots of unit types in map, so i cannot make a duplicate for each of them.

I cannot use "Upgrades" too because this abilities will come with items.
 
Level 9
Joined
Apr 28, 2009
Messages
538
bump c'mon there's just no way of changing units defense type? :sad::sad:
Not even by triggers? Updates? Abilities?

Anything except for replacing with another similar unit?:sad:
 
Level 8
Joined
Nov 9, 2008
Messages
502
If Blizzard ever made an upgrade to change defense type they would probably use Chaos :p

Really, how many units would you have to duplicate because I see that as the only way...
 
Level 9
Joined
Apr 28, 2009
Messages
538
actually, there is an ability that changes the defense type, WITHOUT upgrade or replacing the unit with another. (my only hope)

This ability is "ROOT". Yes, the "root" form ancient protector (and other night elf buildings) but the problem is: when i cast this ability the unit will not be able to move and attack anymore. :( After i cast it again, the unit will return to it's default state (wich is good).
 
Level 8
Joined
Nov 9, 2008
Messages
502
Ye but that's a very specialised ability which you probably can't customise. You can edit the 'attacks allowed' but as for move speed it's probably hard coded that the unit becomes a building.
 
Level 21
Joined
Dec 9, 2007
Messages
3,096
Let's think like this...
Using an upgrade, you can change a unit's defense type. We all know this.
Now, we can use it without any triggers with the Glyph abilities. Take a look, they give an upgrade.
But BEWARE, once an upgrade is done, it cannot be undone!
Now, we only need to add the upgrade to the item. But, there's a problem. The item can't be held in the inventory. It has to be used by clicking on it or when acquired.

As I know, sadvisor tested this theory and it did not work.

Any ideas?
 
Level 9
Joined
Apr 28, 2009
Messages
538
well i guess the only question that remains now is:
It is possible to change a unit's defense type with a Glyph of Fortification?
If yes, how? (triggers are good too)
 
Level 3
Joined
Feb 18, 2005
Messages
50
The ability has to be activated... Used!
But then, how could the item be held in the inventory?
Things will get more complicated if you use triggers.
>.>
I need to take a better look at these things.

I believe you can add the ability "Inventory (Hero)" to non hero units, then if you want the item to be used there is a value labeled "Perish" or something like that in the item screen and you just check that to false. Should work fine
 
Level 8
Joined
Aug 6, 2008
Messages
451
If I were you, I would just trigger all damage types and armor types and controll all damage dealt with triggers and things like this would become ridicilously easy.

Of course setting up a system like that takes shitloads of coding.
 
Level 9
Joined
Apr 28, 2009
Messages
538
you don't understand, do you?
I have over 35 types of units.

That would mean i have to do:
35 x 4(attack types) x 4(defense types) units.
 
Level 3
Joined
Feb 18, 2005
Messages
50
520 combos, yeah it takes time but w/ copy and paste it isn't as bad. Sorry, I don't have any other solution for ya man :(
 
Level 6
Joined
May 7, 2009
Messages
228
How about this?

Make a ton of different upgrades for each defense type. When a unit acquires or drops an item, give it the appropriate upgrade.

The only problem with this is that if the player keeps picking up and dropping them item, the upgrades will be used up pretty quickly.

Still it's the best thing I can think. I'm guessing you're pretty much out of luck.
 
Level 8
Joined
Aug 6, 2008
Messages
451
Just get some damagedetection system and trigger some neat, damagetype & armortype thingy that controls damage taken in your map. It takes some work but also solves your problem and is only reasonable solution really.
 
Level 21
Joined
Dec 9, 2007
Messages
3,096
I think this is really impossible.
But now I need something similar...
I need a hero to be able to change his armor and attack type.
Armors:
Unarmored
Cloth
Leather
Mail
Plate
Attacks:
Unarmed
One-Handed
Two-Handed
Ranged

I guess you need something similar.
I hope that at least the 1.24 patch will open a way to solve this.
 
Level 9
Joined
Apr 28, 2009
Messages
538
well i guess i should just quit all the maps i`m working on wxcept for the modern-warfare-type one.

I don't need such thing on that kind of map.
 
Level 21
Joined
Dec 9, 2007
Messages
3,096
Hey, but in your map, how many units do need this thing?
In my map... only one.
And I'm using the BX-TRS II inventory so i can't replace the unit or something like that...
Or like those futuristic maps where the heroes have some fat-ass smart weapons and armors that change their stats. They are protected.
 
Level 9
Joined
Apr 28, 2009
Messages
538
OFFTOPIC Start
[neah...my modern-warfare-type map has nothing to do with zombies, laser guns and such things. :) ]
OFFTOPIC End
 
Level 36
Joined
Jul 1, 2007
Messages
6,677
I think this is really impossible.
But now I need something similar...
I need a hero to be able to change his armor and attack type.
Armors:
Unarmored
Cloth
Leather
Mail
Plate
Attacks:
Unarmed
One-Handed
Two-Handed
Ranged

I guess you need something similar.
I hope that at least the 1.24 patch will open a way to solve this.

Unarmored: Villager Male
Cloth: Villager Male 2
Leather: Weaponless Peasant
Mail: Weaponless Militia
Plate: Weaponless Footman

Now you just need to add 2H and ranged anims.
 
Level 8
Joined
Aug 6, 2008
Messages
451
Just use Chaos. Its not a big job to generate as much as few thousand abilities with grimex. Check system called UnitProperties in wc3c.net script section. It uses a nice lua script to create 150 item stats bonus abilities for that system.

You could maybe try something similiar to create those Chaos abilities and unit types for all possible combinations. ( if there aint too much of them .. )
 
Status
Not open for further replies.
Top