/** * @file Globals.java * @brief * File containing the Globals class, a helper class for the * vector based evaluation system * * @author Christos Choutouridis 8997 cchoutou@ece.auth.gr * @author Konstantina Tsechelidou 8445 konstsec@ece.auth.gr */ package gr.auth.ee.dsproject.node; import gr.auth.ee.dsproject.pacman.PacmanUtilities; /** * @class Globals * @brief * Contains constants and factors to trick * the Node evaluation algorithm */ public class Globals { /* * Global constants */ public static final int NO_PLACE = -1; // out of region square //public static final int NO_MOVE = -1; public static final int INVALID_MOVE = -1; // invalid move marker public static final int EVAL_MAX = 100; // out max evaluation value public static final int EVAL_MIN = -100; // our minimum evaluation value public static final int NO_EVAL = EVAL_MIN-1; // mark the invalid move or no evaluation /* * Evaluation settings */ /** * Mixing factor for the minimum distance */ public static final double EVAL_GHOSTDIST_MIN_FACTOR = 0.8; public static final double EVAL_LGHOSTDIST_AVER_FACTOR = 1 - EVAL_GHOSTDIST_MIN_FACTOR; /** * Evaluation mixing factor representing how much the ghost distances will * affect the final evaluation value */ public static final double EVAL_GHOSTDIST_FACTOR = 0.6; /** * Evaluation mixing factor representing how much the flag distances will * affect the final evaluation value */ public static final double EVAL_FLAGDIST_FACTOR = 1 - EVAL_GHOSTDIST_FACTOR; /* * Tree settings */ public static final int MINMAXTREE_MAX_DEPTH = 2; // MUST be multiple of 2 /* * In order to find out when a ghost is inside a cavity we manualy * define the box limits of the cavity boxes of the current maze here * :) */ public static final int BOXES[][][] = { { { 5, 5}, { 8, 8} }, { { 5, 16}, { 8, 19} }, { {11, 5}, {14, 8} }, { {11, 16}, {14, 19} } }; public static final int[] FALSE_POS = {-1, -1}; public static final int MAX_DISTANCE = PacmanUtilities.numberOfRows + PacmanUtilities.numberOfColumns - 1; }