• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

Bag dummy = First Hero =P

Status
Not open for further replies.
Level 12
Joined
Oct 28, 2019
Messages
480
I´ve created 3 heroes 1 based on tyrande, other in archmage other in montain king. And a Bag dummy (hero).

The "archmage hero" appears in first position (F1) instead the other in second (F2) How fix this?. Other question, theres a easy way to set one of atributes to zero (ex agility to zero) ?
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,583
If you didn't create them through triggers then it would probably be the order that you placed them on the map. It's most likely that the first hero you place will be the first icon to display.

A trigger example:
  • Actions:
  • Unit - Create 1 Archmage
  • Unit - Create 1 Mountain King
  • Unit - Create 1 Paladin
The Archmage is first, MK second, and Paladin third.

Edit:
About hero attributes.

Hold shift in the Object Editor to set an Attribute to 0. Shift allows you to modify fields beyond their regular limits. Also, make sure that in your World Editor preferences (File/Preferences/General) you check off "Allow negative real values...". This allows you to use negative values in the Object Editor using the Shift method. For example, you can modify Devotion Aura so that it gives -Armor using this method. Change it's Target's Allowed to Enemies and you'll have yourself a negative armor aura.
 
Last edited:
Level 12
Joined
Oct 28, 2019
Messages
480
If you didn't create them through triggers then it would probably be the order that you placed them on the map. It's most likely that the first hero you place will be the first icon to display.

A trigger example:
  • Actions:
  • Unit - Create 1 Archmage
  • Unit - Create 1 Mountain King
  • Unit - Create 1 Paladin
The Archmage is first, MK second, and Paladin third.

Edit:
About hero attributes.

Hold shift in the Object Editor to set an Attribute to 0. Shift allows you to modify fields beyond their regular limits. Also, make sure in your World Editor preferences (File/Preferences/General) you check off "Enable negative real values...". This allows you to use negative values in the Object Editor using the Shift method. For example, you can modify Devotion Aura so that it gives -Armor using this method. Change it's Target's Allowed to Enemies and you'll have yourself a negative armor aura.


ok I will try. TY. About the negative values I really didnt know about it really cool
 
Level 12
Joined
Oct 28, 2019
Messages
480
If you didn't create them through triggers then it would probably be the order that you placed them on the map. It's most likely that the first hero you place will be the first icon to display.

A trigger example:
  • Actions:
  • Unit - Create 1 Archmage
  • Unit - Create 1 Mountain King
  • Unit - Create 1 Paladin
The Archmage is first, MK second, and Paladin third.

Edit:
About hero attributes.

Hold shift in the Object Editor to set an Attribute to 0. Shift allows you to modify fields beyond their regular limits. Also, make sure that in your World Editor preferences (File/Preferences/General) you check off "Allow negative real values...". This allows you to use negative values in the Object Editor using the Shift method. For example, you can modify Devotion Aura so that it gives -Armor using this method. Change it's Target's Allowed to Enemies and you'll have yourself a negative armor aura.


Only last question, and An iten gives +3 all stasts, but a hero with 0 strenght cant gain strenght how can i do this
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,583
It's possible but you need a system that takes into consideration every single item that adds Strength.

For example:
  • Acquire Belt
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Belt of Giant Strength +6
      • (Unit-type of (Triggering unit)) Equal to Paladin
    • Actions
      • Item - For Item: (Item being manipulated), Remove Ability: Item Hero Stat Bonus (+6 Strength)
  • Lose Belt
    • Events
      • Unit - A unit Loses an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Belt of Giant Strength +6
      • (Unit-type of (Triggering unit)) Equal to Paladin
    • Actions
      • Item - For Item: (Item being manipulated), Add Ability: Item Hero Stat Bonus (+6 Strength)
Whenever the Paladin acquires a Belt of Giant Strength +6 it loses it's Strength bonus. Whenever he loses the item it gains it's ability back. This way you can trade the item between heroes without any issues.

Here's a system I made to make this work for multiple Items and to get around an annoying bug/issue with +All Stats. I attached a map as well (patch 1.32):
  • Item Strength Setup
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- HOW TO USE: --------
      • -------- You must remove any +Stat (Str/Agi/Int) abilities from your Items in the Object Editor. --------
      • -------- These Items then need to be added to this Setup trigger. --------
      • -------- IMPORTANT - In the Variable Editor (Control + B) make sure the Initial Value of Str_Abilities_No is set to ACID BOMB. --------
      • -------- If you changed the name of this ability that's fine you still need to do this. --------
      • -------- --------
      • -------- Set this to the total number of Item-Types that you've added below: --------
      • Set VariableSet Str_Total_Items = 3
      • -------- --------
      • -------- Set this to the Hero that can't gain Strength: --------
      • Set VariableSet Str_Hero = Paladin
      • -------- --------
      • -------- First Item: --------
      • Set VariableSet Str_Items[1] = Gauntlets of Ogre Strength +3
      • Set VariableSet Str_Abilities[1] = Item Hero Stat Bonus (+3 Strength)
      • -------- --------
      • -------- Second Item: --------
      • Set VariableSet Str_Items[2] = Belt of Giant Strength +6
      • Set VariableSet Str_Abilities[2] = Item Hero Stat Bonus (+6 Strength)
      • -------- --------
      • -------- Third Item: --------
      • -------- For Items like the Crown of Kings that add +5 All Stats you'll need an additional variable and a new ability. --------
      • -------- Str_Abilities is added to standard Heroes, and Str_Abilities_No is added to our NO-Strength Hero: --------
      • Set VariableSet Str_Items[3] = Crown of Kings +5
      • Set VariableSet Str_Abilities[3] = Item Hero Stat Bonus (+5 All Stats)
      • Set VariableSet Str_Abilities_No[3] = Item Hero Stat Bonus (+5 Agi / Int)
      • -------- --------
      • -------- Fourth Item: (etc) --------
You'll see that for the Crown of Kings item I created a new ability called Item Hero Stat Bonus (+5 Agi / Int). This ability is based on Item Hero Stat Bonus (+5 All Stats) but with the Strength value set to 0.

Here are the triggers that actually add/remove the Item abilities.
  • Acquire Strength Item
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • For each (Integer Str_Loop) from 1 to Str_Total_Items, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Item-type of (Item being manipulated)) Equal to Str_Items[Str_Loop]
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Unit-type of (Triggering unit)) Equal to Str_Hero
                • Then - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • Str_Abilities_No[Str_Loop] Not equal to Acid Bomb
                    • Then - Actions
                      • Item - For Item: (Item being manipulated), Add Ability: Str_Abilities_No[Str_Loop]
                    • Else - Actions
                • Else - Actions
                  • Item - For Item: (Item being manipulated), Add Ability: Str_Abilities[Str_Loop]
            • Else - Actions
  • Lose Strength Item
    • Events
      • Unit - A unit Loses an item
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • For each (Integer Str_Loop) from 1 to Str_Total_Items, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Item-type of (Item being manipulated)) Equal to Str_Items[Str_Loop]
            • Then - Actions
              • Item - For Item: (Item being manipulated), Remove Ability: Str_Abilities[Str_Loop]
              • Item - For Item: (Item being manipulated), Remove Ability: Str_Abilities_No[Str_Loop]
            • Else - Actions

If you have more than 1 Hero-type that cannot gain Strength then you'll need to modify the triggers slightly. It's a very simple fix, instead of using the Str_Hero variable, you delete it and edit the conditions in the Acquire Strength Item trigger:
OR - Multiple Conditions:
(Unit-type of (Triggering unit)) Equal to Hero1
(Unit-type of (Triggering unit)) Equal to Hero2
(Unit-type of (Triggering unit)) Equal to Hero3
etc...
 

Attachments

  • No Strength 1.w3m
    19.4 KB · Views: 9
Last edited:
Status
Not open for further replies.
Top