[Trigger]Spell Problem

Status
Not open for further replies.

Airandius

Level 17
I have a spell called enrage, and I want it to create 4 shockwaves outwards creating a +.
My spell however makes the dummy only cast it at facing of triggering unit + 0 degree, and goes lick fuck off to the 90, 180 and 270 degree casting.
How can I solve this?

Here is the trigger:

• Enrage
• Events
• Unit - A unit Starts the effect of an ability
• Conditions
• (Ability being cast) Equal to Enrage [E]
• Actions
• Set CasterPoint[(Player number of (Owner of (Triggering unit)))] = (Position of (Triggering unit))
• Floating Text - Create floating text that reads (PlayerColor[(Player number of (Owner of (Triggering unit)))] + ([Enrage - Rank + ((String((Level of Enrage [E] for (Triggering unit)))) + ]))) at CasterPoint[(Player number of (Owner of (Triggering unit)))] with Z offset 0.00, using font size 9.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
• Floating Text - Change (Last created floating text): Disable permanence
• Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
• Floating Text - Change the fading age of (Last created floating text) to 3.00 seconds
• Floating Text - Set the velocity of (Last created floating text) to 15.00 towards (Random real number between 50.00 and 90.00) degrees
• Set CastPoint[(Player number of (Owner of (Triggering unit)))] = (CasterPoint[(Player number of (Owner of (Triggering unit)))] offset by 200.00 towards ((Facing of (Triggering unit)) + 0.00) degrees)
• Set CastPoint2[(Player number of (Owner of (Triggering unit)))] = (CasterPoint[(Player number of (Owner of (Triggering unit)))] offset by 200.00 towards ((Facing of (Triggering unit)) + 90.00) degrees)
• Set CastPoint3[(Player number of (Owner of (Triggering unit)))] = (CasterPoint[(Player number of (Owner of (Triggering unit)))] offset by 200.00 towards ((Facing of (Triggering unit)) + 180.00) degrees)
• Set CastPoint4[(Player number of (Owner of (Triggering unit)))] = (CasterPoint[(Player number of (Owner of (Triggering unit)))] offset by 200.00 towards ((Facing of (Triggering unit)) + 270.00) degrees)
• Animation - Reset (Triggering unit)'s animation
• Animation - Play (Triggering unit)'s Stand Victory animation
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at CasterPoint[(Player number of (Owner of (Triggering unit)))] facing Default building facing degrees
• Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
• Unit - Add (D) Enrage to (Last created unit)
• Unit - Set level of (D) Enrage for (Last created unit) to (Level of Enrage [E] for (Triggering unit))
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave CastPoint[(Player number of (Owner of (Triggering unit)))]
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave CastPoint2[(Player number of (Owner of (Triggering unit)))]
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave CastPoint3[(Player number of (Owner of (Triggering unit)))]
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave CastPoint4[(Player number of (Owner of (Triggering unit)))]
• Custom script: set bj_wantDestroyGroup = true
• Custom script: call RemoveLocation(udg_CastPoint[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))])
• Custom script: call RemoveLocation(udg_CastPoint2[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))])
• Custom script: call RemoveLocation(udg_CastPoint3[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))])
• Custom script: call RemoveLocation(udg_CastPoint4[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))])
• Custom script: call RemoveLocation(udg_CasterPoint[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))])
EDIT: I don't want to hear, check if the spell for dummy has cooldown or mana cost blablabla, that's all fine.

bounty hunter2

Level 18
I think you must wait a bit, like 0.1 second before casting it in other directions, I'm not sure thou. Did you set the cooldown to 0? And manacost?

Level 5

Airandius

Level 17
I think you must wait a bit, like 0.1 second before casting it in other directions, I'm not sure thou. Did you set the cooldown to 0? And manacost?

EDIT: I don't want to hear, check if the spell for dummy has cooldown or mana cost blablabla, that's all fine.

I don't like waits, I want it to be MPI at least.

bounty hunter2

Level 18
Sorry didn't see the Edited part. Anyway you could maybe make a trigger for when the shockwave is cast first time:

unit begins the efect of abiliry
= shockwave
set a = a + 1 ( a is initialy 1 )
Set CastPoint[(Player number of (Owner of (Triggering unit)))] = (CasterPoint[(Player number of (Owner of (Triggering unit)))] offset by 200.00 towards ((Facing of (Triggering unit)) +a x 90) degrees)

Maybe this would work you just add exp. timer and all the other stuff.

Squiggy

Level 28
• For each Integer A from 1 to 4 do:
• Set Castpoint = (CasterPoint offset by 200.00 towards ((Facing of (Triggering unit)) + x) degrees)
• Unit - Create 1 dummy at Casterpoint for (Owner of (Tiggering Unit) facing x degrees
• Unit - Add a 3 seconds standard expirationtimer to (last created unit)
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave CastPoint
• Set x = (x + 90.00)
• Custom script: call Remove(udg_Castpoint)
• Set x = 0.00
Whereas x is a real whch is increased by 90 everytime the loop runs.
Plus, as I was told, you don't need Arrays for that

TheBlooddancer

Level 22
Its cause you can't make 4 last created units to cast.

Last = Last, and not the one before last reffered.

Just put the casting right after you spawn it, its still Mpi.

Status
Not open for further replies.

Replies
12
Views
718
Replies
5
Views
604
Replies
0
Views
476
[Trigger] Weapon Limit
Replies
8
Views
1K
[Trigger] Leaks?
Replies
5
Views
764