- Joined
- Aug 4, 2012
- Messages
- 193
native UnitDamagePoint takes unit whichUnit, real delay, real radius, real x, real y, real amount, boolean attack, boolean ranged, attacktype attackType, damagetype damageType, weapontype weaponType returns boolean
unit whichUnit
- Unit to deal the damage. For example, GetTriggerUnit()
, which is (Triggering Unit) in GUI.real delay
- I'm not 100% on this, but I think it is just for if you want to delay the damage by a few seconds. Usually you will just put in 0
real radius
- The radius of the area you want to damage. From the center point, the radius will extend out and make the function cover a particular circular area. real x
- The x-coordinate of the area you want to damage. (the x-coordinate of the center area)real y
- The y-coordinate of the area you want to damage. (the y-coordinate of the center area)real amount
- The amount of damage to deal.boolean attack
- iirc it will fire the attack event, but I could be wrong. Usually you will have it as true
.boolean ranged
- probably just for some internal game damage handling or something, usually just set it to false
attacktype attackType
- the type of attack to deal. Here is a list of them:damagetype damageType
- the type of damage to deal. Here is a list of them: constant damagetype DAMAGE_TYPE_UNKNOWN = ConvertDamageType(0)
constant damagetype DAMAGE_TYPE_NORMAL = ConvertDamageType(4)
constant damagetype DAMAGE_TYPE_ENHANCED = ConvertDamageType(5)
constant damagetype DAMAGE_TYPE_FIRE = ConvertDamageType(8)
constant damagetype DAMAGE_TYPE_COLD = ConvertDamageType(9)
constant damagetype DAMAGE_TYPE_LIGHTNING = ConvertDamageType(10)
constant damagetype DAMAGE_TYPE_POISON = ConvertDamageType(11)
constant damagetype DAMAGE_TYPE_DISEASE = ConvertDamageType(12)
constant damagetype DAMAGE_TYPE_DIVINE = ConvertDamageType(13)
constant damagetype DAMAGE_TYPE_MAGIC = ConvertDamageType(14)
constant damagetype DAMAGE_TYPE_SONIC = ConvertDamageType(15)
constant damagetype DAMAGE_TYPE_ACID = ConvertDamageType(16)
constant damagetype DAMAGE_TYPE_FORCE = ConvertDamageType(17)
constant damagetype DAMAGE_TYPE_DEATH = ConvertDamageType(18)
constant damagetype DAMAGE_TYPE_MIND = ConvertDamageType(19)
constant damagetype DAMAGE_TYPE_PLANT = ConvertDamageType(20)
constant damagetype DAMAGE_TYPE_DEFENSIVE = ConvertDamageType(21)
constant damagetype DAMAGE_TYPE_DEMOLITION = ConvertDamageType(22)
constant damagetype DAMAGE_TYPE_SLOW_POISON = ConvertDamageType(23)
constant damagetype DAMAGE_TYPE_SPIRIT_LINK = ConvertDamageType(24)
constant damagetype DAMAGE_TYPE_SHADOW_STRIKE = ConvertDamageType(25)
constant damagetype DAMAGE_TYPE_UNIVERSAL = ConvertDamageType(26)
weapontype weaponType
- here is a list of them: constant weapontype WEAPON_TYPE_WHOKNOWS = ConvertWeaponType(0)
constant weapontype WEAPON_TYPE_METAL_LIGHT_CHOP = ConvertWeaponType(1)
constant weapontype WEAPON_TYPE_METAL_MEDIUM_CHOP = ConvertWeaponType(2)
constant weapontype WEAPON_TYPE_METAL_HEAVY_CHOP = ConvertWeaponType(3)
constant weapontype WEAPON_TYPE_METAL_LIGHT_SLICE = ConvertWeaponType(4)
constant weapontype WEAPON_TYPE_METAL_MEDIUM_SLICE = ConvertWeaponType(5)
constant weapontype WEAPON_TYPE_METAL_HEAVY_SLICE = ConvertWeaponType(6)
constant weapontype WEAPON_TYPE_METAL_MEDIUM_BASH = ConvertWeaponType(7)
constant weapontype WEAPON_TYPE_METAL_HEAVY_BASH = ConvertWeaponType(8)
constant weapontype WEAPON_TYPE_METAL_MEDIUM_STAB = ConvertWeaponType(9)
constant weapontype WEAPON_TYPE_METAL_HEAVY_STAB = ConvertWeaponType(10)
constant weapontype WEAPON_TYPE_WOOD_LIGHT_SLICE = ConvertWeaponType(11)
constant weapontype WEAPON_TYPE_WOOD_MEDIUM_SLICE = ConvertWeaponType(12)
constant weapontype WEAPON_TYPE_WOOD_HEAVY_SLICE = ConvertWeaponType(13)
constant weapontype WEAPON_TYPE_WOOD_LIGHT_BASH = ConvertWeaponType(14)
constant weapontype WEAPON_TYPE_WOOD_MEDIUM_BASH = ConvertWeaponType(15)
constant weapontype WEAPON_TYPE_WOOD_HEAVY_BASH = ConvertWeaponType(16)
constant weapontype WEAPON_TYPE_WOOD_LIGHT_STAB = ConvertWeaponType(17)
constant weapontype WEAPON_TYPE_WOOD_MEDIUM_STAB = ConvertWeaponType(18)
constant weapontype WEAPON_TYPE_CLAW_LIGHT_SLICE = ConvertWeaponType(19)
constant weapontype WEAPON_TYPE_CLAW_MEDIUM_SLICE = ConvertWeaponType(20)
constant weapontype WEAPON_TYPE_CLAW_HEAVY_SLICE = ConvertWeaponType(21)
constant weapontype WEAPON_TYPE_AXE_MEDIUM_CHOP = ConvertWeaponType(22)
constant weapontype WEAPON_TYPE_ROCK_HEAVY_BASH = ConvertWeaponType(23)
call UnitDamagePoint(GetTriggerUnit(), 0, 500, GetUnitX(GetTriggerUnit()), GetUnitY(GetTriggerUnit()), 300, true, false, ATTACK_TYPE_NORMAL, DAMAGE_TYPE_NORMAL, WEAPON_TYPE_WHOKNOWS)
null
)