Lua API — Types
Value Classes (Opaque IDs)
These are inline value wrappers that provide type-safety for numeric IDs.
| Class |
Value Type |
Description |
CombatAnalyzerQueryID |
Int |
|
CustomGameEventListenerID |
Int |
|
EntityIndex |
Int |
|
EventListenerID |
Int |
|
ParticleID |
Int |
|
PlayerID |
Int |
|
ProjectileID |
Int |
|
SpawnGroupHandle |
Int |
|
ViewerID |
Int |
|
Type Aliases
| Alias |
Target |
Description |
Quaternion |
Any |
There is no known way to create values of this type. |
Vector2D |
Any |
There is no known way to create values of this type. |
Data Types
LocalTime
| Field |
Type |
Description |
Minutes |
Int |
|
Seconds |
Int |
|
Hours |
Int |
|
CScriptHTTPResponse
| Field |
Type |
Description |
Body |
String |
|
Request |
CScriptHTTPRequest |
|
StatusCode |
UInt |
|
ApplyDamageOptions
| Field |
Type |
Description |
victim |
BaseNPC |
|
attacker |
BaseNPC |
|
damage |
Float |
|
damage_type |
DamageTypes |
|
damage_flags |
DOTADamageFlag? |
|
ability |
BaseAbility? |
|
CreateIllusionsModifierKeys
| Field |
Type |
Description |
outgoing_damage |
Float? |
|
incoming_damage |
Float? |
|
bounty_base |
Float? |
|
bounty_growth |
Float? |
|
outgoing_damage_structure |
Float? |
|
outgoing_damage_roshan |
Float? |
|
EntityBounds
| Field |
Type |
Description |
Mins |
Vector |
|
Maxs |
Vector |
|
CombatAnalyzerQueryResult
| Field |
Type |
Description |
query_id |
CombatAnalyzerQueryID |
|
ExecuteOrderOptions
| Field |
Type |
Description |
UnitIndex |
EntityIndex |
|
OrderType |
Dotaunitorder |
|
TargetIndex |
EntityIndex? |
|
AbilityIndex |
EntityIndex? |
|
Position |
Vector? |
|
Queue |
Boolean? |
|
| Field |
Type |
Description |
startpos |
Vector |
|
endpos |
Vector |
|
ent |
CBaseEntity |
|
mins |
Any? |
|
maxs |
Any? |
|
TraceCollideableOutputs
| Field |
Type |
Description |
hit |
Boolean |
|
pos |
Vector |
|
normal |
Vector |
|
fraction |
Float |
|
| Field |
Type |
Description |
startpos |
Vector |
|
endpos |
Vector |
|
min |
Any |
|
max |
Any |
|
mask |
Any? |
|
ignore |
Any? |
|
TraceHullOutputs
| Field |
Type |
Description |
hit |
Boolean |
|
startsolid |
Boolean |
|
pos |
Vector |
|
normal |
Vector |
|
fraction |
Float |
|
enthit |
CBaseEntity? |
|
| Field |
Type |
Description |
startpos |
Vector |
|
endpos |
Vector |
|
mask |
Any? |
|
ignore |
Any? |
|
TraceLineOutputs
| Field |
Type |
Description |
hit |
Boolean |
|
startsolid |
Boolean |
|
pos |
Vector |
|
normal |
Vector |
|
fraction |
Float |
|
enthit |
CBaseEntity? |
|
CreateBaseProjectileOptions
| Field |
Type |
Description |
EffectName |
String? |
|
Ability |
BaseAbility? |
|
Source |
BaseNPC? |
|
bProvidesVision |
Boolean? |
|
iVisionRadius |
UInt? |
|
iVisionTeamNumber |
DOTATeam? |
|
ExtraData |
Any? |
|
CreateLinearProjectileOptions
| Field |
Type |
Description |
vSpawnOrigin |
Vector? |
|
vVelocity |
Vector? |
|
vAcceleration |
Vector? |
|
fMaxSpeed |
Float? |
|
fDistance |
Float? |
|
fStartRadius |
Float? |
|
fEndRadius |
Float? |
|
fExpireTime |
Float? |
|
iUnitTargetTeam |
DotaUnitTargetTeam? |
|
iUnitTargetFlags |
DotaUnitTargetFlags? |
|
iUnitTargetType |
DotaUnitTargetType? |
|
bIgnoreSource |
Boolean? |
|
bHasFrontalCone |
Boolean? |
|
bDrawsOnMinimap |
Boolean? |
|
bVisibleToEnemies |
Boolean? |
|
CreateTrackingProjectileOptions
| Field |
Type |
Description |
vSourceLoc |
Vector? |
|
Target |
BaseNPC? |
|
iMoveSpeed |
Int? |
|
flExpireTime |
Float? |
|
bDodgeable |
Boolean? |
|
bIsAttack |
Boolean? |
|
bReplaceExisting |
Boolean? |
|
bIgnoreObstructions |
Boolean? |
|
bSuppressTargetCheck |
Boolean? |
|
iSourceAttachment |
DOTAProjectileAttachment? |
|
bDrawsOnMinimap |
Boolean? |
|
bVisibleToEnemies |
Boolean? |
|
AbilityTuningValueFilterEvent
| Field |
Type |
Description |
entindex_caster_const |
EntityIndex |
|
entindex_ability_const |
EntityIndex |
|
value_name_const |
String |
|
value |
Int |
|
BountyRunePickupFilterEvent
| Field |
Type |
Description |
player_id_const |
PlayerID |
|
xp_bounty |
Int |
|
gold_bounty |
Int |
|
DamageFilterEvent
| Field |
Type |
Description |
entindex_attacker_const |
EntityIndex |
|
entindex_victim_const |
EntityIndex |
|
entindex_inflictor_const |
EntityIndex? |
|
damagetype_const |
DamageTypes |
|
damage |
Float |
|
ExecuteOrderFilterEvent
| Field |
Type |
Description |
units |
Map<String |
|
entindex_target |
EntityIndex |
|
entindex_ability |
EntityIndex |
|
issuer_player_id_const |
PlayerID |
|
sequence_number_const |
UInt |
|
queue |
Int |
|
order_type |
Dotaunitorder |
|
position_x |
Float |
|
position_y |
Float |
|
position_z |
Float |
|
shop_item_name |
String |
|
HealingFilterEvent
| Field |
Type |
Description |
entindex_target_const |
EntityIndex |
|
entindex_inflictor_const |
EntityIndex? |
|
entindex_healer_const |
EntityIndex? |
|
heal |
Int |
|
ItemAddedToInventoryFilterEvent
| Field |
Type |
Description |
inventory_parent_entindex_const |
EntityIndex |
|
item_parent_entindex_const |
EntityIndex |
|
item_entindex_const |
EntityIndex |
|
suggested_slot |
Int |
|
ModifierGainedFilterEvent
| Field |
Type |
Description |
entindex_caster_const |
EntityIndex |
|
entindex_parent_const |
EntityIndex |
|
entindex_ability_const |
EntityIndex |
|
name_const |
String |
|
duration |
Int |
|
ModifyExperienceFilterEvent
| Field |
Type |
Description |
hero_entindex_const |
EntityIndex |
|
player_id_const |
PlayerID |
|
reason_const |
ModifyXPReason |
|
experience |
Int |
|
ModifyGoldFilterEvent
| Field |
Type |
Description |
player_id_const |
PlayerID |
|
reason_const |
ModifyGoldReason |
|
reliable |
Int |
|
gold |
UInt |
|
RuneSpawnFilterEvent
| Field |
Type |
Description |
spawner_entindex_const |
EntityIndex |
|
rune_type |
DotaRunes |
|
TrackingProjectileFilterEvent
| Field |
Type |
Description |
entindex_source_const |
EntityIndex |
|
entindex_target_const |
EntityIndex |
|
entindex_ability_const |
EntityIndex |
|
is_attack |
Int |
|
dodgeable |
Int |
|
max_impact_time |
Int |
|
move_speed |
Int |
|
expire_time |
Int |
|
ModifierAttackEvent
| Field |
Type |
Description |
attacker |
BaseNPC |
|
damage |
Float |
|
damage_type |
DamageTypes |
|
damage_category |
DamageCategory |
|
damage_flags |
DOTADamageFlag |
|
inflictor |
BaseAbility? |
|
original_damage |
Float |
|
ranged_attack |
Boolean |
|
target |
BaseNPC |
|
no_attack_cooldown |
Boolean |
|
record |
Int |
|
fail_type |
Attackfail |
|
report_max |
Boolean? |
|
ModifierInstanceEvent
| Field |
Type |
Description |
attacker |
BaseNPC |
|
damage |
Float |
|
damage_type |
DamageTypes |
|
damage_category |
DamageCategory |
|
damage_flags |
DOTADamageFlag |
|
inflictor |
BaseAbility? |
|
original_damage |
Float |
|
ranged_attack |
Boolean |
|
unit |
BaseNPC |
|
no_attack_cooldown |
Boolean |
|
record |
Int |
|
fail_type |
Attackfail |
|
ModifierUnitEvent
| Field |
Type |
Description |
new_pos |
Vector |
|
order_type |
Dotaunitorder |
|
unit |
BaseNPC |
|
ModifierAbilityEvent
| Field |
Type |
Description |
ability |
BaseAbility |
|
target |
BaseNPC? |
|
ModifierOverrideAbilitySpecialEvent
| Field |
Type |
Description |
ability |
BaseAbility |
|
ability_special_value |
String |
|
ability_special_level |
Int |
|
ModifierAddedEvent
| Field |
Type |
Description |
unit |
BaseNPC |
|
added_buff |
Buff |
|
ModifierHealEvent
| Field |
Type |
Description |
gain |
Int |
|
SpawnEntityFromTableOptions
| Field |
Type |
Description |
origin |
String? |
|
angles |
String? |
|
scales |
String? |
|
targetname |
String? |
|
vscripts |
String? |
|
CreateUnitFromTableOptions
| Field |
Type |
Description |
MapUnitName |
String |
|
teamnumber |
DOTATeam? |
|
modelscale |
Int? |
|
initial_waypoint |
String? |
|
EnableAutoStyles |
String? |
|
rendercolor |
String? |
|
skin |
Int? |
|
NeverMoveToClearSpace |
Boolean? |
|