- Joined
- Jun 20, 2017
- Messages
- 380
Can anyone help to limiting resources on these trigger? (All I want is send only 2 gold/2k lumber per minute with cmd, you cannot send more than that)
-
Trade
-
Events
-
Player - Player 1 (Red) types a chat message containing -g as A substring
-
Player - Player 2 (Blue) types a chat message containing -g as A substring
-
Player - Player 3 (Teal) types a chat message containing -g as A substring
-
Player - Player 4 (Purple) types a chat message containing -g as A substring
-
Player - Player 5 (Yellow) types a chat message containing -g as A substring
-
Player - Player 6 (Orange) types a chat message containing -g as A substring
-
Player - Player 7 (Green) types a chat message containing -g as A substring
-
Player - Player 8 (Pink) types a chat message containing -g as A substring
-
Player - Player 9 (Gray) types a chat message containing -g as A substring
-
Player - Player 10 (Light Blue) types a chat message containing -g as A substring
-
Player - Player 11 (Dark Green) types a chat message containing -g as A substring
-
Player - Player 12 (Brown) types a chat message containing -g as A substring
-
Player - Player 1 (Red) types a chat message containing -w as A substring
-
Player - Player 2 (Blue) types a chat message containing -w as A substring
-
Player - Player 3 (Teal) types a chat message containing -w as A substring
-
Player - Player 4 (Purple) types a chat message containing -w as A substring
-
Player - Player 5 (Yellow) types a chat message containing -w as A substring
-
Player - Player 6 (Orange) types a chat message containing -w as A substring
-
Player - Player 7 (Green) types a chat message containing -w as A substring
-
Player - Player 8 (Pink) types a chat message containing -w as A substring
-
Player - Player 9 (Gray) types a chat message containing -w as A substring
-
Player - Player 10 (Light Blue) types a chat message containing -w as A substring
-
Player - Player 11 (Dark Green) types a chat message containing -w as A substring
-
Player - Player 12 (Brown) types a chat message containing -w as A substring
-
-
Conditions
-
Actions
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Substring((Entered chat string), 1, 2)) Equal to (==) -g
-
-
Then - Actions
-
Set Integer_TradePlayer = (Integer((Substring((Entered chat string), 4, 5))))
-
Set Integer_TradeAmount = (Integer((Substring((Entered chat string), 6, (Length of (Entered chat string))))))
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Player(Integer_TradePlayer)) slot status) Equal to (==) Is playing
-
((Triggering player) is an ally of (Player(Integer_TradePlayer))) Equal to (==) True
-
((Triggering player) Current gold) Greater than or equal to (>=) Integer_TradeAmount
-
Integer_TradeAmount Greater than (>) 0
-
-
Then - Actions
-
Player - Set (Triggering player) Current gold to (((Triggering player) Current gold) - Integer_TradeAmount)
-
Player - Add Integer_TradeAmount to (Player(Integer_TradePlayer)) Current gold
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + ( has given + (Strings_PlayerColors[Integer_TradePlayer] + ((Name of (Player(Integer_TradePlayer))) + (|r + ( |cffffff00 + ((String(Integer_TradeAmount)) +
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
Else - Actions
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + not enough resources. |cffff0000Cannot trade with the enemy.|r)))
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
-
-
-
Else - Actions
-
-
-------- /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// --------
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Substring((Entered chat string), 1, 2)) Equal to (==) -w
-
-
Then - Actions
-
Set Integer_TradePlayer = (Integer((Substring((Entered chat string), 4, 5))))
-
Set Integer_TradeAmount = (Integer((Substring((Entered chat string), 6, (Length of (Entered chat string))))))
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Player(Integer_TradePlayer)) slot status) Equal to (==) Is playing
-
((Triggering player) is an ally of (Player(Integer_TradePlayer))) Equal to (==) True
-
((Triggering player) Current lumber) Greater than or equal to (>=) Integer_TradeAmount
-
Integer_TradeAmount Greater than (>) 0
-
-
Then - Actions
-
Player - Set (Triggering player) Current lumber to (((Triggering player) Current lumber) - Integer_TradeAmount)
-
Player - Add Integer_TradeAmount to (Player(Integer_TradePlayer)) Current lumber
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + ( has given + (Strings_PlayerColors[Integer_TradePlayer] + ((Name of (Player(Integer_TradePlayer))) + (|r + ( |cff008000 + ((String(Integer_TradeAmount)) +
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
Else - Actions
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + not enough resources. |cffff0000Cannot trade with the enemy.|r)))
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
-
-
-
Else - Actions
-
-
-
-
-
Trade Limit
-
Events
-
Time - Timer_TradeRestart expires
-
-
Conditions
-
Actions
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Integer_TradeAmount Less than or equal to (<=) 2
-
-
Then - Actions
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + you can only send a maximum of 2 Gold per minute.)))
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
Else - Actions
-
-
-------- /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// --------
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Integers_TradedMaxLumber[Integer_TradeAmount] Less than or equal to (<=) 2000
-
-
Then - Actions
-
Set PlayerGroup = (Player group((Triggering player)))
-
Game - Display to PlayerGroup the text: (Strings_PlayerColors[(Player number of (Triggering player))] + ((Name of (Triggering player)) + (|r + you can only send a maximum of 2000 Lumber per minute.)))
-
Custom script: call DestroyForce(udg_PlayerGroup)
-
-
Else - Actions
-
-
-
-