Skip to content

Commit 80d86cf

Browse files
committed
Fix social deduction chance legal actions
1 parent 97e9e2a commit 80d86cf

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

open_spiel/games/social_deduction/social_deduction.cc

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,10 +151,9 @@ Player SocialDeductionState::CurrentPlayer() const {
151151

152152
std::vector<Action> SocialDeductionState::LegalActions() const {
153153
if (IsTerminal()) return {};
154-
if (phase_ == Phase::kAssignRoles) {
155-
return RoleAssignments(num_players_, parent_game_.NumImposters());
154+
if (phase_ == Phase::kAssignRoles || phase_ == Phase::kObservation) {
155+
return LegalChanceOutcomes();
156156
}
157-
if (phase_ == Phase::kObservation) return ObservationSignals(alive_);
158157

159158
std::vector<Action> actions;
160159
if (phase_ == Phase::kCommunication) {

0 commit comments

Comments
 (0)