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

Modify Hero stats

Status
Not open for further replies.
Level 9
Joined
Apr 28, 2009
Messages
538
Can anybody tell me a simple way to make a unit/building that has 6 buttons:

1 - Aglt +1
2 - Aglt -1
3 - Stgt +1
4 - Stgt -1
5 - Intg +1
6 - Intg -1

and when the player clicks one of the buttons, a hero's stats are being modified ?

EDIT: i forget to mention that i've tried a trigger like this one, but it won't work for some reason:
  • AgUP
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to (==) (MY_ABILITY)
    • Actions
      • Hero - Modify ABILITY of MY_HERO <gen>: Add MY_VALUE
 
Level 4
Joined
Apr 18, 2009
Messages
127
For the building you should use dummy units that you "buy" then kill. And create a trigger that looks something like this:

  • H
    • Events
      • Unit - A unit Finishes training a unit
    • Conditions
      • (Unit-type of (Last created unit)) Equal to AGILITYUNIT
      • ((Buying unit) is A Hero) Equal to True
    • Actions
      • Hero - Modify Agility of (Buying unit): Add 10
EDIT: Oh i c your trigger now. I believe my trigger is more specific, when it comes to "Buying unit" etc. Anyway I might be terribly wrong
 
Level 4
Joined
Dec 15, 2007
Messages
96
You could use a building, and make it sell items like "+ Agility" and "- Agility", etc.
Use the normal Tome effects, you know "Tome of Agility", and just rename it. To get it to remove 1 agility, you can change on the "Item Agility Gain" ability to do -1 agility bonus, instead of +1. (For negative values, hold down Shift botton while dubble clicking, or pressing Enter)
 
Status
Not open for further replies.
Top