Add: bonus meat into game
This commit is contained in:
@@ -38,9 +38,7 @@ MeatBase.prototype.initMeatTypeVariables = function() {
|
||||
|
||||
this.baseScale = 0.5;
|
||||
|
||||
this.rareScore = 0;
|
||||
this.welldoneScore = 0;
|
||||
this.burnBlackScore = 0;
|
||||
this.className = "MeatBase";
|
||||
}
|
||||
|
||||
|
||||
@@ -144,6 +142,18 @@ MeatBase.prototype.onDragStopListener = function(pointer) {
|
||||
|
||||
|
||||
|
||||
MeatBase.prototype.getClassName = function() {
|
||||
return this.className;
|
||||
}
|
||||
|
||||
MeatBase.prototype.getScore = function(meatDoneness) {
|
||||
var scoreDoneness = this.scoreArray[meatDoneness];
|
||||
var totalCookingTime = this.cookingTime[MeatBase.MEAT_BACK] + this.cookingTime[MeatBase.MEAT_FRONT];
|
||||
|
||||
console.log(totalCookingTime);
|
||||
return scoreDoneness * totalCookingTime;
|
||||
}
|
||||
|
||||
MeatBase.prototype.isFront = function() {
|
||||
if(this.cookingSide == MeatBase.MEAT_BACK)
|
||||
return true;
|
||||
@@ -313,18 +323,20 @@ MeatBase.prototype.changeAnimateSmokeColor = function(type) {
|
||||
}
|
||||
|
||||
|
||||
MeatBase.MEAT_NONE = 0;
|
||||
MeatBase.MEAT_FRONT = 1;
|
||||
MeatBase.MEAT_BACK = 2;
|
||||
MeatBase.CLASS_NAME = "MeatBase";
|
||||
|
||||
MeatBase.MEAT_NONE = 0;
|
||||
MeatBase.MEAT_FRONT = 1;
|
||||
MeatBase.MEAT_BACK = 2;
|
||||
|
||||
MeatBase.ANGLE_NONE = 0;
|
||||
MeatBase.ANGLE_FRONT = 30;
|
||||
MeatBase.ANGLE_BACK = -30;
|
||||
|
||||
MeatBase.DONENESS_RARE = 0;
|
||||
MeatBase.DONENESS_WELLDONE = 1;
|
||||
MeatBase.DONENESS_BURN_BLACK = 2;
|
||||
MeatBase.DONENESS_NONE = 3;
|
||||
|
||||
MeatBase.ANGLE_NONE = 0;
|
||||
MeatBase.ANGLE_FRONT = 30;
|
||||
MeatBase.ANGLE_BACK = -30;
|
||||
|
||||
MeatBase.COOK_TIME_WELLDONE = 20;
|
||||
MeatBase.COOK_TIME_BURN = 400;
|
||||
MeatBase.COOK_TIME_WELLDONE = 20;
|
||||
MeatBase.COOK_TIME_BURN = 400;
|
||||
Reference in New Issue
Block a user