• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Make a hero in tavern on cooldown

Status
Not open for further replies.
Level 6
Joined
Sep 24, 2015
Messages
174
you could change alliance settings? change owner of you entering hero for player 13 (Neutral hostile) or 14 (Neutral passive) wait (your cooldown) and then reset alliance to Whatever owner player you want :)

Well, like this maybe...

Edit
  • changing owner of a unit
    • Event
      • Unit - A unit enters <your region>
    • Conditions
      • (Unit-type of (Entering unit)) Equal to* (your hero)
    • Actions
      • Unit - Change ownership of (Entering unit) to Neutre Hostile and Change colour
      • Wait 10.00 seconds
      • Unit - Change ownership of (Entering unit) to <Your desiredPlayerColour> and Change colour
But this will work only if the unit enters in the region and will not retrigger if the unit stays in the region.

I show you the triggers rquired if you wanna do it every 10 seconds if the unit is in the region ( but you need 2 triggers)

  • changing owner of a unit every 10 seconds
    • Event
      • Time - Every 10.00 seconds of game time
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Group unit - Pick every unit in Units in <your region> matching ((Unit-type of (Matching unit)) Equal to <your hero type>)) and do (Actions)
        • Loop - Actions
          • Unit - Change ownership of (Picked unit) to Neutral Hostile and Change coulour
  • changing owner of a unit every 10 seconds
    • Event
      • Time - Every 20.00 seconds of game time
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Group unit - Pick every unit in Units in <your region> matching ((Unit-type of (Matching unit)) Equal to <your hero type>)) and do (Actions)
        • Loop - Actions
          • Unit - Change ownership of (Picked unit) to <your player color> and Change coulour
 
Last edited:
Level 11
Joined
Jun 26, 2014
Messages
497
you could change alliance settings? change owner of you entering hero for player 13 (Neutral hostile) or 14 (Neutral passive) wait (your cooldown) and then reset alliance to Whatever owner player you want :)

Well, like this maybe...

Edit
  • changing owner of a unit
    • Event
      • Unit - A unit enters <your region>
    • Conditions
      • (Unit-type of (Entering unit)) Equal to* (your hero)
    • Actions
      • Unit - Change ownership of (Entering unit) to Neutre Hostile and Change colour
      • Wait 10.00 seconds
      • Unit - Change ownership of (Entering unit) to <Your desiredPlayerColour> and Change colour
But this will work only if the unit enters in the region and one time...

How will this make the hero in the tavern on cooldown?
 
Level 6
Joined
Sep 24, 2015
Messages
174
I did the trigger like you asked in the Second post...for your hero in your region...
 
Last edited:
Level 13
Joined
Jul 15, 2007
Messages
763
You can make the "hero" at the tavern a dummy unit or item which is infinite in stock, and add the cooldown to actually buying your hero via triggers (or disable its availability). So if poop enters region and poop is on cooldown, players buying poop at the Tavern will not get poop, but a message saying that poop is on cooldown.

If poop is permanently on cooldown, then you can just remove it from the tavern instead.
 
Level 11
Joined
Jun 26, 2014
Messages
497
You can make the "hero" at the tavern a dummy unit or item which is infinite in stock, and add the cooldown to actually buying your hero via triggers (or disable its availability). So if poop enters region and poop is on cooldown, players buying poop at the Tavern will not get poop, but a message saying that poop is on cooldown.

If poop is permanently on cooldown, then you can just remove it from the tavern instead.

How can I remove a unit from the tavern?
 
Level 13
Joined
Jul 15, 2007
Messages
763
How can I remove a unit from the tavern?

The easiest way for you to achieve this is in a trigger like this:

  • bla
    • Events
      • Unit - A unit Sells a unit
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Tavern
      • (Unit-type of (Sold unit)) Equal to Blademaster
    • Actions
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Player - Limit training of (Unit-type of (Sold unit)) to 0 for (Player((Integer A)))
 
Status
Not open for further replies.
Top