Dota 2 Workshop Tools/Scripting/API/CDOTA BaseNPC.CastAbilityOnTarget: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Dota_Lebot push: Updated Page)
Line 13: Line 13:


== Parameters ==
== Parameters ==
{| class="standard-table" style="width: 50%;"
{| class="standard-table" style="width: 100%;"
! Type
! Type
! Name
! Name
! Description
! Description
! Example
|-
|-
| handle
| handle
| target
| target
| No Description Set
| The target to this ability is to be casted on
| target
|-
|-
| handle
| handle
| ability
| ability
| No Description Set
| The ability on the unit to be cast on the target
| keys.caster:FindAbilityByName("mana_burn")
|-
|-
| int
| int
| playerIndex
| playerIndex
| No Description Set
| The casting units player ID
| keys.caster:GetOwner():GetPlayerID()
|}
|}

Revision as of 09:22, 17 August 2014

Note.pngNote: This page is automatically generated. Any changes may be overwritten

Function Description

void CastAbilityOnTarget(handle target, handle ability, int playerIndex)

Cast an ability on a target entity.


Parameters

Type Name Description Example
handle target The target to this ability is to be casted on target
handle ability The ability on the unit to be cast on the target keys.caster:FindAbilityByName("mana_burn")
int playerIndex The casting units player ID keys.caster:GetOwner():GetPlayerID()