• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Solved] Help with Tavern Heroes

Level 3
Joined
Dec 30, 2023
Messages
8
So, I added extra heroes to the tavern, and when a player buy those added heroes they'll stay there instead of being removed.
Could someone help me with this, please?
 
Level 39
Joined
Feb 27, 2007
Messages
5,031
Make sure their Stats - Stock... fields in the Object Editor mirror those values for other neutral heroes. (In order they are: 1, 1, 0, 135.) In Gameplay Constants also make sure those heroes are added to Techtree - Dependency Equivalents - Hero.
 
Level 3
Joined
Dec 30, 2023
Messages
8
Make sure their Stats - Stock... fields in the Object Editor mirror those values for other neutral heroes. (In order they are: 1, 1, 0, 135.) In Gameplay Constants also make sure those heroes are added to Techtree - Dependency Equivalents - Hero.
Thank you for the response!



I checked what you said:

1703947780661.png
(Default Neutral Hero)

1703947846868.png
(Added Neutral Hero)



Also:

I added them to the gameplay constants:

1703948341229.png

(The first four ones).




And then I checked during the game, and this happened:

1703948566036.png
:fp:
1703948604587.png

(The added heroes won't remove still). :c



Maybe am I missing something?
 
Last edited:
Level 3
Joined
Dec 30, 2023
Messages
8
I figured out how to make it work by using triggers for each player and each added hero:
  • Hero Limit
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Limit training of Archmage to 1 for Player 1 (Red)
          • Player - Limit training of Blademaster to 1 for Player 1 (Red)
          • Player - Limit training of Dreadlord to 1 for Player 1 (Red)
          • Player - Limit training of Keeper of the Grove to 1 for Player 1 (Red)
          • Player - Limit training of Archmage to 1 for Player 2 (Blue)
          • Player - Limit training of Blademaster to 1 for Player 2 (Blue)
          • Player - Limit training of Dreadlord to 1 for Player 2 (Blue)
          • Player - Limit training of Keeper of the Grove to 1 for Player 2 (Blue)
          • Player - Limit training of Archmage to 1 for Player 3 (Teal)
          • Player - Limit training of Blademaster to 1 for Player 3 (Teal)
          • Player - Limit training of Dreadlord to 1 for Player 3 (Teal)
          • Player - Limit training of Keeper of the Grove to 1 for Player 3 (Teal)
          • Player - Limit training of Archmage to 1 for Player 4 (Purple)
          • Player - Limit training of Blademaster to 1 for Player 4 (Purple)
          • Player - Limit training of Dreadlord to 1 for Player 4 (Purple)
          • Player - Limit training of Keeper of the Grove to 1 for Player 4 (Purple)
          • Player - Limit training of Archmage to 1 for Player 5 (Yellow)
          • Player - Limit training of Blademaster to 1 for Player 5 (Yellow)
          • Player - Limit training of Dreadlord to 1 for Player 5 (Yellow)
          • Player - Limit training of Keeper of the Grove to 1 for Player 5 (Yellow)
          • Player - Limit training of Archmage to 1 for Player 6 (Orange)
          • Player - Limit training of Blademaster to 1 for Player 6 (Orange)
          • Player - Limit training of Dreadlord to 1 for Player 6 (Orange)
          • Player - Limit training of Keeper of the Grove to 1 for Player 6 (Orange)
(I'm new at this). 🐤
 
Last edited:

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,583
I figured out how to make it work by using triggers for each player and each added hero:

  • Hero Limit
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Limit training of Archmage to 1 for Player 1 (Red)
          • Player - Limit training of Blademaster to 1 for Player 1 (Red)
          • Player - Limit training of Dreadlord to 1 for Player 1 (Red)
          • Player - Limit training of Keeper of the Grove to 1 for Player 1 (Red)
          • Player - Limit training of Archmage to 1 for Player 2 (Blue)
          • Player - Limit training of Blademaster to 1 for Player 2 (Blue)
          • Player - Limit training of Dreadlord to 1 for Player 2 (Blue)
          • Player - Limit training of Keeper of the Grove to 1 for Player 2 (Blue)
          • Player - Limit training of Archmage to 1 for Player 3 (Teal)
          • Player - Limit training of Blademaster to 1 for Player 3 (Teal)
          • Player - Limit training of Dreadlord to 1 for Player 3 (Teal)
          • Player - Limit training of Keeper of the Grove to 1 for Player 3 (Teal)
          • Player - Limit training of Archmage to 1 for Player 4 (Purple)
          • Player - Limit training of Blademaster to 1 for Player 4 (Purple)
          • Player - Limit training of Dreadlord to 1 for Player 4 (Purple)
          • Player - Limit training of Keeper of the Grove to 1 for Player 4 (Purple)
          • Player - Limit training of Archmage to 1 for Player 5 (Yellow)
          • Player - Limit training of Blademaster to 1 for Player 5 (Yellow)
          • Player - Limit training of Dreadlord to 1 for Player 5 (Yellow)
          • Player - Limit training of Keeper of the Grove to 1 for Player 5 (Yellow)
          • Player - Limit training of Archmage to 1 for Player 6 (Orange)
          • Player - Limit training of Blademaster to 1 for Player 6 (Orange)
          • Player - Limit training of Dreadlord to 1 for Player 6 (Orange)
          • Player - Limit training of Keeper of the Grove to 1 for Player 6 (Orange)
You should change that trigger to look like this:
  • Hero Limit
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Limit training of Archmage to 1 for (Picked player)
          • Player - Limit training of Blademaster to 1 for (Picked player)
          • Player - Limit training of Dreadlord to 1 for (Picked player)
          • Player - Limit training of Keeper of the Grove to 1 for (Picked player)
One of the main reasons to use Player Group - Pick every player is to gain access to the (Picked player) Event Response. The (Picked player) represents each Player inside of your Player Group, which in this case is (All players). So my trigger is running those four "Limit training" actions once for each Player.

This is much easier than doing it manually. This design also updates automatically if you add more Players to your game since it will consider them as one of the (All players).
 
Last edited:
Level 3
Joined
Dec 30, 2023
Messages
8
You should change that trigger to look like this:
  • Hero Limit
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Limit training of Archmage to 1 for (Picked player)
          • Player - Limit training of Blademaster to 1 for (Picked player)
          • Player - Limit training of Dreadlord to 1 for (Picked player)
          • Player - Limit training of Keeper of the Grove to 1 for (Picked player)
One of the main reasons to use Player Group - Pick every player is to gain access to the (Picked player) Event Response. The (Picked player) represents each Player inside of your Player Group, which in this case is (All players). So my trigger is running those four "Limit training" actions once for each Player.

This is much easier than doing it manually. This design also updates automatically if you add more Players to your game since it will consider them as one of the (All players).


Ohh, didn't know about that! Now it even looks neater! 😄

Thank You So Much for the help! 💙
 
Top