• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

Chat string to ping unit

Status
Not open for further replies.
Level 5
Joined
Jan 4, 2006
Messages
139
How can I make a chat string for anyone who types in a command as an exact match, to finda certain unit that they own.
ie. I could put my harvesting unit as a worker (showing the idle worker button) but it will clog up acctual workers, so I want to instead have a chat command (-h or -harvester) to ping all of the players harvesters on the map.
Thanks in advance :)
 
Something like this maybe:

  • PingHarvesters
    • Events
      • Player - Player 1 (Red) types a chat message containing -h as An exact match
      • Player - Player 1 (Red) types a chat message containing -harvester as An exact match
      • Etc...
    • Conditions
    • Actions
      • If ((Number of living Harvester units owned by (Triggering player)) Greater than or equal to 1) then do (Unit Group - Pick every unit in (Units owned by (Triggering player) of type Harvester) and do (Cinematic - Ping minimap for (Player group((Triggering player))) at (Position of (Picked unit)) for 1.00 seconds, using a Simple ping of color (100.00%, 100.00%, 100 else do (Game - Display to (Player group((Triggering player))) the text: No harvesters found!)
 
Last edited:
I would do like this:
[trigger:1:620d677d2c]Untitled Trigger 001
Events
Player - Player 1 (Red) types a chat message containing -harvester as An exact match
Conditions
Actions
Unit Group - Pick every unit in (Units owned by (Triggering player) of type Peasant) and do (Actions)
Loop - Actions
Cinematic - Ping minimap for (Player group((Triggering player))) at (Position of (Picked unit)) for 1.00 seconds
[/trigger:1:620d677d2c]
 
Status
Not open for further replies.
Back
Top