score multiplier

This commit is contained in:
garrettdreyfus 2014-05-26 13:04:23 -04:00
parent bca95619b3
commit 7fa3481bb3
3 changed files with 4 additions and 2 deletions

View file

@ -172,4 +172,4 @@ function findCenterOfBlocks(arr) {
y:trueCanvas.height/2 + Math.sin(avgAngle * (Math.PI / 180)) * avgDFH
}
}
}

View file

@ -32,5 +32,5 @@ function fadeUpAndOut(text){
}
function fadeOut(text){
text.opacity -= 0.01 ;
text.opacity -= 0.02;
}

View file

@ -69,6 +69,8 @@ function consolidateBlocks(clock,side,index){
if(now - clock.lastCombo < 5000 ){
clock.comboMultiplier += 1;
clock.lastCombo = now;
var coords = findCenterOfBlocks(deletedBlocks);
clock.texts.push(new Text(coords['x'],coords['y'],"x "+clock.comboMultiplier.toString(),"bold Lovelo 24px",deletedBlocks[0].color,fadeOut));
}
else{
clock.lastCombo = now;