#
Class: Unit#
Hierarchy↳ Unit
#
Constructors#
constructornew Unit(owner: number | MapPlayer, unitId: number, x: number, y: number, face: number, skinId?: number): Unit
Creates a unit.
#
Parameters:Name | Type | Description |
---|---|---|
owner | number | MapPlayer | The owner of the unit. |
unitId | number | The rawcode of the unit. |
x | number | The x-coordinate of the unit. |
y | number | The y-coordinate of the unit. |
face | number | The direction that the unit will be facing in degrees. |
skinId? | number | The skin of the unit. |
Returns: Unit
Defined in: handles/unit.ts:15
#
Properties#
handle• Readonly
handle: unit
Defined in: handles/unit.ts:15
#
Accessors#
acquireRangeacquireRange(): number
Sets a unit's acquire range. This is the value that a unit uses to choose targets to engage with. Note that this is not the attack range. When acquisition range is greater than attack range, the unit will attempt to move towards acquired targets, and then attack. Setting acquisition range lower than attack range in the object editor limits the unit's attack range to the acquisition range, but changing a unit's acquisition range with this native does not change its attack range, nor the value displayed in the UI.
Returns: number
Defined in: handles/unit.ts:49
acquireRange(value: number): void
Sets a unit's acquire range. This is the value that a unit uses to choose targets to engage with. Note that this is not the attack range. When acquisition range is greater than attack range, the unit will attempt to move towards acquired targets, and then attack. Setting acquisition range lower than attack range in the object editor limits the unit's attack range to the acquisition range, but changing a unit's acquisition range with this native does not change its attack range, nor the value displayed in the UI.
note
It is a myth that reducing acquire range with this native can limit a unit's attack range.
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:45
#
agilityagility(): number
Returns: number
Defined in: handles/unit.ts:53
agility(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:57
#
armorarmor(): number
Returns: number
Defined in: handles/unit.ts:61
armor(armorAmount: number): void
#
Parameters:Name | Type |
---|---|
armorAmount | number |
Returns: void
Defined in: handles/unit.ts:65
#
canSleepcanSleep(): boolean
Returns: boolean
Defined in: handles/unit.ts:73
canSleep(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:69
#
collisionSizecollisionSize(): number
Returns: number
Defined in: handles/unit.ts:77
#
colorcolor(whichColor: playercolor): void
#
Parameters:Name | Type |
---|---|
whichColor | playercolor |
Returns: void
Defined in: handles/unit.ts:81
#
currentOrdercurrentOrder(): number
Returns: number
Defined in: handles/unit.ts:85
#
defaultAcquireRangedefaultAcquireRange(): number
Returns: number
Defined in: handles/unit.ts:89
#
defaultFlyHeightdefaultFlyHeight(): number
Returns: number
Defined in: handles/unit.ts:93
#
defaultMoveSpeeddefaultMoveSpeed(): number
Returns: number
Defined in: handles/unit.ts:97
#
defaultPropWindowdefaultPropWindow(): number
Returns a unit's default propulsion window angle in degrees.
note
This function is the odd case in the asymmetric prop window API, since the
other prop window natives use radians.
Returns: number
Defined in: handles/unit.ts:106
#
defaultTurnSpeeddefaultTurnSpeed(): number
Returns: number
Defined in: handles/unit.ts:110
#
experienceexperience(): number
Returns: number
Defined in: handles/unit.ts:114
experience(newXpVal: number): void
#
Parameters:Name | Type |
---|---|
newXpVal | number |
Returns: void
Defined in: handles/unit.ts:118
#
facingfacing(): number
Returns: number
The units facing in degrees.
Defined in: handles/unit.ts:129
facing(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:122
#
foodMadefoodMade(): number
Returns: number
Defined in: handles/unit.ts:133
#
foodUsedfoodUsed(): number
Returns: number
Defined in: handles/unit.ts:137
#
idid(): number
Get the unique ID of the handle. The ID is recycled once you destroy the object.
Returns: number
The unique ID of a handle object.
Defined in: handles/handle.ts:18
#
ignoreAlarmToggledignoreAlarmToggled(): boolean
Returns: boolean
Defined in: handles/unit.ts:141
#
intelligenceintelligence(): number
Returns: number
Defined in: handles/unit.ts:145
intelligence(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:149
#
inventorySizeinventorySize(): number
Returns: number
Defined in: handles/unit.ts:153
#
invulnerableinvulnerable(): boolean
Renders a unit invulnerable/lifts that specific invulnerability.
Returns: boolean
Defined in: handles/unit.ts:167
invulnerable(flag: boolean): void
Renders a unit invulnerable/lifts that specific invulnerability.
note
The native seems to employ the 'Avul'
ability, which is defined in the default AbilityData.slk.
If there is no 'Avul'
defined, this will crash the game.
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:163
#
levellevel(): number
Returns: number
Defined in: handles/unit.ts:171
#
lifelife(): number
Get the Widget's life.
Returns: number
Defined in: handles/widget.ts:9
life(value: number): void
Set the Widget's life.
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/widget.ts:16
#
localZlocalZ(): number
Returns: number
Defined in: handles/unit.ts:175
#
manamana(): number
Returns: number
Defined in: handles/unit.ts:179
mana(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:183
#
maxLifemaxLife(): number
Returns: number
Defined in: handles/unit.ts:187
maxLife(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:191
#
maxManamaxMana(): number
Returns: number
Defined in: handles/unit.ts:195
maxMana(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:199
#
moveSpeedmoveSpeed(): number
Returns: number
Defined in: handles/unit.ts:207
moveSpeed(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:203
#
namename(): string
async
Returns: string
Defined in: handles/unit.ts:214
name(value: string): void
#
Parameters:Name | Type |
---|---|
value | string |
Returns: void
Defined in: handles/unit.ts:218
#
namePropernameProper(): string
Returns the hero's "Proper Name", which is the name displayed above the level bar.
note
Will return 'null' on non-hero units.
Returns: string
Defined in: handles/unit.ts:231
nameProper(value: string): void
#
Parameters:Name | Type |
---|---|
value | string |
Returns: void
Defined in: handles/unit.ts:222
#
ownerowner(): MapPlayer
Returns: MapPlayer
Defined in: handles/unit.ts:239
owner(whichPlayer: MapPlayer): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: void
Defined in: handles/unit.ts:235
#
pausedpaused(): boolean
Pauses a unit. A paused unit has the following properties:
- Buffs/effects are suspended
- Orders are stored when paused and fired on unpause
- The paused unit does not accept powerups.
addItem
returns true but the item is not picked up
Returns: boolean
true if the unit is paused
Defined in: handles/unit.ts:256
paused(flag: boolean): void
Pauses a unit. A paused unit has the following properties:
- Buffs/effects are suspended
- Orders are stored when paused and fired on unpause
- The paused unit does not accept powerups.
addItem
returns true but the item is not picked up
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:249
#
pointpoint(): Point
bug
If the unit is loaded into a zeppelin this will not return the position
of the zeppelin but the last position of the unit before it was loaded into
the zeppelin.
Returns: Point
Defined in: handles/unit.ts:265
point(whichPoint: Point): void
#
Parameters:Name | Type |
---|---|
whichPoint | Point |
Returns: void
Defined in: handles/unit.ts:269
#
pointValuepointValue(): number
Returns: number
Defined in: handles/unit.ts:273
#
propWindowpropWindow(): number
Returns a unit's propulsion window angle in radians.
http://www.hiveworkshop.com/forums/2391397-post20.html
Returns: number
Defined in: handles/unit.ts:298
propWindow(newPropWindowAngle: number): void
Sets a unit's propulsion window to the specified angle (in radians). The propulsion window determines at which facing angle difference to the target command's location (move, attack, patrol, smart) a unit will begin to move if movement is required to fulfil the command, or if it will turn without movement. A propulsion window of 0 makes the unit unable to move at all. A propulsion window of 180 will force it to start moving as soon as the command is given (if movement is required). In practice, this means that setting a unit's prop window to 0 will prevent it from attacking.
http://www.hiveworkshop.com/forums/2391397-post20.html
#
Parameters:Name | Type | Description |
---|---|---|
newPropWindowAngle | number | The propulsion window angle to assign. Should be in radians. |
Returns: void
Defined in: handles/unit.ts:291
#
racerace(): race
Returns: race
Defined in: handles/unit.ts:302
#
rallyDestructablerallyDestructable(): Destructable
Returns: Destructable
Defined in: handles/unit.ts:306
#
rallyPointrallyPoint(): Point
Returns: Point
Defined in: handles/unit.ts:310
#
rallyUnitrallyUnit(): Unit
Returns: Unit
Defined in: handles/unit.ts:314
#
resourceAmountresourceAmount(): number
Returns: number
Defined in: handles/unit.ts:322
resourceAmount(amount: number): void
#
Parameters:Name | Type |
---|---|
amount | number |
Returns: void
Defined in: handles/unit.ts:318
#
selectableselectable(): boolean
Returns: boolean
Defined in: handles/unit.ts:326
#
selectionScaleselectionScale(): number
Returns: number
Defined in: handles/unit.ts:334
selectionScale(scale: number): void
#
Parameters:Name | Type |
---|---|
scale | number |
Returns: void
Defined in: handles/unit.ts:330
#
showshow(): boolean
Returns: boolean
Defined in: handles/unit.ts:343
show(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:339
#
skillPointsskillPoints(): number
Returns the units available skill points.
Returns: number
Defined in: handles/unit.ts:358
skillPoints(skillPointDelta: number): void
Adds the amount to the units available skill points. Calling with a negative number reduces the skill points by that amount. Returns false if the amount of available skill points is already zero and if it's called with any non-positive number. Returns true in any other case.
note
If skillPointDelta
is greater than the amount of skillpoints the hero
actually can spend (like 9 for three 3-level abilities) only that amount will
be added. Negative skillPointDelta
works as expected.
#
Parameters:Name | Type |
---|---|
skillPointDelta | number |
Returns: void
Defined in: handles/unit.ts:372
#
skinskin(): number
Returns: number
Defined in: handles/unit.ts:347
skin(skinId: number): void
#
Parameters:Name | Type |
---|---|
skinId | number |
Returns: void
Defined in: handles/unit.ts:351
#
sleepingsleeping(): boolean
Returns: boolean
Defined in: handles/unit.ts:376
#
strengthstrength(): number
Returns: number
Defined in: handles/unit.ts:380
strength(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:384
#
turnSpeedturnSpeed(): number
Returns: number
Defined in: handles/unit.ts:392
turnSpeed(value: number): void
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:388
#
typeIdtypeId(): number
Returns: number
Defined in: handles/unit.ts:396
#
userDatauserData(): number
Returns: number
Defined in: handles/unit.ts:400
userData(value: number): void
Sets a single custom integer for a unit.
note
This value is not used by any standard mechanisms in Warcraft III.
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:409
#
waygateActivewaygateActive(): boolean
Returns: boolean
Defined in: handles/unit.ts:417
waygateActive(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:413
#
xx(): number
bug
If the unit is loaded into a zeppelin this will not return the position
of the zeppelin but the last position of the unit before it was loaded into
the zeppelin.
Returns: number
Defined in: handles/unit.ts:426
x(value: number): void
note
If the unit has movementspeed of zero the unit will be moved but the model of the unit will not move.
note
This does not cancel orders of the unit. setPosition
does cancel orders.
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:434
#
yy(): number
Returns: number
Defined in: handles/unit.ts:438
y(value: number): void
note
If the unit has movementspeed of zero the unit will be moved but the model of the unit will not move.
note
This does not cancel orders of the unit. setPosition
does cancel orders.
#
Parameters:Name | Type |
---|---|
value | number |
Returns: void
Defined in: handles/unit.ts:446
#
zz(): number
Returns: number
Defined in: handles/unit.ts:450
#
Methods#
addAbilityaddAbility(abilityId: number): boolean
#
Parameters:Name | Type |
---|---|
abilityId | number |
Returns: boolean
Defined in: handles/unit.ts:454
#
addAnimationPropsaddAnimationProps(animProperties: string, add: boolean): void
#
Parameters:Name | Type |
---|---|
animProperties | string |
add | boolean |
Returns: void
Defined in: handles/unit.ts:458
#
addExperienceaddExperience(xpToAdd: number, showEyeCandy: boolean): void
Adds the input value of experience to the hero unit specified.
If the experience added exceeds the amount required for the hero to gain a level, then it will force the unit to gain a level and the remaining experience will spill over for the next level.
bug
Adding negative value to experience will decrease it
by the stated value, but won't lower the level even if the experience value
after deduction is lower than the lower bound of the experience required to get
the stated level.
bug
If the value will become lower than zero, the experience won't be negative, instead of it it'll be equal
to 4294967296+(supposed_negative_experience_value)
.
#
Parameters:Name | Type | Description |
---|---|---|
xpToAdd | number | The amount of experience to add to the hero unit. |
showEyeCandy | boolean | If the boolean input is true, then the hero-level-gain effect will be shown if the hero gains a level from the added experience. |
Returns: void
Defined in: handles/unit.ts:478
#
addIndicatoraddIndicator(red: number, blue: number, green: number, alpha: number): void
#
Parameters:Name | Type |
---|---|
red | number |
blue | number |
green | number |
alpha | number |
Returns: void
Defined in: handles/unit.ts:482
#
addItemaddItem(whichItem: Item): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
Returns: boolean
Defined in: handles/unit.ts:486
#
addItemByIdaddItemById(itemId: number): Item
#
Parameters:Name | Type |
---|---|
itemId | number |
Returns: Item
Defined in: handles/unit.ts:490
#
addItemToSlotByIdaddItemToSlotById(itemId: number, itemSlot: number): boolean
#
Parameters:Name | Type |
---|---|
itemId | number |
itemSlot | number |
Returns: boolean
Defined in: handles/unit.ts:494
#
addItemToStockaddItemToStock(itemId: number, currentStock: number, stockMax: number): void
#
Parameters:Name | Type |
---|---|
itemId | number |
currentStock | number |
stockMax | number |
Returns: void
Defined in: handles/unit.ts:498
#
addResourceAmountaddResourceAmount(amount: number): void
Adds the amount more gold to the whichUnit gold mine.
bug
If the value after adding negative amount will be less than zero, then it
will display negative resource amount, but if some peasant or peon will try to
gather resources from such a mine, he will bring back 0 gold and the mine will
be auto-destroyed.
#
Parameters:Name | Type | Description |
---|---|---|
amount | number | The amount of resources to add to the unit. |
Returns: void
Defined in: handles/unit.ts:511
#
addSleepPermaddSleepPerm(add: boolean): void
#
Parameters:Name | Type |
---|---|
add | boolean |
Returns: void
Defined in: handles/unit.ts:515
#
addTypeaddType(whichUnitType: unittype): boolean
#
Parameters:Name | Type |
---|---|
whichUnitType | unittype |
Returns: boolean
Defined in: handles/unit.ts:519
#
addUnitToStockaddUnitToStock(unitId: number, currentStock: number, stockMax: number): void
#
Parameters:Name | Type |
---|---|
unitId | number |
currentStock | number |
stockMax | number |
Returns: void
Defined in: handles/unit.ts:523
#
applyTimedLifeapplyTimedLife(buffId: number, duration: number): void
#
Parameters:Name | Type |
---|---|
buffId | number |
duration | number |
Returns: void
Defined in: handles/unit.ts:527
#
attachSoundattachSound(sound: Sound): void
#
Parameters:Name | Type |
---|---|
sound | Sound |
Returns: void
Defined in: handles/unit.ts:531
#
canSleepPermcanSleepPerm(): boolean
Returns: boolean
Defined in: handles/unit.ts:539
#
cancelTimedLifecancelTimedLife(): void
Returns: void
Defined in: handles/unit.ts:535
#
countBuffscountBuffs(removePositive: boolean, removeNegative: boolean, magic: boolean, physical: boolean, timedLife: boolean, aura: boolean, autoDispel: boolean): number
#
Parameters:Name | Type |
---|---|
removePositive | boolean |
removeNegative | boolean |
magic | boolean |
physical | boolean |
timedLife | boolean |
aura | boolean |
autoDispel | boolean |
Returns: number
Defined in: handles/unit.ts:543
#
damageAtdamageAt(delay: number, radius: number, x: number, y: number, amount: number, attack: boolean, ranged: boolean, attackType: attacktype, damageType: damagetype, weaponType: weapontype): boolean
#
Parameters:Name | Type |
---|---|
delay | number |
radius | number |
x | number |
y | number |
amount | number |
attack | boolean |
ranged | boolean |
attackType | attacktype |
damageType | damagetype |
weaponType | weapontype |
Returns: boolean
Defined in: handles/unit.ts:547
#
damageTargetdamageTarget(target: widget, amount: number, attack: boolean, ranged: boolean, attackType: attacktype, damageType: damagetype, weaponType: weapontype): boolean
Deals damage to target widget from a source unit.
note
For some insight about the different configurations of the different types see this post.
#
Parameters:Name | Type | Description |
---|---|---|
target | widget | The target being damaged. |
amount | number | How much damage is being dealt. |
attack | boolean | Consider the damage dealt as being an attack. |
ranged | boolean | Consider the damage dealt as being from a ranged source. |
attackType | attacktype | |
damageType | damagetype | |
weaponType | weapontype |
Returns: boolean
Defined in: handles/unit.ts:574
#
decAbilityLeveldecAbilityLevel(abilCode: number): number
Decreases the level of a unit's ability by 1. The level will not go below 1.
#
Parameters:Name | Type | Description |
---|---|---|
abilCode | number | The four digit rawcode representation of the ability. |
Returns: number
The new ability level.
Defined in: handles/unit.ts:583
#
destroydestroy(): void
Instantly removes the unit from the game.
Returns: void
Defined in: handles/unit.ts:590
#
disableAbilitydisableAbility(abilId: number, flag: boolean, hideUI: boolean): void
#
Parameters:Name | Type |
---|---|
abilId | number |
flag | boolean |
hideUI | boolean |
Returns: void
Defined in: handles/unit.ts:594
#
dropItemdropItem(whichItem: Item, x: number, y: number): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
x | number |
y | number |
Returns: boolean
Defined in: handles/unit.ts:598
#
dropItemFromSlotdropItemFromSlot(whichItem: Item, slot: number): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
slot | number |
Returns: boolean
Defined in: handles/unit.ts:602
#
dropItemTargetdropItemTarget(whichItem: Item, target: Widget): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
target | Widget |
Returns: boolean
Defined in: handles/unit.ts:606
#
endAbilityCooldownendAbilityCooldown(abilCode: number): void
#
Parameters:Name | Type |
---|---|
abilCode | number |
Returns: void
Defined in: handles/unit.ts:610
#
getAbilitygetAbility(abilId: number): ability
#
Parameters:Name | Type |
---|---|
abilId | number |
Returns: ability
Defined in: handles/unit.ts:614
#
getAbilityByIndexgetAbilityByIndex(index: number): ability
#
Parameters:Name | Type |
---|---|
index | number |
Returns: ability
Defined in: handles/unit.ts:618
#
getAbilityCooldowngetAbilityCooldown(abilId: number, level: number): number
#
Parameters:Name | Type |
---|---|
abilId | number |
level | number |
Returns: number
Defined in: handles/unit.ts:622
#
getAbilityCooldownRemaininggetAbilityCooldownRemaining(abilId: number): number
#
Parameters:Name | Type |
---|---|
abilId | number |
Returns: number
Defined in: handles/unit.ts:626
#
getAbilityLevelgetAbilityLevel(abilCode: number): number
Returns the level of the ability for the unit.
note
This function is not zero indexed.
#
Parameters:Name | Type |
---|---|
abilCode | number |
Returns: number
Defined in: handles/unit.ts:634
#
getAbilityManaCostgetAbilityManaCost(abilId: number, level: number): number
#
Parameters:Name | Type |
---|---|
abilId | number |
level | number |
Returns: number
Defined in: handles/unit.ts:638
#
getAgilitygetAgility(includeBonuses: boolean): number
#
Parameters:Name | Type |
---|---|
includeBonuses | boolean |
Returns: number
Defined in: handles/unit.ts:642
#
getAttackCooldowngetAttackCooldown(weaponIndex: number): number
#
Parameters:Name | Type |
---|---|
weaponIndex | number |
Returns: number
Defined in: handles/unit.ts:646
#
getBaseDamagegetBaseDamage(weaponIndex: number): number
#
Parameters:Name | Type |
---|---|
weaponIndex | number |
Returns: number
Defined in: handles/unit.ts:650
#
getDiceNumbergetDiceNumber(weaponIndex: number): number
#
Parameters:Name | Type |
---|---|
weaponIndex | number |
Returns: number
Defined in: handles/unit.ts:654
#
getDiceSidesgetDiceSides(weaponIndex: number): number
#
Parameters:Name | Type |
---|---|
weaponIndex | number |
Returns: number
Defined in: handles/unit.ts:658
#
getFieldgetField(field: unitbooleanfield | unitintegerfield | unitrealfield | unitstringfield): string | number | boolean
#
Parameters:Name | Type |
---|---|
field | unitbooleanfield | unitintegerfield | unitrealfield | unitstringfield |
Returns: string | number | boolean
Defined in: handles/unit.ts:662
#
getHeroLevelgetHeroLevel(): number
Returns: number
Defined in: handles/unit.ts:691
#
getIgnoreAlarmgetIgnoreAlarm(flag: boolean): boolean
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: boolean
Defined in: handles/unit.ts:695
#
getIntelligencegetIntelligence(includeBonuses: boolean): number
#
Parameters:Name | Type |
---|---|
includeBonuses | boolean |
Returns: number
Defined in: handles/unit.ts:699
#
getItemInSlotgetItemInSlot(slot: number): Item
#
Parameters:Name | Type |
---|---|
slot | number |
Returns: Item
Defined in: handles/unit.ts:703
#
getStategetState(whichUnitState: unitstate): number
#
Parameters:Name | Type |
---|---|
whichUnitState | unitstate |
Returns: number
Defined in: handles/unit.ts:707
#
getStrengthgetStrength(includeBonuses: boolean): number
#
Parameters:Name | Type |
---|---|
includeBonuses | boolean |
Returns: number
Defined in: handles/unit.ts:711
#
getflyHeightgetflyHeight(): number
Returns: number
Defined in: handles/unit.ts:687
#
hasBuffshasBuffs(removePositive: boolean, removeNegative: boolean, magic: boolean, physical: boolean, timedLife: boolean, aura: boolean, autoDispel: boolean): boolean
#
Parameters:Name | Type |
---|---|
removePositive | boolean |
removeNegative | boolean |
magic | boolean |
physical | boolean |
timedLife | boolean |
aura | boolean |
autoDispel | boolean |
Returns: boolean
Defined in: handles/unit.ts:715
#
hasItemhasItem(whichItem: Item): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
Returns: boolean
Defined in: handles/unit.ts:719
#
hideAbilityhideAbility(abilId: number, flag: boolean): void
#
Parameters:Name | Type |
---|---|
abilId | number |
flag | boolean |
Returns: void
Defined in: handles/unit.ts:723
#
inForceinForce(whichForce: Force): boolean
#
Parameters:Name | Type |
---|---|
whichForce | Force |
Returns: boolean
Defined in: handles/unit.ts:741
#
inGroupinGroup(whichGroup: Group): boolean
#
Parameters:Name | Type |
---|---|
whichGroup | Group |
Returns: boolean
Defined in: handles/unit.ts:745
#
inRangeinRange(x: number, y: number, distance: number): boolean
#
Parameters:Name | Type |
---|---|
x | number |
y | number |
distance | number |
Returns: boolean
Defined in: handles/unit.ts:749
#
inRangeOfPointinRangeOfPoint(whichPoint: Point, distance: number): boolean
#
Parameters:Name | Type |
---|---|
whichPoint | Point |
distance | number |
Returns: boolean
Defined in: handles/unit.ts:753
#
inRangeOfUnitinRangeOfUnit(otherUnit: Unit, distance: number): boolean
#
Parameters:Name | Type |
---|---|
otherUnit | Unit |
distance | number |
Returns: boolean
Defined in: handles/unit.ts:757
#
inTransportinTransport(whichTransport: Unit): boolean
#
Parameters:Name | Type |
---|---|
whichTransport | Unit |
Returns: boolean
Defined in: handles/unit.ts:765
#
incAbilityLevelincAbilityLevel(abilCode: number): number
Increases the level of a unit's ability by 1.
note
incAbilityLevel
can increase an abilities level to maxlevel+1. On maxlevel+1 all ability fields are 0.
http://www.wc3c.net/showthread.php?p=1029039#post1029039 http://www.hiveworkshop.com/forums/lab-715/silenceex-everything-you-dont-know-about-silence-274351/.
#
Parameters:Name | Type | Description |
---|---|---|
abilCode | number | The four digit rawcode representation of the ability. |
Returns: number
The new ability level.
Defined in: handles/unit.ts:737
#
interruptAttackinterruptAttack(): void
Returns: void
Defined in: handles/unit.ts:761
#
isAliveisAlive(): boolean
Returns: boolean
Defined in: handles/unit.ts:769
#
isAllyisAlly(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:773
#
isEnemyisEnemy(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:777
#
isExperienceSuspendedisExperienceSuspended(): boolean
Returns: boolean
Defined in: handles/unit.ts:781
#
isFoggedisFogged(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:785
#
isHeroisHero(): boolean
Returns: boolean
Defined in: handles/unit.ts:789
#
isIllusionisIllusion(): boolean
Returns: boolean
Defined in: handles/unit.ts:793
#
isLoadedisLoaded(): boolean
Returns: boolean
Defined in: handles/unit.ts:797
#
isMaskedisMasked(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:801
#
isSelectedisSelected(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:805
#
isUnitisUnit(whichSpecifiedUnit: Unit): boolean
note
Useless. Use operator == instead.
#
Parameters:Name | Type |
---|---|
whichSpecifiedUnit | Unit |
Returns: boolean
Defined in: handles/unit.ts:844
#
isUnitTypeisUnitType(whichUnitType: unittype): boolean
note
This native returns a boolean, which when typecasted to integer might be greater than 1. It's probably implemented via a bitset.
note
In past patches this native bugged when used in conditionfuncs.
The fix back then was to compare with true (==true
).
I cannot reproduce the faulty behaviour in patch 1.27 so this is only a note.
#
Parameters:Name | Type | Description |
---|---|---|
whichUnitType | unittype |
Returns: boolean
Defined in: handles/unit.ts:855
#
isVisibleisVisible(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/unit.ts:859
#
issueBuildOrderissueBuildOrder(unit: string | number, x: number, y: number): boolean
#
Parameters:Name | Type |
---|---|
unit | string | number |
x | number |
y | number |
Returns: boolean
Defined in: handles/unit.ts:809
#
issueImmediateOrderissueImmediateOrder(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
Returns: boolean
Defined in: handles/unit.ts:813
#
issueInstantOrderAtissueInstantOrderAt(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest, x: number, y: number, instantTargetWidget: Widget): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
x | number |
y | number |
instantTargetWidget | Widget |
Returns: boolean
Defined in: handles/unit.ts:817
#
issueInstantTargetOrderissueInstantTargetOrder(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest, targetWidget: Widget, instantTargetWidget: Widget): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
targetWidget | Widget |
instantTargetWidget | Widget |
Returns: boolean
Defined in: handles/unit.ts:823
#
issueOrderAtissueOrderAt(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest, x: number, y: number): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
x | number |
y | number |
Returns: boolean
Defined in: handles/unit.ts:829
#
issuePointOrderissuePointOrder(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest, whichPoint: Point): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
whichPoint | Point |
Returns: boolean
Defined in: handles/unit.ts:833
#
issueTargetOrderissueTargetOrder(order: string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest, targetWidget: Widget): boolean
#
Parameters:Name | Type |
---|---|
order | string | Absorb | Acidbomb | Acolyteharvest | Aimove | Ambush | Ancestralspirit | Ancestralspirittarget | Animatedead | Antimagicshell | Attack | Attackground | Attackonce | Attributemodskill | Auraunholy | Auravampiric | Autodispel | Autodispeloff | Autodispelon | Autoentangle | Autoentangleinstant | Autoharvestgold | Autoharvestlumber | Avatar | Avengerform | Awaken | Banish | Barkskin | Barkskinoff | Barkskinon | Battleroar | Bearform | Berserk | Blackarrow | Blackarrowoff | Blackarrowon | Blight | Blink | Blizzard | Bloodlust | Bloodlustoff | Bloodluston | Board | Breathoffire | Breathoffrost | Build | Burrow | Cancel | Cannibalize | Carrionscarabs | Carrionscarabsinstant | Carrionscarabsoff | Carrionscarabson | Carrionswarm | Chainlightning | Channel | Charm | Chemicalrage | Cloudoffog | Clusterrockets | Coldarrows | Coldarrowstarg | Controlmagic | Corporealform | Corrosivebreath | Coupleinstant | Coupletarget | Creepanimatedead | Creepdevour | Creepheal | Creephealoff | Creephealon | Creepthunderbolt | Creepthunderclap | Cripple | Curse | Curseoff | Curseon | Cyclone | Darkconversion | Darkportal | Darkritual | Darksummoning | Deathanddecay | Deathcoil | Deathpact | Decouple | Defend | Detectaoe | Detonate | Devour | Devourmagic | Disassociate | Disenchant | Dismount | Dispel | Divineshield | Doom | Drain | Dreadlordinferno | Dropitem | Drunkenhaze | Earthquake | Eattree | Elementalfury | Ensnare | Ensnareoff | Ensnareon | Entangle | Entangleinstant | Entanglingroots | Etherealform | Evileye | Faeriefire | Faeriefireoff | Faeriefireon | Fanofknives | Farsight | Fingerofdeath | Firebolt | Flamestrike | Flamingarrows | Flamingarrowstarg | Flamingattack | Flamingattacktarg | Flare | Forceboard | Forceofnature | Freezingbreath | Frenzy | Frenzyoff | Frenzyon | Frostarmor | Frostarmoroff | Frostarmoron | Frostnova | Getitem | Gold2lumber | Grabtree | Harvest | Heal | Healingspray | Healingward | Healingwave | Healoff | Healon | Hex | Holdposition | Holybolt | Howlofterror | Humanbuild | Immolation | Impale | Incineratearrow | Incineratearrowoff | Incineratearrowon | Inferno | Innerfire | Innerfireoff | Innerfireon | Instant | Instant1 | Instant2 | Instant3 | Instant4 | Invisibility | Lavamonster | Lightningshield | Load | Loadarcher | Loadcorpse | Loadcorpseinstant | Locustswarm | Lumber2gold | Magicdefense | Magicleash | Magicundefense | Manaburn | Manaflareoff | Manaflareon | Manashieldoff | Manashieldon | Massteleport | Mechanicalcritter | Metamorphosis | Militia | Militiaconvert | Militiaoff | Militiaunconvert | Mindrot | Mirrorimage | Monsoon | Mount | Mounthippogryph | Move | Moveslot1 | Moveslot2 | Moveslot3 | Moveslot4 | Moveslot5 | Moveslot6 | Nagabuild | Neutraldetectaoe | Neutralinteract | Neutralspell | Nightelfbuild | Orcbuild | Parasite | Parasiteoff | Parasiteon | Patrol | Phaseshift | Phaseshiftinstant | Phaseshiftoff | Phaseshifton | Phoenixfire | Phoenixmorph | Poisonarrows | Poisonarrowstarg | Polymorph | Possession | Preservation | Purge | Rainofchaos | Rainoffire | Raisedead | Raisedeadoff | Raisedeadon | Ravenform | Recharge | Rechargeoff | Rechargeon | Rejuvination | Renew | Renewoff | Renewon | Repair | Repairoff | Repairon | Replenish | Replenishlife | Replenishlifeoff | Replenishlifeon | Replenishmana | Replenishmanaoff | Replenishmanaon | Replenishoff | Replenishon | Request_hero | Requestsacrifice | Restoration | Restorationoff | Restorationon | Resumebuild | Resumeharvesting | Resurrection | Returnresources | Revenge | Revive | Roar | Robogoblin | Root | Sacrifice | Sanctuary | Scout | Scrollofspeed | Selfdestruct | Selfdestructoff | Selfdestructon | Sentinel | Setrally | Shadowsight | Shadowstrike | Shockwave | Silence | Skillmenu | Sleep | Slow | Slowoff | Slowon | Smart | Soulburn | Soulpreservation | Spellshield | Spellshieldaoe | Spellsteal | Spellstealoff | Spellstealon | Spies | Spiritlink | Spiritofvengeance | Spirittroll | Spiritwolf | Stampede | Standdown | Starfall | Stasistrap | Steal | Stomp | Stoneform | Stop | Stunned | Submerge | Summonfactory | Summongrizzly | Summonphoenix | Summonquillbeast | Summonwareagle | Tankdroppilot | Tankloadpilot | Tankpilot | Taunt | Thunderbolt | Thunderclap | Tornado | Townbelloff | Townbellon | Tranquility | Transmute | Unavatar | Unavengerform | Unbearform | Unburrow | Uncoldarrows | Uncorporealform | Undeadbuild | Undefend | Undivineshield | Unetherealform | Unflamingarrows | Unflamingattack | Unholyfrenzy | Unimmolation | Unload | Unloadall | Unloadallcorpses | Unloadallinstant | Unpoisonarrows | Unravenform | Unrobogoblin | Unroot | Unstableconcoction | Unstoneform | Unsubmerge | Unsummon | Unwindwalk | Useslot1 | Useslot2 | Useslot3 | Useslot4 | Useslot5 | Useslot6 | Vengeance | Vengeanceinstant | Vengeanceoff | Vengeanceon | Volcano | Voodoo | Ward | Waterelemental | Wateryminion | Web | Weboff | Webon | Whirlwind | Windwalk | Wispharvest |
targetWidget | Widget |
Returns: boolean
Defined in: handles/unit.ts:837
#
killkill(): void
Kills the unit.
Returns: void
Defined in: handles/unit.ts:866
#
lookAtlookAt(whichBone: string, lookAtTarget: Unit, offsetX: number, offsetY: number, offsetZ: number): void
Locks a unit's bone to face the target until ResetUnitLookAt is called.
The offset coordinates ( X, Y, Z ) are taken from the target's origin. The bones will lock to the lookAtTarget, offset by those coordinates. You can't have both the head and the chest locked to the target at the same time.
note
The parameter whichBone
can only move the head bones and the chest bones.
All other input will default to the head bone. However, the function only looks
for the helper named "Bone_Head"
(or "Bone_Chest"
) in the MDL, so you can just
rename a helper so that it will move that set of bones instead.
note
SetUnitLookAt is affected by animation speed and blend time.
note
How to instantly set a unit's facing
#
Parameters:Name | Type | Description |
---|---|---|
whichBone | string | The bone to lock onto the target. The engine only supports locking the head and the chest. To lock the head, you can put in any input except a null string. To lock the chest, the string must start with "bone_chest" . All leading spaces are ignored, it is case insensitive, and anything after the first non-leading space will be ignored. |
lookAtTarget | Unit | - |
offsetX | number | The x-offset from lookAtTarget's origin point. |
offsetY | number | The y-offset from lookAtTarget's origin point. |
offsetZ | number | The z-offset from lookAtTarget's origin point (this already factors in the terrain Z). |
Returns: void
Defined in: handles/unit.ts:892
#
makeAbilityPermanentmakeAbilityPermanent(permanent: boolean, abilityId: number): void
This native is used to keep abilities when morphing units
#
Parameters:Name | Type |
---|---|
permanent | boolean |
abilityId | number |
Returns: void
Defined in: handles/unit.ts:899
#
modifySkillPointsmodifySkillPoints(skillPointDelta: number): boolean
#
Parameters:Name | Type |
---|---|
skillPointDelta | number |
Returns: boolean
Defined in: handles/unit.ts:903
#
pauseExpauseEx(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:907
#
pauseTimedLifepauseTimedLife(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:911
#
queueAnimationqueueAnimation(whichAnimation: string): void
#
Parameters:Name | Type |
---|---|
whichAnimation | string |
Returns: void
Defined in: handles/unit.ts:915
#
recycleGuardPositionrecycleGuardPosition(): void
Returns: void
Defined in: handles/unit.ts:919
#
removeAbilityremoveAbility(abilityId: number): boolean
#
Parameters:Name | Type |
---|---|
abilityId | number |
Returns: boolean
Defined in: handles/unit.ts:923
#
removeBuffsremoveBuffs(removePositive: boolean, removeNegative: boolean): void
#
Parameters:Name | Type |
---|---|
removePositive | boolean |
removeNegative | boolean |
Returns: void
Defined in: handles/unit.ts:927
#
removeBuffsExremoveBuffsEx(removePositive: boolean, removeNegative: boolean, magic: boolean, physical: boolean, timedLife: boolean, aura: boolean, autoDispel: boolean): void
#
Parameters:Name | Type |
---|---|
removePositive | boolean |
removeNegative | boolean |
magic | boolean |
physical | boolean |
timedLife | boolean |
aura | boolean |
autoDispel | boolean |
Returns: void
Defined in: handles/unit.ts:931
#
removeGuardPositionremoveGuardPosition(): void
Returns: void
Defined in: handles/unit.ts:935
#
removeItemremoveItem(whichItem: Item): void
The item is removed from the Hero and placed on the ground at the Hero's feet.
#
Parameters:Name | Type | Description |
---|---|---|
whichItem | Item | The item to remove. |
Returns: void
Defined in: handles/unit.ts:943
#
removeItemFromSlotremoveItemFromSlot(itemSlot: number): Item
If an item exists in the given slot, it is removed from the Hero and placed on the ground at the Hero's feed
#
Parameters:Name | Type | Description |
---|---|---|
itemSlot | number |
Returns: Item
Defined in: handles/unit.ts:952
#
removeItemFromStockremoveItemFromStock(itemId: number): void
#
Parameters:Name | Type |
---|---|
itemId | number |
Returns: void
Defined in: handles/unit.ts:956
#
removeTyperemoveType(whichUnitType: unittype): boolean
#
Parameters:Name | Type |
---|---|
whichUnitType | unittype |
Returns: boolean
Defined in: handles/unit.ts:960
#
removeUnitFromStockremoveUnitFromStock(itemId: number): void
#
Parameters:Name | Type |
---|---|
itemId | number |
Returns: void
Defined in: handles/unit.ts:964
#
resetCooldownresetCooldown(): void
Returns: void
Defined in: handles/unit.ts:968
#
resetLookAtresetLookAt(): void
Unlocks the bone oriented by lookAt
, allowing it to move in accordance to the unit's regular animations.
Returns: void
Defined in: handles/unit.ts:975
#
reviverevive(x: number, y: number, doEyecandy: boolean): boolean
#
Parameters:Name | Type |
---|---|
x | number |
y | number |
doEyecandy | boolean |
Returns: boolean
Defined in: handles/unit.ts:979
#
reviveAtPointreviveAtPoint(whichPoint: Point, doEyecandy: boolean): boolean
#
Parameters:Name | Type |
---|---|
whichPoint | Point |
doEyecandy | boolean |
Returns: boolean
Defined in: handles/unit.ts:983
#
selectselect(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:987
#
selectSkillselectSkill(abilCode: number): void
#
Parameters:Name | Type |
---|---|
abilCode | number |
Returns: void
Defined in: handles/unit.ts:991
#
setAbilityCooldownsetAbilityCooldown(abilId: number, level: number, cooldown: number): void
#
Parameters:Name | Type |
---|---|
abilId | number |
level | number |
cooldown | number |
Returns: void
Defined in: handles/unit.ts:995
#
setAbilityLevelsetAbilityLevel(abilCode: number, level: number): number
#
Parameters:Name | Type |
---|---|
abilCode | number |
level | number |
Returns: number
Defined in: handles/unit.ts:999
#
setAbilityManaCostsetAbilityManaCost(abilId: number, level: number, manaCost: number): void
#
Parameters:Name | Type |
---|---|
abilId | number |
level | number |
manaCost | number |
Returns: void
Defined in: handles/unit.ts:1003
#
setAgilitysetAgility(value: number, permanent: boolean): void
#
Parameters:Name | Type |
---|---|
value | number |
permanent | boolean |
Returns: void
Defined in: handles/unit.ts:1007
#
setAnimationsetAnimation(whichAnimation: string | number): void
#
Parameters:Name | Type |
---|---|
whichAnimation | string | number |
Returns: void
Defined in: handles/unit.ts:1011
#
setAnimationWithRaritysetAnimationWithRarity(whichAnimation: string, rarity: raritycontrol): void
#
Parameters:Name | Type |
---|---|
whichAnimation | string |
rarity | raritycontrol |
Returns: void
Defined in: handles/unit.ts:1019
#
setAttackCooldownsetAttackCooldown(cooldown: number, weaponIndex: number): void
#
Parameters:Name | Type |
---|---|
cooldown | number |
weaponIndex | number |
Returns: void
Defined in: handles/unit.ts:1023
#
setBaseDamagesetBaseDamage(baseDamage: number, weaponIndex: number): void
#
Parameters:Name | Type |
---|---|
baseDamage | number |
weaponIndex | number |
Returns: void
Defined in: handles/unit.ts:1027
#
setBlendTimesetBlendTime(timeScale: number): void
#
Parameters:Name | Type |
---|---|
timeScale | number |
Returns: void
Defined in: handles/unit.ts:1031
#
setConstructionProgresssetConstructionProgress(constructionPercentage: number): void
#
Parameters:Name | Type |
---|---|
constructionPercentage | number |
Returns: void
Defined in: handles/unit.ts:1035
#
setCreepGuardsetCreepGuard(creepGuard: boolean): void
#
Parameters:Name | Type |
---|---|
creepGuard | boolean |
Returns: void
Defined in: handles/unit.ts:1039
#
setDiceNumbersetDiceNumber(diceNumber: number, weaponIndex: number): void
#
Parameters:Name | Type |
---|---|
diceNumber | number |
weaponIndex | number |
Returns: void
Defined in: handles/unit.ts:1043
#
setDiceSidessetDiceSides(diceSides: number, weaponIndex: number): void
#
Parameters:Name | Type |
---|---|
diceSides | number |
weaponIndex | number |
Returns: void
Defined in: handles/unit.ts:1047
#
setExperiencesetExperience(newXpVal: number, showEyeCandy: boolean): void
#
Parameters:Name | Type |
---|---|
newXpVal | number |
showEyeCandy | boolean |
Returns: void
Defined in: handles/unit.ts:1051
#
setExplodedsetExploded(exploded: boolean): void
#
Parameters:Name | Type |
---|---|
exploded | boolean |
Returns: void
Defined in: handles/unit.ts:1055
#
setFacingExsetFacingEx(facingAngle: number): void
#
Parameters:Name | Type |
---|---|
facingAngle | number |
Returns: void
Defined in: handles/unit.ts:1059
#
setFieldsetField(field: unitbooleanfield | unitintegerfield | unitrealfield | unitstringfield, value: string | number | boolean): boolean
#
Parameters:Name | Type |
---|---|
field | unitbooleanfield | unitintegerfield | unitrealfield | unitstringfield |
value | string | number | boolean |
Returns: boolean
Defined in: handles/unit.ts:1063
#
setHeroLevelsetHeroLevel(level: number, showEyeCandy: boolean): void
#
Parameters:Name | Type |
---|---|
level | number |
showEyeCandy | boolean |
Returns: void
Defined in: handles/unit.ts:1083
#
setIntelligencesetIntelligence(value: number, permanent: boolean): void
#
Parameters:Name | Type |
---|---|
value | number |
permanent | boolean |
Returns: void
Defined in: handles/unit.ts:1087
#
setItemTypeSlotssetItemTypeSlots(slots: number): void
#
Parameters:Name | Type |
---|---|
slots | number |
Returns: void
Defined in: handles/unit.ts:1091
#
setOwnersetOwner(whichPlayer: MapPlayer, changeColor: boolean): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
changeColor | boolean |
Returns: void
Defined in: handles/unit.ts:1095
#
setPathingsetPathing(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:1099
#
setPositionsetPosition(x: number, y: number): void
note
This cancels the orders of the unit. If you want to move a unit without canceling its orders set x
/y
.
#
Parameters:Name | Type |
---|---|
x | number |
y | number |
Returns: void
Defined in: handles/unit.ts:1106
#
setRescuablesetRescuable(byWhichPlayer: MapPlayer, flag: boolean): void
#
Parameters:Name | Type |
---|---|
byWhichPlayer | MapPlayer |
flag | boolean |
Returns: void
Defined in: handles/unit.ts:1110
#
setRescueRangesetRescueRange(range: number): void
#
Parameters:Name | Type |
---|---|
range | number |
Returns: void
Defined in: handles/unit.ts:1114
#
setScalesetScale(scaleX: number, scaleY: number, scaleZ: number): void
bug
Only takes scaleX into account and uses scaleX for all three dimensions.
#
Parameters:Name | Type | Description |
---|---|---|
scaleX | number | This is actually the scale for all dimensions |
scaleY | number | This parameter is not taken into account |
scaleZ | number | This parameter is not taken into account |
Returns: void
Defined in: handles/unit.ts:1124
#
setStatesetState(whichUnitState: unitstate, newVal: number): void
#
Parameters:Name | Type |
---|---|
whichUnitState | unitstate |
newVal | number |
Returns: void
Defined in: handles/unit.ts:1128
#
setStrengthsetStrength(value: number, permanent: boolean): void
#
Parameters:Name | Type |
---|---|
value | number |
permanent | boolean |
Returns: void
Defined in: handles/unit.ts:1132
#
setTimeScalesetTimeScale(timeScale: number): void
#
Parameters:Name | Type |
---|---|
timeScale | number |
Returns: void
Defined in: handles/unit.ts:1136
#
setUnitAttackCooldownsetUnitAttackCooldown(cooldown: number, weaponIndex: number): void
#
Parameters:Name | Type |
---|---|
cooldown | number |
weaponIndex | number |
Returns: void
Defined in: handles/unit.ts:1140
#
setUnitTypeSlotssetUnitTypeSlots(slots: number): void
#
Parameters:Name | Type |
---|---|
slots | number |
Returns: void
Defined in: handles/unit.ts:1144
#
setUpgradeProgresssetUpgradeProgress(upgradePercentage: number): void
#
Parameters:Name | Type |
---|---|
upgradePercentage | number |
Returns: void
Defined in: handles/unit.ts:1148
#
setUseAltIconsetUseAltIcon(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:1152
#
setUseFoodsetUseFood(useFood: boolean): void
#
Parameters:Name | Type |
---|---|
useFood | boolean |
Returns: void
Defined in: handles/unit.ts:1156
#
setVertexColorsetVertexColor(red: number, green: number, blue: number, alpha: number): void
Sets the unit's color to the color defined by (red,green,blue,alpha).
#
Parameters:Name | Type | Description |
---|---|---|
red | number | An integer from 0-255 determining the amount of red color. |
green | number | An integer from 0-255 determining the amount of green color. |
blue | number | An integer from 0-255 determining the amount of blue color. |
alpha | number | An integer from 0-255 determining the amount of alpha color. |
Returns: void
Defined in: handles/unit.ts:1167
#
setflyHeightsetflyHeight(value: number, rate: number): void
#
Parameters:Name | Type |
---|---|
value | number |
rate | number |
Returns: void
Defined in: handles/unit.ts:1079
#
shareVisionshareVision(whichPlayer: MapPlayer, share: boolean): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
share | boolean |
Returns: void
Defined in: handles/unit.ts:1171
#
showTeamGlowshowTeamGlow(show: boolean): void
#
Parameters:Name | Type |
---|---|
show | boolean |
Returns: void
Defined in: handles/unit.ts:1175
#
startAbilityCooldownstartAbilityCooldown(abilCode: number, cooldown: number): void
#
Parameters:Name | Type |
---|---|
abilCode | number |
cooldown | number |
Returns: void
Defined in: handles/unit.ts:1179
#
stripLevelsstripLevels(howManyLevels: number): boolean
#
Parameters:Name | Type |
---|---|
howManyLevels | number |
Returns: boolean
Defined in: handles/unit.ts:1183
#
suspendDecaysuspendDecay(suspend: boolean): void
#
Parameters:Name | Type |
---|---|
suspend | boolean |
Returns: void
Defined in: handles/unit.ts:1187
#
suspendExperiencesuspendExperience(flag: boolean): void
#
Parameters:Name | Type |
---|---|
flag | boolean |
Returns: void
Defined in: handles/unit.ts:1191
#
useItemuseItem(whichItem: Item): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
Returns: boolean
Defined in: handles/unit.ts:1195
#
useItemAtuseItemAt(whichItem: Item, x: number, y: number): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
x | number |
y | number |
Returns: boolean
Defined in: handles/unit.ts:1199
#
useItemTargetuseItemTarget(whichItem: Item, target: Widget): boolean
#
Parameters:Name | Type |
---|---|
whichItem | Item |
target | Widget |
Returns: boolean
Defined in: handles/unit.ts:1203
#
wakeUpwakeUp(): void
Returns: void
Defined in: handles/unit.ts:1207
#
waygateGetDestinationXwaygateGetDestinationX(): number
Returns: number
Defined in: handles/unit.ts:1211
#
waygateGetDestinationYwaygateGetDestinationY(): number
Returns: number
Defined in: handles/unit.ts:1215
#
waygateSetDestinationwaygateSetDestination(x: number, y: number): void
#
Parameters:Name | Type |
---|---|
x | number |
y | number |
Returns: void
Defined in: handles/unit.ts:1219
#
foodMadeByTypestatic foodMadeByType(unitId: number): number
#
Parameters:Name | Type |
---|---|
unitId | number |
Returns: number
Defined in: handles/unit.ts:1223
#
foodUsedByTypestatic foodUsedByType(unitId: number): number
#
Parameters:Name | Type |
---|---|
unitId | number |
Returns: number
Defined in: handles/unit.ts:1227
#
fromEnumstatic fromEnum(): Unit
Returns: Unit
Defined in: handles/unit.ts:1231
#
fromEventstatic fromEvent(): Unit
Returns: Unit
Overrides: Widget
Defined in: handles/unit.ts:1235
#
fromFilterstatic fromFilter(): Unit
Returns: Unit
Defined in: handles/unit.ts:1239
#
fromHandlestatic fromHandle(handle: unit): Unit
#
Parameters:Name | Type |
---|---|
handle | unit |
Returns: Unit
Overrides: Widget
Defined in: handles/unit.ts:1243
#
getPointValueByTypestatic getPointValueByType(unitType: number): number
#
Parameters:Name | Type |
---|---|
unitType | number |
Returns: number
Defined in: handles/unit.ts:1247
#
isUnitIdHerostatic isUnitIdHero(unitId: number): boolean
#
Parameters:Name | Type |
---|---|
unitId | number |
Returns: boolean
Defined in: handles/unit.ts:1251
#
isUnitIdTypestatic isUnitIdType(unitId: number, whichUnitType: unittype): boolean
#
Parameters:Name | Type |
---|---|
unitId | number |
whichUnitType | unittype |
Returns: boolean
Defined in: handles/unit.ts:1255