Добавлен , опубликован
// Base Field API
// Unit Base
native GetUnitBaseIntegerFieldById						takes integer unitTypeId, unitintegerfield whichField returns integer
native SetUnitBaseIntegerFieldById						takes integer unitTypeId, unitintegerfield whichField, integer value returns boolean

native GetUnitBaseBooleanFieldById						takes integer unitTypeId, unitbooleanfield whichField returns boolean
native SetUnitBaseBooleanFieldById						takes integer unitTypeId, unitbooleanfield whichField, boolean value returns boolean

native GetUnitBaseRealFieldById							takes integer unitTypeId, unitrealfield whichField returns real
native SetUnitBaseRealFieldById							takes integer unitTypeId, unitrealfield whichField, real value returns boolean

native GetUnitBaseStringFieldById						takes integer unitTypeId, unitstringfield whichField returns string
native SetUnitBaseStringFieldById						takes integer unitTypeId, unitstringfield whichField, string value returns boolean

// Unit Base Weapon
native GetUnitBaseWeaponIntegerFieldById				takes integer unitTypeId, unitweaponintegerfield whichField, integer index returns integer
native SetUnitBaseWeaponIntegerFieldById				takes integer unitTypeId, unitweaponintegerfield whichField, integer index, integer value returns boolean

native GetUnitBaseWeaponBooleanFieldById				takes integer unitTypeId, unitweaponbooleanfield whichField, integer index returns boolean
native SetUnitBaseWeaponBooleanFieldById				takes integer unitTypeId, unitweaponbooleanfield whichField, integer index, boolean value returns boolean

native GetUnitBaseWeaponRealFieldById					takes integer unitTypeId, unitweaponrealfield whichField, integer index returns real
native SetUnitBaseWeaponRealFieldById					takes integer unitTypeId, unitweaponrealfield whichField, integer index, real value returns boolean

native GetUnitBaseWeaponStringFieldById					takes integer unitTypeId, unitweaponstringfield whichField, integer index returns string
native SetUnitBaseWeaponStringFieldById					takes integer unitTypeId, unitweaponstringfield whichField, integer index, string value returns boolean
//

// Field API
// Unit 
native GetUnitIntegerField								takes unit whichUnit, unitintegerfield whichField returns integer
native SetUnitIntegerField								takes unit whichUnit, unitintegerfield whichField, integer value returns boolean

native GetUnitBooleanField								takes unit whichUnit, unitbooleanfield whichField returns boolean
native SetUnitBooleanField								takes unit whichUnit, unitbooleanfield whichField, boolean value returns boolean

native GetUnitRealField									takes unit whichUnit, unitrealfield whichField returns real
native SetUnitRealField									takes unit whichUnit, unitrealfield whichField, real value returns boolean

native GetUnitStringField								takes unit whichUnit, unitstringfield whichField returns string
native SetUnitStringField								takes unit whichUnit, unitstringfield whichField, string value returns boolean

// Unit Weapon
native GetUnitWeaponIntegerField						takes unit whichUnit, unitweaponintegerfield whichField, integer index returns integer
native SetUnitWeaponIntegerField						takes unit whichUnit, unitweaponintegerfield whichField, integer index, integer value returns boolean

native GetUnitWeaponBooleanField						takes unit whichUnit, unitweaponbooleanfield whichField, integer index returns boolean
native SetUnitWeaponBooleanField						takes unit whichUnit, unitweaponbooleanfield whichField, integer index, boolean value returns boolean

native GetUnitWeaponRealField							takes unit whichUnit, unitweaponrealfield whichField, integer index returns real
native SetUnitWeaponRealField							takes unit whichUnit, unitweaponrealfield whichField, integer index, real value returns boolean

native GetUnitWeaponStringField							takes unit whichUnit, unitweaponstringfield whichField, integer index returns string
native SetUnitWeaponStringField							takes unit whichUnit, unitweaponstringfield whichField, integer index, string value returns boolean
//

// Normal API
native SetUnitTypeId									takes unit whichUnit, integer newId returns nothing
native GetUnitLocustFlag								takes unit whichUnit returns integer
native GetUnitUnderCursor								takes nothing returns unit
native GetUnitSelectedCountByPlayer						takes player whichPlayer returns integer
native GetUnitSelected									takes player whichPlayer returns unit // Always returns Active unit, aka the "main" one whose UI is drawn.
native GetUnitInSelectionByIndex						takes player whichPlayer, integer index returns unit
native GetFirstUnitInSelection							takes player whichPlayer returns unit
native GetLastUnitInSelection							takes player whichPlayer returns unit
native IsUnitAlive										takes unit whichUnit returns boolean // checks unit flags
native IsUnitDead										takes unit whichUnit returns boolean // checks internal flag (not a part of unit flags)
native IsUnitMoving										takes unit whichUnit returns boolean
native IsUnitStunned									takes unit whichUnit returns boolean
native IsUnitInvulnerable								takes unit whichUnit returns boolean
native IsUnitHero										takes unit whichUnit returns boolean
native IsUnitTower										takes unit whichUnit returns boolean
native IsUnitShop										takes unit whichUnit returns boolean
native IsUnitInventoryEnabled							takes unit whichUnit returns boolean
native EnableUnitInventory								takes unit whichUnit, boolean enable returns nothing
native IsUnitInventoryEnabledEx							takes unit whichUnit returns boolean
native EnableUnitInventoryEx							takes unit whichUnit, boolean enable returns nothing
native IsUnitMovementEnabled							takes unit whichUnit returns boolean
native EnableUnitMovement								takes unit whichUnit, boolean enable returns nothing
native IsUnitMovementEnabledEx							takes unit whichUnit returns boolean
native EnableUnitMovementEx								takes unit whichUnit, boolean enable returns nothing
native IsUnitAttackEnabled								takes unit whichUnit returns boolean
native EnableUnitAttack									takes unit whichUnit, boolean enable returns nothing
native IsUnitAttackEnabledEx							takes unit whichUnit returns boolean
native EnableUnitAttackEx								takes unit whichUnit, boolean enable returns nothing
native IsUnitStateNormal								takes unit whichUnit, boolean additionalCheck returns boolean
native RedrawUnit										takes unit whichUnit returns nothing
native UpdateUnitInfoBar								takes unit whichUnit returns integer
native UnitUnapplyUpgrades								takes unit whichUnit returns integer
native UnitApplyUpgrades								takes unit whichUnit returns integer
native GetUnitAbility									takes unit whichUnit, integer aid returns ability
native GetUnitAbilityByIndex							takes unit whichUnit, integer index returns ability
native GetUnitBuff										takes unit whichUnit, integer buffId returns buff
native GetUnitBuffByIndex								takes unit whichUnit, integer index returns buff
native GetUnitBuffLevel									takes unit whichUnit, integer buffId returns integer
native UnitAddAbilityEx									takes unit whichUnit, integer abilityId, boolean checkForDuplicates returns boolean
native UnitRemoveAbilityEx								takes unit whichUnit, integer abilityId, boolean removeDuplicates returns boolean
native IsUnitAbilityVisible								takes unit whichUnit, integer abilityId returns boolean
native ShowUnitAbility									takes unit whichUnit, integer abilityId, boolean show returns nothing
native DisableUnitAbility								takes unit whichUnit, integer abilityId, boolean hide, boolean disable returns nothing
native EnableUnitAbility								takes unit whichUnit, integer abilityId, boolean show, boolean enable returns nothing
native IsUnitSelectable									takes unit whichUnit returns boolean
native SetUnitSelectable								takes unit whichUnit, boolean selectable returns nothing
native SetUnitControl									takes unit whichUnit, integer flagValue, boolean isSetFlagValue, boolean ismove, boolean isattack, boolean isinventory returns nothing // flagValue = 0x200 and isSetFlagValue = true to emulate pause 
native SetUnitLocustFlag								takes unit whichUnit, integer flag, integer mode returns nothing
native SetUnitTruesightImmuneState						takes unit whichUnit, boolean state returns nothing
native GetUnitZ											takes unit whichUnit returns real
native GetUnitDamageReduction							takes unit whichUnit returns real
native GetUnitMagicResistByType							takes unit whichUnit, integer resistType returns real
native GetUnitEluneMagicResist							takes unit whichUnit returns real
native GetUnitRunicMagicResist							takes unit whichUnit returns real 
native GetUnitTotalMagicResist							takes unit whichUnit returns real
native IsUnitGatherer									takes unit whichUnit returns boolean
native GetUnitCurrentResources							takes unit whichUnit returns integer
native GetUnitCurrentSight								takes unit whichUnit returns real
native SetUnitCurrentSight								takes unit whichUnit, real realValue returns nothing
native GetUnitAttackRemainingCooldown					takes unit whichUnit returns real
native SetUnitAttackRemainingCooldown					takes unit whichUnit, real time returns nothing
native GetUnitAttackRemainingDamagePoint				takes unit whichUnit returns real
native SetUnitAttackRemainingDamagePoint				takes unit whichUnit, real time returns nothing
native GetUnitAttackRemainingBackswing					takes unit whichUnit returns real
native SetUnitAttackRemainingBackswing					takes unit whichUnit, real time returns nothing
native UnitResetAttack									takes unit whichUnit returns boolean
native UnitFinishAttack									takes unit whichUnit returns boolean
native GetUnitAttackTypeByIndex							takes unit whichUnit, integer attackIndex returns attacktype
native SetUnitAttackTypeByIndex							takes unit whichUnit, integer attackIndex, attacktype whichAttackType returns nothing
native GetUnitWeaponTypeByIndex							takes unit whichUnit, integer attackIndex returns weapontype
native SetUnitWeaponTypeByIndex							takes unit whichUnit, integer attackIndex, weapontype whichWeaponType returns nothing
native GetUnitWeaponSoundByIndex						takes unit whichUnit, integer attackIndex returns integer
native SetUnitWeaponSoundByIndex						takes unit whichUnit, integer attackIndex, integer weaponSound returns nothing
native GetUnitBaseDamageByIndex							takes unit whichUnit, integer attackIndex returns integer
native SetUnitBaseDamageByIndex							takes unit whichUnit, integer attackIndex, integer damage returns nothing
native GetUnitBonusDamageByIndex						takes unit whichUnit, integer attackIndex returns integer
native SetUnitBonusDamageByIndex						takes unit whichUnit, integer attackIndex, integer bonusDamage returns nothing
native GetUnitDamageDicesSideByIndex					takes unit whichUnit, integer attackIndex returns integer
native SetUnitDamageDicesSideByIndex					takes unit whichUnit, integer attackIndex, integer dicesSides returns nothing
native GetUnitDamageDicesByIndex						takes unit whichUnit, integer attackIndex returns integer
native SetUnitDamageDicesByIndex						takes unit whichUnit, integer attackIndex, integer dices returns nothing
native GetUnitMinimumDamageByIndex						takes unit whichUnit, integer attackIndex returns integer
native GetUnitMaximumDamageByIndex						takes unit whichUnit, integer attackIndex returns integer
native GetUnitAttackRangeByIndex						takes unit whichUnit, integer attackIndex returns real
native SetUnitAttackRangeByIndex						takes unit whichUnit, integer attackIndex, real range returns nothing
native GetUnitAttackSpeed								takes unit whichUnit returns real
native SetUnitAttackSpeed								takes unit whichUnit, real attackSpeed returns nothing
native GetUnitAttackCooldownByIndex						takes unit whichUnit, integer attackIndex returns real
native SetUnitAttackCooldownByIndex						takes unit whichUnit, integer attackIndex, real attackCooldown returns nothing
native GetUnitBackswingPointByIndex						takes unit whichUnit, integer attackIndex returns real
native SetUnitBackswingPointByIndex						takes unit whichUnit, integer attackIndex, real backswing returns nothing
native GetUnitDamagePointByIndex						takes unit whichUnit, integer attackIndex returns real
native SetUnitDamagePointByIndex						takes unit whichUnit, integer attackIndex, real damagePoint returns nothing
native GetUnitAttacksEnabledIndex						takes unit whichUnit returns integer
native GetUnitArmourType								takes unit whichUnit returns defensetype
native SetUnitArmourType								takes unit whichUnit, defensetype whichArmour returns nothing
native GetUnitArmour									takes unit whichUnit returns real
native SetUnitArmour									takes unit whichUnit, real armour returns nothing
native GetUnitTimeScale									takes unit whichUnit returns real
native GetUnitBaseMoveSpeed								takes unit whichUnit returns real
native SetUnitBaseMoveSpeed								takes unit whichUnit, real baseMoveSpeed returns nothing
native GetUnitTotalMoveSpeed							takes unit whichUnit returns real
native GetUnitBonusMoveSpeedPercent						takes unit whichUnit returns real
native SetUnitBonusMoveSpeedPercent						takes unit whichUnit, real bonusMoveSpeedPercent returns nothing
native GetUnitVertexColour								takes unit whichUnit returns integer
native GetUnitCurrentLife								takes unit whichUnit returns real
native SetUnitCurrentLife								takes unit whichUnit, real life returns nothing
native GetUnitMaxLife									takes unit whichUnit returns real
native SetUnitMaxLife									takes unit whichUnit, real maxLife returns nothing
native GetUnitLifeRegen									takes unit whichUnit returns real
native SetUnitLifeRegen									takes unit whichUnit, real lifeRegen returns nothing
native GetUnitCurrentMana								takes unit whichUnit returns real
native SetUnitCurrentMana								takes unit whichUnit, real mana returns nothing
native GetUnitMaxMana									takes unit whichUnit returns real
native SetUnitMaxMana									takes unit whichUnit, real maxMana returns nothing
native GetUnitManaRegen									takes unit whichUnit returns real
native SetUnitManaRegen									takes unit whichUnit, real manaRegen returns nothing
native GetUnitPrimaryStat								takes unit whichUnit returns heroattribute
native SetUnitPrimaryStat								takes unit whichUnit, heroattribute whichHeroAttribute returns nothing
native SetUnitModel										takes unit whichUnit, string modelName returns nothing
native SetUnitModelEx									takes unit whichUnit, string modelName, integer playercolourId returns nothing
native SetUnitMaterialTexture							takes unit whichUnit, string textureName, integer materialId, integer textureIndex returns nothing
native SetUnitTexture									takes unit whichUnit, string textureName, integer textureIndex returns nothing
native SetUnitReplaceableTexture						takes unit whichUnit, string textureName, integer textureIndex returns nothing
native GetUnitCollisionType								takes unit whichUnit returns collisiontype
native SetUnitCollisionType								takes unit whichUnit, collisiontype collisionType returns nothing
native GetUnitPathingAIType								takes unit whichUnit returns pathingaitype
native SetUnitPathingAIType								takes unit whichUnit, pathingaitype pathingAIType returns nothing
native GetUnitPathingType								takes unit whichUnit returns pathingtype
native SetUnitPathingType								takes unit whichUnit, pathingtype pathingType returns nothing
native GetUnitItemSlots									takes unit whichUnit returns integer
native SetUnitItemSlots									takes unit whichUnit, integer itemSlots returns nothing
native SetUnitFacingEx									takes unit whichUnit, real facing, boolean isInstant returns nothing
native SetUnitFacingInstant								takes unit whichUnit, real facing returns nothing
native GetUnitMinimapX									takes unit whichUnit returns real
native GetUnitMinimapY									takes unit whichUnit returns real
native GetUnitRallyPointX								takes unit whichUnit returns real
native GetUnitRallyPointY								takes unit whichUnit returns real
native GetHeroMaxLevelExperienceNeeded					takes unit whichUnit returns integer
native GetHeroExperienceNeeded							takes unit whichUnit, integer forLevel returns integer
native UnitApplySilence									takes unit whichUnit, boolean state returns nothing
native UnitDisableAbilities								takes unit whichUnit, boolean state returns nothing
native PauseUnitEx										takes unit whichUnit, boolean flag returns nothing // this is pretty much a copy of SetUnitStunned, added for compatibility.
native SetUnitStunned									takes unit whichUnit, boolean state returns nothing
native GetUnitStunCounter								takes unit whichUnit returns integer
native SetUnitStunCounter								takes unit whichUnit, integer stunCounter returns nothing
native SetUnitKiller									takes unit whichUnit, unit killer returns nothing
native KillUnitEx										takes unit whichUnit, unit killer returns nothing
native MorphUnitToTypeIdEx								takes unit whichUnit, integer uid, integer unitFlags, boolean updateHealthState, boolean updateManaState, integer healthStateId, integer manaStateId, boolean updateScale, boolean replaceAbilities, ability whichAbility, boolean resetBuildingAnimation returns nothing
native MorphUnitToTypeId								takes unit whichUnit, integer uid returns nothing
native GetUnitModelObjectPositionX						takes unit whichUnit, string whichObject returns real
native GetUnitModelObjectPositionY						takes unit whichUnit, string whichObject returns real
native GetUnitModelObjectPositionZ						takes unit whichUnit, string whichObject returns real
native GetUnitModelObjectPositionLoc					takes unit whichUnit, string whichObject returns location
native SetUnitAnimationOffsetPercent					takes unit whichUnit, real percent returns boolean
//

// Order API
native QueueImmediateOrderById							takes unit whichUnit, integer order returns boolean
native QueuePointOrderById								takes unit whichUnit, integer order, real x, real y returns boolean
native QueueTargetOrderById								takes unit whichUnit, integer order, widget targetWidget returns boolean
native QueueInstantPointOrderById						takes unit whichUnit, integer order, real x, real y, widget instantTargetWidget returns boolean
native QueueInstantTargetOrderById						takes unit whichUnit, integer order, widget targetWidget, widget instantTargetWidget returns boolean
native QueueBuildOrderById								takes unit whichPeon, integer unitId, real x, real y returns boolean
native QueueNeutralImmediateOrderById					takes player forWhichPlayer, unit neutralStructure, integer unitId returns boolean
native QueueNeutralPointOrderById						takes player forWhichPlayer, unit neutralStructure, integer unitId, real x, real y returns boolean
native QueueNeutralTargetOrderById						takes player forWhichPlayer, unit neutralStructure, integer unitId, widget target returns boolean
native GetUnitOrderCount								takes unit whichUnit returns integer
native GetUnitOrderIdByIndex							takes unit whichUnit, integer index returns integer
native UnitClearOrders									takes unit whichUnit, boolean onlyQueued returns nothing
native UnitForceStopOrder								takes unit whichUnit, boolean clearQueue returns nothing
//
//
`
ОЖИДАНИЕ РЕКЛАМЫ...
1
20
11 месяцев назад
1
Добавлено:
	native GetUnitCollisionType 							takes unit whichUnit returns collisiontype
	native SetUnitCollisionType 							takes unit whichUnit, collisiontype collisionType returns nothing
Удалено:
native SetUnitMoveTypeByIndex 							takes unit whichUnit, integer moveIndex returns nothing
0
19
11 месяцев назад
Отредактирован Таренас
0
SetUnitPortrait нету что-ли?
1
20
11 месяцев назад
1
SetUnitPortrait нету что-ли?
Через SetUnitStringField и UNIT_SF_PORTRAIT.
Чтобы оставить комментарий, пожалуйста, войдите на сайт.