Trigger API Reference DCEI Functions Effect0 - BLKTower/TestWiki GitHub Wiki
Trigger API Reference\DCEI Functions\Effect {Trigger-API-ReferenceDCEI-FunctionsEffect}
string GetEffectType(string effectName)
Returns the effect type of an effect as a string.
local effect_type = DCEI.GetEffectType("DoNothing")
DCEI.LogMessage(effect_type)
void CreateEffect(string effectName, unit target)
Creates an effect targeting a unit. There is no source or caster unit.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local test_subject = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffect("Kill", test_subject)
void CreateEffectAtUnit(string effectName, unit target) {void-CreateEffectAtUnitstring-effectName-unit-target}
void CreateEffectAtUnit(string effectName, unit target)
Creates an effect targeting a unit. There is no source or caster unit.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local test_subject = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffectAtUnit("Kill", test_subject)
void CreateEffect(string effectName, unit caster, unit source, unit target) {void-CreateEffectstring-effectName-unit-caster-unit-source-unit-target}
void CreateEffect(string effectName, unit caster, unit source, unit target)
Create an effect targeting a unit via a source unit as if cast by another unit.
-
string
effectName
the name of the effect to create. -
unit
caster
the unit that is considered to be the caster of the effect. -
unit
source
the unit to treat as the effect source. -
unit
target
the unit to target with the effect.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local caster = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
local source = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
local target = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffect("Kill", caster, source, target)
void CreateEffectAtUnit(string effectName, unit target, unit caster, unit source) {void-CreateEffectAtUnitstring-effectName-unit-target-unit-caster-unit-source}
void CreateEffectAtUnit(string effectName, unit target, unit caster, unit source)
Create an effect targeting a unit via a source unit as if cast by another unit.
-
string
effectName
the name of the effect to create. -
unit
caster
the unit that is considered to be the caster of the effect. -
unit
source
the unit to treat as the effect source. -
unit
target
the unit to target with the effect.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local caster = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
local source = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
local target = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffectAtUnit("Kill", caster, source, target)
void CreateEffect(string effectName, unit caster, float x, float z) {void-CreateEffectstring-effectName-unit-caster-float-x-float-z}
void CreateEffect(string effectName, unit caster, float x, float z)
Creates an effect from a unit targeting a point.
-
string
effectName
the name of the effect to create. -
unit
caster
the unit that is considered to be the caster of the effect. -
float
x
the x-axis coordinate to cast the ability at. -
float
z
the z-axis coordinate to cast the ability at.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local test_subject = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffect("Kill", test_subject)
void CreateEffectAtPosition(string effectName, unit caster, float x, float z) {void-CreateEffectAtPositionstring-effectName-unit-caster-float-x-float-z}
void CreateEffectAtPosition(string effectName, unit caster, float x, float z)
Creates an effect from a unit targeting a point.
-
string
effectName
the name of the effect to create. -
unit
caster
the unit that is considered to be the caster of the effect. -
float
x
the x-axis coordinate to cast the ability at. -
float
z
the z-axis coordinate to cast the ability at.
local team_id = 1
local player_id = 1
local unit_type = "Standard MeleeUnit"
local x, y = 16, 16
local test_subject = DCEI.CreateUnitAsync(team_id, player_id, unit_type, x, y)
DCEI.CreateEffectAtPosition("Kill", test_subject)