• 🏆 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!

Canceling Upgrades

Status
Not open for further replies.
Level 17
Joined
Nov 13, 2006
Messages
1,814
ok if u mean canceling it with trigger during its already started then in my head have 2 way.

1. maybe with force keys if have a hotkey for cancel upgrade, idk if work coz dont test also maybe u can try re order the research, maybe its cancel, idk
2. pause unit and amybe recreate if needed (idk if order stop work or no but pause must work but then the building stoped too, so then u can recreate the building)
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
for me this work

  • Upgrade
    • Events
      • Unit - A unit Begins an upgrade
    • Conditions
    • Actions
      • Wait 0.00 seconds
      • Game - Force (Triggering player) to press Escape/Cancel
      • Game - Display to (All players) the text: (Name of (Triggering unit))
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
I tried that but the order fire too quickly and I would have to give it some delay, thanks for posting that though.

ok anyway u can use timer and hashtable for make delay, its mean save unit to hashtable where the key is the timerid then its work with 100 unit too even u upgrade same time

(i can do it if u want, but in jass only, in gui i am noob with handling timers without make add event for 1 trigger)
 
Status
Not open for further replies.
Top