- Joined
- Dec 12, 2012
- Messages
- 1,007
Hello all,
I wounder if there is some "hidden" functionality in the World Editor which isn't specified at all in the libraries, but still accessable.
According to the common.j , there are seven different AttackTypes, namely:
This is also what you get in GUI when using the UnitDamageTargetBJ function to deal damage to a target.
BUT if you use ConvertAttackType(7) as an AttackType-Parameter for this function, you will get a "hidden" AttackType. Just like this:
This "hidden" AttackType has some interesting behaviour: If you want to deal 1 damage on a unit with it, it deals in reality:
With this, its quite easy to identify a units armortype. But even more interesting is: Are there more hidden functionalities in the World Editor? A ConvertAttackType(8) doesn't do anything, so after checking all integers up to 10000, this is the only hidden AttackType. There is also a huge amount of DamageTypes (over 1000), but they don't differ in any kind, so they might be uninteressting. But you can convert many other things, like unitevents. So it would be interessting to know if there are more hidden and usefull functions in the WE.
Does anybody know something about this? I googled for several days now and didn't find anything about this...
Greetings,
lfh
I wounder if there is some "hidden" functionality in the World Editor which isn't specified at all in the libraries, but still accessable.
According to the common.j , there are seven different AttackTypes, namely:
JASS:
ATTACK_TYPE_NORMAL = ConvertAttackType(0)
ATTACK_TYPE_MELEE = ConvertAttackType(1)
ATTACK_TYPE_PIERCE = ConvertAttackType(2)
ATTACK_TYPE_SIEGE = ConvertAttackType(3)
ATTACK_TYPE_MAGIC = ConvertAttackType(4)
ATTACK_TYPE_CHAOS = ConvertAttackType(5)
ATTACK_TYPE_HERO = ConvertAttackType(6)
This is also what you get in GUI when using the UnitDamageTargetBJ function to deal damage to a target.
BUT if you use ConvertAttackType(7) as an AttackType-Parameter for this function, you will get a "hidden" AttackType. Just like this:
JASS:
call UnitDamageTargetBJ( unitAttacker, unitAttacked , 1.0, ConvertAttackType(7), DAMAGE_TYPE_UNIVERSAL )
This "hidden" AttackType has some interesting behaviour: If you want to deal 1 damage on a unit with it, it deals in reality:
- 1 Damage to units with armortype MEDIUM
- 1 Damage to units with armortype FORTIFIED
- 25 Damage to units with armortype UNARMORED
- 150 Damage to units with armortype HERO
- 400 Damage to units with armortype DIVINE
- 522 Damage to units with armortype HEAVY
- 522 Damage to units with armortype NORMAL
- 2048 Damage to units with armortype LIGHT
With this, its quite easy to identify a units armortype. But even more interesting is: Are there more hidden functionalities in the World Editor? A ConvertAttackType(8) doesn't do anything, so after checking all integers up to 10000, this is the only hidden AttackType. There is also a huge amount of DamageTypes (over 1000), but they don't differ in any kind, so they might be uninteressting. But you can convert many other things, like unitevents. So it would be interessting to know if there are more hidden and usefull functions in the WE.
Does anybody know something about this? I googled for several days now and didn't find anything about this...
Greetings,
lfh
Last edited: