diff --git a/src/game/mouse/card_matching/define_variables.js b/src/game/mouse/card_matching/define_variables.js
deleted file mode 100644
index 74e39c7..0000000
--- a/src/game/mouse/card_matching/define_variables.js
+++ /dev/null
@@ -1 +0,0 @@
-let scoreManager = new ScoreManager();
diff --git a/src/game/mouse/card_matching/game.js b/src/game/mouse/card_matching/game.js
index e3edbc4..103e6cf 100644
--- a/src/game/mouse/card_matching/game.js
+++ b/src/game/mouse/card_matching/game.js
@@ -24,17 +24,23 @@ var Game = {
screenTopUI.makeBackButton( (function() { this.back(); }).bind(this) );
screenTopUI.makeFullScreenButton();
- var scoreBoard = new ScoreBoard();
- scoreManager.addOnChangeScoreListener( function(score) {
- sessionStorageManager.setRecord(score);
- scoreBoard.printScore(NumberUtil.numberWithCommas(score));
- });
- scoreManager.addOnChangeHighScoreListener( function(highScore) {
- // console.log(highScore);
- // sessionStorageManager.setAppHighestRecord(highScore);
- sessionStorageManager.setIsNewBestRecrd(true);
- // screenBottomUI.printLeftTextWithAppHighestRecord(sessionStorageManager.getAppHighestRecord());
- });
+ this.scoreManager = new ScoreManager();
+ this.scoreBoard = new ScoreBoard();
+ this.scoreManager.addOnChangeScoreListener(
+ (function(score) {
+ sessionStorageManager.setRecord(score);
+ this.scoreBoard.printScore(NumberUtil.numberWithCommas(score));
+ }).bind(this)
+ );
+ this.scoreManager.addOnChangeHighScoreListener(
+ (function(highScore) {
+ // console.log(highScore);
+ // sessionStorageManager.setAppHighestRecord(highScore);
+ sessionStorageManager.setIsNewBestRecrd(true);
+ // this.screenBottomUI.printLeftTextWithAppHighestRecord(sessionStorageManager.getAppHighestRecord());
+ }).bind(this)
+ );
+
this.stageTimer = new StageTimer(
Game.GAME_TIME_SEC,
(function() {
@@ -125,7 +131,7 @@ var Game = {
this.card_characters[13] = 'soccer';
this.card_characters_count = this.card_characters.length;
this.cardCharacterIndexList = Phaser.ArrayUtils.numberArray(0, this.card_characters_count - 1);
- console.log("cardCharacterIndexList : " + this.cardCharacterIndexList.length);
+ // console.log("cardCharacterIndexList : " + this.cardCharacterIndexList.length);
for(var i = 0; i < DudeCard.MAX_CARD_COLUMN_NO; i++){
for(var j = 0; j < DudeCard.MAX_CARD_ROW_NO; j++) {
@@ -205,7 +211,6 @@ var Game = {
},
setOpenCardColumnRow() {
- console.log("setOpenCardColumnRow : " + this.playingStageNo);
switch(this.playingStageNo) {
case 1:
this.activatedCardColumnNo = 2;
@@ -405,7 +410,6 @@ var Game = {
},
clearOpenedTwoCards() {
- console.log(this.openCardInfoIndex[0]);
var card1 = this.cards[this.openCardInfoIndex[0]];
this.resetOpenCardInfo(card1.getColumnNo(), card1.getRowNo());
this.reservedHideCard[0] = card1;
@@ -432,7 +436,7 @@ var Game = {
// this.addScore();
// this.updateScore();
- scoreManager.plusScore(this.getScore());
+ this.scoreManager.plusScore(this.getScore());
// to do : check clear stage
this.clearedCardCount += 2;
diff --git a/src/web/client/card_matching.html b/src/web/client/card_matching.html
index dd635e9..259fd84 100644
--- a/src/web/client/card_matching.html
+++ b/src/web/client/card_matching.html
@@ -34,7 +34,6 @@
-