Ima start by saying I had a different one that worked. But I decided to remake most of it as I wanted to change the condition for how the item works. Now the chat string doesn't work at all. This trigger is for each player to set a value so they can use certain abilities from an item that will then reference the set value.
-
Setting DT amount
-
Events
-
Player - Player 1 (Red) types a chat message containing DT as A substring
-
Player - Player 2 (Blue) types a chat message containing DT as A substring
-
Player - Player 3 (Teal) types a chat message containing DT as A substring
-
Player - Player 4 (Purple) types a chat message containing DT as A substring
-
Player - Player 5 (Yellow) types a chat message containing DT as A substring
-
Player - Player 6 (Orange) types a chat message containing DT as A substring
-
-
Conditions
-
(Substring((Entered chat string), 1, 3)) Equal to DT
-
-
Actions
-
Custom script: set bj_wantDestroyGroup = true
-
Unit Group - Pick every unit in (Units owned by (Triggering player).) and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked unit) has an item of type |cffd45e19Black Diamond of Eclipso|r) Equal to True
-
((Picked unit) is A Hero) Equal to True
-
-
Then - Actions
-
Set VariableSet DTUnit[(Player number of (Triggering player))] = (Picked unit)
-
-
Else - Actions
-
Set VariableSet DTUnit[(Player number of (Triggering player))] = No unit
-
-
-
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
DTUnit[(Player number of (Triggering player))] Not equal to No unit
-
-
Then - Actions
-
Set VariableSet DTAmount[(Player number of (Triggering player))] = (Real((Substring((Entered chat string), 4, (Length of (Entered chat string))))))
-
Set VariableSet TempPG[0] = (All players matching ((Matching player) Equal to (Triggering player)).)
-
Game - Display to TempPG[0] for 5.00 seconds the text: (Dark Tribute Cost: |cffff0000 + ((String(DTAmount[(Player number of (Triggering player))])) + |r))
-
Custom script: call DestroyForce( udg_TempPG[0])
-
-
Else - Actions
-
-
-