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

-Kill command??

Status
Not open for further replies.
Level 37
Joined
Mar 6, 2006
Messages
9,240
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
669
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