forked from External/mage
dev, AI: improved AI logs:
* added object and targets info for possible actions; * added detailed score for each action in possible action chains; * added stack info; * improved output for easy read and analyse;
This commit is contained in:
parent
e3de777bd5
commit
add2d0473e
7 changed files with 281 additions and 163 deletions
|
|
@ -1315,10 +1315,10 @@ public class ComputerPlayer extends PlayerImpl {
|
|||
}
|
||||
switch (game.getTurnStepType()) {
|
||||
case UPKEEP:
|
||||
// TODO: is it needs here? Need research (e.g. for better choose in upkeep triggers)?
|
||||
findPlayables(game);
|
||||
break;
|
||||
case DRAW:
|
||||
logState(game);
|
||||
break;
|
||||
case PRECOMBAT_MAIN:
|
||||
findPlayables(game);
|
||||
|
|
@ -2873,12 +2873,6 @@ public class ComputerPlayer extends PlayerImpl {
|
|||
return threats;
|
||||
}
|
||||
|
||||
protected void logState(Game game) {
|
||||
if (log.isTraceEnabled()) {
|
||||
logList("Computer player " + name + " hand: ", new ArrayList<MageObject>(hand.getCards(game)));
|
||||
}
|
||||
}
|
||||
|
||||
protected void logList(String message, List<MageObject> list) {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append(message).append(": ");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue