Tengo un problema con estos detonadores
se supone que esta habilidad debe llegar a todo el mapa pero ya hize eso pero el problema es que la unidad Bala R ; al volver a usar la habilidad ya no aparece pero el resto funciona bien alguien me puede explicar que esta mal
Casteo:
[GUI]
CanonCasteo
Acontecimientos
Unidad - A unit Comienza a lanzar una habilidad
Condiciones
Acciones
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Si: Condiciones
(Ability being cast) Igual a Gran Cañon
Entonces: Acciones
Set Canon_Caster = (Casting unit)
Set Canon_PuntoPiked = (Target point of ability being cast)
Unidad - Create 1 Bala R for (Owner of Canon_Caster) at (Position of Canon_Caster) facing Vista edificio predeterminada degrees
Set Canon_Bala = (Last created unit)
Unidad - Create 1 Punto_Caster[Unidad] for Jugador 1 (rojo) at (Position of Canon_Caster) facing Vista edificio predeterminada degrees
Set Canon_Bala_punto = (Last created unit)
Set Canon_Punto_Caster = (Position of Canon_Bala_punto)
Detonador - Turn on CanoMovimiento
Detonador - Turn off (This trigger)
Otros: Acciones
[/GUI]
Avanzar la bala
[GUI]
CanoMovimiento
Acontecimientos
Tiempo - Every 0.05 seconds of game time
Condiciones
Acciones
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Si: Condiciones
Canon_Tiempo Menor que o igual a 30
Entonces: Acciones
Unidad - Move Canon_Bala instantly to (Canon_Punto_Caster offset by (Real(Canon_Avanze)) towards (Angle from Canon_Punto_Caster to Canon_PuntoPiked) degrees), facing (Angle from Canon_Punto_Caster to Canon_PuntoPiked) degrees
Grupo de unidad - Pick every unit in (Units within 120.00 of (Position of Canon_Bala) matching (((Matching unit) belongs to an enemy of (Owner of Canon_Bala)) Igual a True)) and do (Actions)
Bucle: Acciones
Unidad - Cause Canon_Caster to damage (Picked unit), dealing ((20.00 + (Real(Canon_Dano))) + 0.00) damage of attack type HÃ
roe and damage type Normal
Set Canon_Avanze = (Canon_Avanze + 70)
Set Canon_Var = (Canon_Var + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Si: Condiciones
Canon_Var Igual a 20
Entonces: Acciones
Set Canon_Dano = (Canon_Dano + (50 x (Level of Gran Cañon for Canon_Caster)))
Set Canon_Var = 0
Set Canon_Tiempo = (Canon_Tiempo + 1)
Otros: Acciones
Otros: Acciones
Detonador - Turn on CanonCasteo
Detonador - Turn on Canon Destruir
Detonador - Turn off (This trigger)
[/GUI]
Y Eleiminar todas la variables:
[GUI]
Canon Destruir
Acontecimientos
Tiempo - Every 0.05 seconds of game time
Condiciones
Acciones
Unidad - Remove Canon_Bala from the game
Unidad - Remove Canon_Bala_punto from the game
Set Canon_Tiempo = 0
Set Canon_Var = 0
Set Canon_Caster = Ninguna unidad
Set Canon_Bala = Ninguna unidad
Set Canon_Bala_punto = Ninguna unidad
Custom script: call RemoveLocation(udg_Canon_PuntoPiked)
Custom script: call RemoveLocation(udg_Canon_Punto_Caster)
Detonador - Turn off (This trigger)
[/GUI]