HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Guessing Trigger

03-14-2006, 07:36 PM#1
Eternal_Dread
I'm trying to make a guessing game trigger, like in Kodo Tag, but I can't find a way to make it so they can't play if they have under 50 gold. Heres what I have so far:
Trigger:
Jail Game
Collapse Events
Player - Player 1 (Red) types a chat message containing -guess as A substring
Player - Player 2 (Blue) types a chat message containing -guess as A substring
Player - Player 3 (Teal) types a chat message containing -guess as A substring
Player - Player 4 (Purple) types a chat message containing -guess as A substring
Player - Player 5 (Yellow) types a chat message containing -guess as A substring
Player - Player 6 (Orange) types a chat message containing -guess as A substring
Player - Player 7 (Green) types a chat message containing -guess as A substring
Player - Player 8 (Pink) types a chat message containing -guess as A substring
Player - Player 9 (Gray) types a chat message containing -guess as A substring
Player - Player 10 (Light Blue) types a chat message containing -guess as A substring
Conditions
Collapse Actions
Player - Set Player 1 (Red) Current gold to ((Player 1 (Red) Current gold) - 50)
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Get Triggering Player State) Equal to Current gold
Collapse Then - Actions
Collapse Unit Group - Pick every unit in (Units owned by (Triggering player)) and do (Actions)
Collapse Loop - Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
Collapse Or - Any (Conditions) are true
Collapse Conditions
(Unit-type of (Picked unit)) Equal to Runner (1)
(Unit-type of (Picked unit)) Equal to Runner (2)
(Unit-type of (Picked unit)) Equal to Runner (3)
(Unit-type of (Picked unit)) Equal to Runner (4)
Collapse Then - Actions
Set Guess = ((Entered chat string) + (8 + 9))
Set Random = (String((Random integer number between 1 and 10)))
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
Guess Equal to Random
Collapse Then - Actions
Game - Display to (All allies of Player 1 (Red)) the text: ((Name of (Triggering player)) + has guessed the random number! He wins 100 gold!)
Player - Add 100 to (Triggering player) Current gold
Collapse Else - Actions
Player Group - Pick every player in (All players controlled by a ((Triggering player) controller) player) and do (Player - Set (Triggering player) Current gold to ((Player 1 (Red) Current gold) - 50))
Collapse Else - Actions
Player Group - Pick every player in (All players controlled by a ((Triggering player) controller) player) and do (Game - Display to (All players matching ((Triggering player) Equal to (Picked player))) the text: Must be in jail to ...)
Else - Actions
03-14-2006, 07:46 PM#2
Captain Griffen
Trigger:
((Triggering player) Current gold) Greater than or equal to 50
03-14-2006, 07:49 PM#3
Eternal_Dread
Quote:
Originally Posted by Captain Griffen
Trigger:
((Triggering player) Current gold) Greater than or equal to 50
I don't have this option in my editor.
EDIT: Oh, I see now. Thanks.