Examples of ScoreEntry


Examples of com.barrybecker4.game.twoplayer.common.cache.ScoreEntry

     * @return statically evaluated value for the board.
     */
    private int cachedWorth( Move lastMove, ParameterArray weights, HashKey key) {

        // uncomment this to do caching.
        ScoreEntry cachedScore = scoreCache_.get(key);
        ///////// comment this to do debugging
        //if (cachedScore != null) {
        //    System.out.println("scoreCache_="+scoreCache_);
        //    return cachedScore.getScore();
        //}

        int worth = worthCalculator_.worth(lastMove, weights);

        if (cachedScore == null) {
            scoreCache_.put(key, new ScoreEntry(key, worth, board_.toString(), getWorthInfo()));
        }
        else {
            if (cachedScore.getScore() != worth) {
                StringBuilder bldr = new StringBuilder();
                bldr.append("\ncachedScore ").
                        append(cachedScore).
                        //append("\nfor key=").
                        //append(getHashKey()).
View Full Code Here

Examples of core.Score.ScoreEntry

    if(highscore)
    {
      for(int i = 0; i < Score.getInstance().getScorelist().length; i++)
      {
        ScoreEntry temp = Score.getInstance().getScorelist()[i]; // Temporärer Scoreentry
        Renderer.getInstance().drawText(temp.getName(), 200, i * 50 + 40, Color.BLACK);
        Renderer.getInstance().drawText(String.valueOf(temp.getPoints()), 500, i * 50 + 40, Color.BLACK);
      }
    }

  } //draw end
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.