~~My dummies won't work~~Need assistance please~~

turok255

New Member
Reaction score
30
Okay i've gotten help from most of you kenny,tom,ect. and followed your instructions exactly and my spells that use dummies NEVER work!

So heres my trigger, If you doin't see anything wrong with it please make an test a trigger that summons a dummy unit..

Code:
Ice Clone
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Ice Clone 
    Actions
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Unit Group - Pick every unit in IceClone_UnitGroup and do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Picked unit) belongs to an enemy of (Owner of IceClone_Caster)) Equal to True
                    Then - Actions
                        Unit - Create 1 Dummy for (Owner of IceClone_Caster) at IceClone_CasterPosition facing IceClone_CasterPosition
                        Unit - Add Storm Bolt Summoned unit to (Last created unit)
                        Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
                        Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Picked unit)
                        Animation - Play IceClone_Caster's stand animation
                        Custom script:   call RemoveLocation(udg_IceClone_CasterPosition)
                        Custom script:   call DestroyGroup(udg_IceClone_UnitGroup)
                    Else - Actions

PS:im not sure if it even creates the dummy unit....

Things i've tried
  • Casting range is 9999
  • Spell costs no mana
  • Spell is a unit ability
  • Dummy can cats it if i place him maunaly in map
  • Targets allowed are, Air, Ground, Debris, Enemy, Nuteral, Organic
  • Making picked units all units in area
  • Custom script outside loop
  • adding a 0.03 wait action
  • Changing variabe order
  • Using triggering unit
 

Steel

Software Engineer
Reaction score
109
Make sure your dummy spell costs no mana (or your caster has mana), make sure the dummy spell has a lot of range, make sure the dummy spell can target the appropriate units, make sure the dummy spell has 0 second cast time.

To test it you should put debug message through it and see what happens. You should also create a dummy unit for yourself and try and cast the spell manually.
 

turok255

New Member
Reaction score
30
Make sure your dummy spell costs no mana (or your caster has mana), make sure the dummy spell has a lot of range, make sure the dummy spell can target the appropriate units, make sure the dummy spell has 0 second cast time.

To test it you should put debug message through it and see what happens. You should also create a dummy unit for yourself and try and cast the spell manually.

debug?

whats that
 
I

IKilledKEnny

Guest
Okay i've gotten help from most of you kenny,tom,ect. and followed your instructions exactly and my spells that use dummies NEVER work!

So heres my trigger, If you doin't see anything wrong with it please make an test a trigger that summons a dummy unit..

Code:
Ice Clone
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Ice Clone 
    Actions
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Unit Group - Pick every unit in IceClone_UnitGroup and do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Picked unit) belongs to an enemy of (Owner of IceClone_Caster)) Equal to True
                    Then - Actions
                        Unit - Create 1 Dummy for (Owner of IceClone_Caster) at IceClone_CasterPosition facing IceClone_CasterPosition
                        Unit - Add Storm Bolt Summoned unit to (Last created unit)
                        Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
                        Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Picked unit)
                        Animation - Play IceClone_Caster's stand animation
                        Custom script:   call RemoveLocation(udg_IceClone_CasterPosition)
                        Custom script:   call DestroyGroup(udg_IceClone_UnitGroup)
                    Else - Actions

PS:im not sure if it even creates the dummy unit....

I found 3 problems. 1. you need to destroy the group outside the loop, it's very important. 2. You didn't define IceClone_Caster. 3. You didn't define IceClone_CasterPosition.

Also Master told me once that somtimes you need to wait a little before unit can cast spell, ut I doubt if that the problem here. Did you make sure the dummy got mana and the ability has no cooldown? Also 2 secs expiration timer should be good.
 

phyrex1an

Staff Member and irregular helper
Reaction score
447
Code:
Ice Clone
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Ice Clone 
    Actions
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Unit Group - Pick every unit in IceClone_UnitGroup and do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Picked unit) belongs to an enemy of (Owner of IceClone_Caster)) Equal to True
                    Then - Actions
                        [B]Unit - Create 1 Dummy for (Owner of IceClone_Caster) at IceClone_CasterPosition facing IceClone_CasterPosition[/B]
                        Unit - Add Storm Bolt Summoned unit to (Last created unit)
                        Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
                        Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Picked unit)
                        Animation - Play IceClone_Caster's stand animation
                        [B]Custom script:   call RemoveLocation(udg_IceClone_CasterPosition)
                        Custom script:   call DestroyGroup(udg_IceClone_UnitGroup)[/B]
                    Else - Actions

First Bold: Where do you set IceClone_CasterPosition? btw, facing angle 0 works better there :)

Second Bold: Since you never set IceClone_CasterPosition you shouldn't destroy it, with that code the first dummy unit will be created at whatever IceClone_CasterPosition is when the code runs, all other dummies will be created at the center of the map

Third Bold: That should be after the loop and not inside it.

>debug?
Usually adding in game text messages to make sure that the code runs as supposed, or to see in what part the error is.
 

turok255

New Member
Reaction score
30
Okay i did all that and heres the status of the trigger.

1)It creates the unit...but somtimes it won't create the unit... and it will create 2 next time casted.
2)The created units don't cast the spell.... but i can maunaly (Took locust off to test)
3)Heres the new trigger.

Code:
Ice Clone
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Ice Clone 
    Actions
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Set IceClone_Caster = (Casting unit)
        Set IceClone_CasterPosition = (Position of (Casting unit))
        Unit Group - Pick every unit in IceClone_UnitGroup and do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Picked unit) belongs to an enemy of (Owner of IceClone_Caster)) Equal to True
                    Then - Actions
                        Unit - Create 1 Dummy for (Owner of IceClone_Caster) at IceClone_CasterPosition facing IceClone_CasterPosition
                        Unit - Add Storm Bolt Summoned unit to (Last created unit)
                        Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
                        Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Picked unit)
                        Animation - Play IceClone_Caster's stand animation
                    Else - Actions
        Custom script:   call DestroyGroup(udg_IceClone_UnitGroup)

PS:How the heck did you get disabled rep??

EDIT:added wait still didn't cast..
 

Tom Jones

N/A
Reaction score
437
Your using your location before you set it.
Code:
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Set IceClone_Caster = (Casting unit)
        Set IceClone_CasterPosition = (Position of (Casting unit))
should be
Code:
        Set IceClone_CasterPosition = (Position of (Casting unit))       
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Set IceClone_Caster = (Casting unit)
Just a piece of advice, if your able to use triggering unit, then do it. It's faster and more reliable.
 

turok255

New Member
Reaction score
30
Okay tom, thanks for the advice :)

I changed the order of variables...:D

But the unit STILL won't cast the ability :( ...my trigger amkes him.. then he starts attacking and dosen't cast the ability :nuts:
 

turok255

New Member
Reaction score
30
Well.... i dunno how i could of messed it up so i'll attach my map could you have a look at it please.

Ability is storm bolt Summoned unit
(Summoned unit is a editor suffix)
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
lol ayu downloaded it hehehe <3

[edit]
yo turok, after testing out your spell, i found out the problem
it was the wait 0.03 seconds, if you remove it, everything will work perfectly
below is the code
Code:
Ice Clone
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Ice Clone 
    Actions
        Set IceClone_CasterPosition = (Position of (Casting unit))
        Set IceClone_UnitGroup = (Units within 500.00 of IceClone_CasterPosition)
        Set IceClone_Caster = (Casting unit)
        Unit Group - Pick every unit in IceClone_UnitGroup and do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Picked unit) belongs to an enemy of (Owner of IceClone_Caster)) Equal to True
                    Then - Actions
[COLOR="Red"]                        Unit - Create 1 Dummy for (Owner of IceClone_Caster) at IceClone_CasterPosition facing IceClone_CasterPosition[/COLOR]
                        Unit - Add Storm Bolt Summoned unit to (Last created unit)
                        Unit - Set level of Storm Bolt Summoned unit for (Last created unit) to ((Level of Ice Clone  for IceClone_Caster) + 0)
                        [COLOR="Red"]Unit - Add a 1.00 second Generic expiration timer to (Last created unit)[/COLOR]
                        [COLOR="Red"]Wait 0.03 seconds [B]<<< remove![/B][/COLOR]
                        Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Picked unit)
                        Animation - Play IceClone_Caster's stand animation
                    Else - Actions
        Custom script:   call DestroyGroup(udg_IceClone_UnitGroup)
       [COLOR="Red"] Custom script:   call RemoveLocation(udg_IceClone_CasterPosition)[/COLOR]

btw, the expiration timer you don't need to have it 10 seconds, 1 second is good
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
hi turok <3

remember to add |r at the end of the statement/paragraph to get your loading screen text to have color
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top