- Joined
- Dec 27, 2012
- Messages
- 36
As the title says the repick system got screwed somehow...i checked the trigger 3 times and there was no problem with it at least thats what i think.The problem is that when i and a friend[purple] pick a hero and he writes -repick he cant choose another hero cuz it says "You allready have a hero" but strangely i can get another hero.
heres the trigger
heres the trigger
-
Tavern Repick
-

Events
-


Player - Player 1 (Red) types a chat message containing -repick as An exact match
-


Player - Player 2 (Blue) types a chat message containing -repick as An exact match
-


Player - Player 3 (Teal) types a chat message containing -repick as An exact match
-


Player - Player 4 (Purple) types a chat message containing -repick as An exact match
-


Player - Player 5 (Yellow) types a chat message containing -repick as An exact match
-


Player - Player 6 (Orange) types a chat message containing -repick as An exact match
-
-

Conditions
-


And - All (Conditions) are true
-



Conditions
-




HeroChosenByPlayer[(Player number of (Triggering player))] Equal to True
-




PlayerRepicked[(Player number of (Triggering player))] Equal to False
-
-
-
-

Actions
-


Set TempUnitGroup = (Units owned by (Triggering player) matching (((Matching unit) is A Hero) Equal to True))
-


Unit Group - Pick every unit in TempUnitGroup and do (Actions)
-



Loop - Actions
-




Player Group - Pick every player in (All players) and do (Actions)
-





Loop - Actions
-






Player - Make (Unit-type of (Picked unit)) Available for training/construction by (Picked player)
-
-
-




Unit - Remove (Picked unit) from the game
-
-
-


Custom script: call DestroyGroup(udg_TempUnitGroup)
-


Game - Display to (All players) the text: ((Name of (Triggering player)) + has repicked a hero)
-


Set HeroChosenByPlayer[(Player number of (Owner of (Sold unit)))] = False
-


Selection - Clear selection for (Triggering player)
-


Selection - Add Hero Tavern 0002 <gen> to selection for (Triggering player)
-


Camera - Pan camera for (Triggering player) to (Center of Hero Tavern <gen>) over 1.00 seconds
-


Set PlayerRepicked[(Player number of (Triggering player))] = True
-
-
-
Hero Selection
-

Events
-


Unit - A unit Sells a unit
-
-

Conditions
-


And - All (Conditions) are true
-



Conditions
-




((Sold unit) is A Hero) Equal to True
-




Or - Any (Conditions) are true
-





Conditions
-






(Selling unit) Equal to Hero Tavern 0002 <gen>
-
-
-
-
-
-

Actions
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




HeroChosenByPlayer[(Player number of (Owner of (Sold unit)))] Equal to True
-
-



Then - Actions
-




Unit - Remove (Sold unit) from the game
-




Game - Display to (All players) the text: You've allready pic...
-
-



Else - Actions
-




Set HeroChosenByPlayer[(Player number of (Owner of (Sold unit)))] = True
-




Player Group - Pick every player in (All players) and do (Actions)
-





Loop - Actions
-






Player - Make (Unit-type of (Sold unit)) Unavailable for training/construction by (Picked player)
-
-
-




Selection - Clear selection for (Owner of (Sold unit))
-




Selection - Add (Sold unit) to selection for (Owner of (Sold unit))
-
-
-
-



