Commit 3ea9bc86 authored by LoveEevee's avatar LoveEevee

Fade in when hitting drumrolls and balloons

parent 6d770e7b
......@@ -258,6 +258,7 @@ class Game{
}
this.globalScore.drumroll ++
this.globalScore.points += score
this.view.setDarkBg(false)
}
checkDrumroll(circle, keysKa){
var ms = this.elapsedTime
......@@ -283,6 +284,7 @@ class Game{
this.view.drumroll.push(circleAnim)
this.globalScore.drumroll++
this.globalScore.points += score * (dai ? 2 : 1)
this.view.setDarkBg(false)
}
whenLastCirclePlayed(){
var ms = this.elapsedTime
......
......@@ -1478,10 +1478,12 @@
explosion.setAnimation(false)
})
}
var miss = score === 0
this.setDarkBg(score === 0)
}else{
var miss = true
this.setDarkBg(true)
}
}
setDarkBg(miss){
if(!miss && this.darkDonBg){
this.darkDonBg = false
this.donBg.classList.remove("donbg-dark")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment