The problems with this class start with the constructor
public function __construct (char $mark, $lines) : void {
The player class should accept a Mark instance, already validated. You want to input value objects into your other classes, which are by definition already validated syntactically. char $mark is wrong, why a "char" when you already have a class for this? Better: Mark $mark.
In real-life, the player's sole job is to decide where to put next his symbol, given a state of the map. It should not hold itself the symbols (that's what Map is for) or any other state.
The problems with this class start with the constructor
The player class should accept a Mark instance, already validated. You want to input value objects into your other classes, which are by definition already validated syntactically.
char $mark
is wrong, why a "char" when you already have a class for this? Better:Mark $mark
.In real-life, the player's sole job is to decide where to put next his symbol, given a state of the map. It should not hold itself the symbols (that's what Map is for) or any other state.