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

[Trigger] How to make a simple trigger set variable with chat command?

Status
Not open for further replies.
Level 3
Joined
Feb 16, 2007
Messages
31
So, in some games or spell test maps / escape maps for example, you can set ice slide speed for example, so how to create the trigger to do that? I have opened some maps to find out but still I dont understand the Player chat event, substring event correctly, so could someone even explain how the substring works, or make a simple understandable trigger that sets a variable to a certain amount you can choose with a chat command.
 
Level 8
Joined
May 21, 2008
Messages
218
Substrings work like this

-Event Player 1 Red (enters a message?)
-Condition ---------------
-Action If Conditions are true then do actions else do else actions
Condition- Entered Chat Substring 4,8 = nts are
Then -------------------
Else ---------------------

In this if player 1 red typed grunts are dumb
123--------9
----nts are -----
Get it? Letters 4-8

So for you you would do
entered chat substing 1,18 -set ice speed to 9
or something like that
 
Status
Not open for further replies.
Top