소스 검색

On peut continuer de verser une couleur sur un

tube complet en refaisant l'action
master
Figg 10 달 전
부모
커밋
dd9c988eea
1개의 변경된 파일5개의 추가작업 그리고 5개의 파일을 삭제
  1. 5
    5
      js/controller.js

+ 5
- 5
js/controller.js 파일 보기

@@ -85,18 +85,18 @@ class Controller
85 85
 		return sourceTube != null && targetTube != null
86 86
 			&& sourceTube != targetTube
87 87
 			&& (targetTube.isEmpty() || sourceTube.peekTopColor() == targetTube.peekTopColor())
88
-			&& !targetTube.isFull() && !targetTube.isComplete();
88
+			&& !targetTube.isFull();
89 89
 	}
90 90
 	
91 91
 	pourColorInto(sourceTube, targetTube)
92 92
 	{
93
-		while (this.canPourInto(sourceTube, targetTube))
93
+		do
94 94
 		{
95 95
 			targetTube.addColorLayer(sourceTube.removeColorLayer());
96
-		}
96
+		} while (this.canPourInto(sourceTube, targetTube) && !targetTube.isComplete());
97 97
 		
98
-		this.checkTubeCompletion(sourceTube);
99
-		this.checkTubeCompletion(targetTube);
98
+		//this.checkTubeCompletion(sourceTube);
99
+		//this.checkTubeCompletion(targetTube);
100 100
 	}
101 101
 	
102 102
 	checkTubeCompletion(tube)

Loading…
취소
저장