• 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.

-Kill command??

Status
Not open for further replies.
Level 37
Joined
Mar 6, 2006
Messages
9,243
There is a space after -kill. It's "-kill " and the space counts as a character.

  • Untitled Trigger 048
    • Events
      • Player - Player 1 (Red) types a chat message containing -kill as A substring
    • Conditions
      • (Substring((Entered chat string), 1, 6)) Equal to -kill
    • Actions
      • Set i1 = (Integer((Substring((Entered chat string), 7, (Length of (Entered chat string))))))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • i1 Greater than 0
          • i1 Less than 1000
        • Then - Actions
          • Set i2 = i1
          • Game - Display to Player Group - Player 1 (Red) the text: (String(i2))
        • Else - Actions
          • Game - Display to Player Group - Player 1 (Red) the text: No
  • Untitled Trigger 051
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Killing unit)) Not equal to Neutral Hostile
    • Actions
      • Set Kills[(Player number of (Owner of (Killing unit)))] = (Kills[(Player number of (Owner of (Killing unit)))] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Kills[(Player number of (Owner of (Killing unit)))] Equal to i2
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Wait Campaign quest delay seconds
          • Game - Victory (Owner of (Killing unit)) (Show dialogs, Show scores)
        • Else - Actions
 
Level 15
Joined
Sep 27, 2009
Messages
676
Going to make it, i will tell u if it's not working :) !
-EDIT:
Not working good ...
This is my trigger:
  • Kill
    • Events
      • Player - Player 2 (Blue) types a chat message containing -kill as A substring
    • Conditions
      • (Substring((Entered chat string), 1, 6)) Equal to -kill
    • Actions
      • Set KILLZ = (Integer((Substring((Entered chat string), 7, (Length of (Entered chat string))))))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • KILLZ Greater than 49
          • KILLZ Less than 151
        • Then - Actions
          • Set KILLZ2 = KILLZ
          • Game - Display to Player Group - Player 2 (Blue) for 4.00 seconds the text: (String(KILLZ2))
        • Else - Actions
          • Game - Display to Player Group - Player 2 (Blue) for 4.00 seconds the text: |cffff0000You canno...
 
Status
Not open for further replies.
Top