feat: add undo

This commit is contained in:
2025-04-05 10:53:41 +02:00
parent 8c2c6946d7
commit 2ec7be27ca
9 changed files with 71 additions and 11 deletions

View File

@@ -24,6 +24,10 @@ public class CommandExecutor {
assert result != CommandResult.Moved || command instanceof PlayerCommand;
processResult(command, result);
if (command instanceof PlayerCommand playerCommand)
this.game.addAction(playerCommand);
command.postExec(game, outputSystem);
return result;
}