• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Need help at triggering spells!

Status
Not open for further replies.
Level 11
Joined
Jul 20, 2004
Messages
2,760
oh, being cast by multiple casters from the same player at the same time. I wasn't sure but had a feeling that this would be the problem. IMO there may be a possibility even with triggers by making a huge array (as big as possible) and giving each casting unit a place into that array. I guess you can do this by yourself so it's just an idea. You can then reset the array after the array number is high enough cuz mostly probably the units with lower numbers didn't start casting the spell yet and so only extremely abusive players could cause a problem (and even so... it's mostly improbable). Hope it helps you.
 
Level 6
Joined
Sep 9, 2004
Messages
152
Hmm maybe i got an idea with an array.Look at this!
Code:
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Electric Storm 
    Actions
        Set catsers = (Last created unit group)
        Add (Casting unit) to catsers
        .............................
        The actions for the spell
        .............................
        
And here all aray variables use the Number of units in casters.What do you think?
 
Level 11
Joined
Jul 20, 2004
Messages
2,760
First, why would you set the Last created unit group value to the catsers? And, how are you actually going to detect them into the unit group? I was trying to suggest a Unit variable with array checked and number of units in the array very very high (8192 is maximum). Still, after a while you'll have to reset them and... getting the number into the array requires another variable and so... pretty not worky if i'm thinking aobut now. But if you think the stuff you made works... Congratulations!
 
Level 9
Joined
Jun 10, 2004
Messages
594
Before I started using JASS, I used a system of arrays and unit groups. Several of my maps use this, but I forget which ones. If you ask, I'll e-mail you one of my best implementations of this system.

However, it is easiest just to use JASS.

~The_Raven
 
Status
Not open for further replies.
Top