Skip to content

Commit

Permalink
also fixed issue for connect 4
Browse files Browse the repository at this point in the history
  • Loading branch information
benblack769 committed Apr 2, 2021
1 parent aad38be commit 5e328e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pettingzoo/classic/connect_four/connect_four.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def __init__(self):
# [1, 1, 2, 1, 0, 1, 0]], dtype=int8)
def observe(self, agent):
board_vals = np.array(self.board).reshape(6, 7)
cur_player = self.possible_agents.index(self.agent_selection)
cur_player = self.possible_agents.index(agent)
opp_player = (cur_player + 1) % 2

cur_p_board = np.equal(board_vals, cur_player + 1)
Expand Down

0 comments on commit 5e328e8

Please sign in to comment.