• 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.

[General] Is there a better way to do this?

Status
Not open for further replies.
Level 14
Joined
Oct 18, 2013
Messages
710
In my map, I am creating a "Spell Power" system. What I mean is that certain items increase how much damage your abilities inflict. The map is multiplayer. Each player will only control one hero. Dealing with just the items aspect of this system, when a hero uses an item the map needs to know which player used the item, so I used this trigger for each player in the game:

If ((Owner of TempUnit[1]) Equal to Player 1 (Red)) then do (Set SpellPower[1] = 3.00) else do (Do nothing)

Do I need to do this for each player in the game? Is there a shorter way around this? Many thanks! :grin:
 
Level 14
Joined
Oct 18, 2013
Messages
710
@icemanbo: good call, xD
@chaosy : how would I do it so that I can do that and have it still work for just the player whose hero used the item? I definitely don't want it so that when one hero uses the item all heroes get the bonus.
 
Level 14
Joined
Oct 18, 2013
Messages
710
The base spell power is one :eek: Well anyways, I think I will go with IceManbo's method, looks pretty straightforward and simple. Thanks to both of you for your help!
 
Status
Not open for further replies.
Top