2048.html
changeset 59 28613a54c71c
parent 55 8ba9dc89be87
child 61 eed17c93d420
equal deleted inserted replaced
58:847ed98813d1 59:28613a54c71c
   557       }
   557       }
   558     }
   558     }
   559 
   559 
   560     ui.ai.algList = {
   560     ui.ai.algList = {
   561       "ai-blind-random": function() {
   561       "ai-blind-random": function() {
   562         return new ai.blindRandom(ui.brdEngine);
   562         return new ai.BlindRandom(ui.brdEngine);
   563       },
   563       },
   564       "ai-blind-weight-random": function(aiDom) {
   564       "ai-blind-weight-random": function(aiDom) {
   565         var cfg = {};
   565         var cfg = {};
   566         ui.ai.parseCfg(aiDom, cfg);
   566         ui.ai.parseCfg(aiDom, cfg);
   567         return new ai.blindWeightRandom(ui.brdEngine, cfg);
   567         return new ai.BlindWeightRandom(ui.brdEngine, cfg);
   568       },
   568       },
   569       "ai-blind-cycle": function(aiDom) {
   569       "ai-blind-cycle": function(aiDom) {
   570         var cfg = {};
   570         var cfg = {};
   571         cfg.clockwise = aiDom.querySelectorAll("input[name='clockwise']")[0].checked;
   571         cfg.clockwise = aiDom.querySelectorAll("input[name='clockwise']")[0].checked;
   572         cfg.whilePossible = aiDom.querySelectorAll("input[name='whilePossible']")[0].checked;
   572         cfg.whilePossible = aiDom.querySelectorAll("input[name='whilePossible']")[0].checked;
   573         return new ai.blindCycle(ui.brdEngine, cfg);
   573         return new ai.BlindCycle(ui.brdEngine, cfg);
   574       },
   574       },
   575       "ai-one-step-deep": function(aiDom) {
   575       "ai-one-step-deep": function(aiDom) {
   576         var cfg = {};
   576         var cfg = {};
   577         ui.ai.parseCfg(aiDom, cfg);
   577         ui.ai.parseCfg(aiDom, cfg);
   578         return new ai.oneStepDeep(ui.brdEngine, cfg);
   578         return new ai.OneStepDeep(ui.brdEngine, cfg);
   579       },
   579       },
   580       "ai-deep-max-score": function() {
   580       "ai-deep-max-score": function() {
   581         return new ai.deepMaxScore(ui.brdEngine);
   581         return new ai.DeepMaxScore(ui.brdEngine);
   582       },
   582       },
   583       "ai-deep-max-score-corner": function() {
   583       "ai-deep-max-score-corner": function() {
   584         return new ai.deepMaxScoreCorner(ui.brdEngine);
   584         return new ai.DeepMaxScoreCorner(ui.brdEngine);
   585       },
   585       },
   586       "ai-expectimax": function() {
   586       "ai-expectimax": function() {
   587         return new ai.expectimax(ui.brdEngine);
   587         return new ai.expectimax(ui.brdEngine);
   588       },
   588       },
   589       // "": function() {
   589       // "": function() {