Add drumroll count to the scoreboard
This commit is contained in:
parent
749e657027
commit
41cc584295
@ -12,6 +12,7 @@ class Game{
|
|||||||
good: 0,
|
good: 0,
|
||||||
fail: 0,
|
fail: 0,
|
||||||
maxCombo: 0,
|
maxCombo: 0,
|
||||||
|
drumroll: 0,
|
||||||
hp: 0,
|
hp: 0,
|
||||||
song: selectedSong.title
|
song: selectedSong.title
|
||||||
}
|
}
|
||||||
@ -196,6 +197,7 @@ class Game{
|
|||||||
var score = 300
|
var score = 300
|
||||||
circle.hit()
|
circle.hit()
|
||||||
}
|
}
|
||||||
|
this.globalScore.drumroll ++
|
||||||
this.globalScore.points += score
|
this.globalScore.points += score
|
||||||
}
|
}
|
||||||
checkDrumroll(circle){
|
checkDrumroll(circle){
|
||||||
@ -211,6 +213,7 @@ class Game{
|
|||||||
circleAnim.played(score)
|
circleAnim.played(score)
|
||||||
circleAnim.animate()
|
circleAnim.animate()
|
||||||
this.controller.view.drumroll.push(circleAnim)
|
this.controller.view.drumroll.push(circleAnim)
|
||||||
|
this.globalScore.drumroll ++
|
||||||
this.globalScore.points += score
|
this.globalScore.points += score
|
||||||
}
|
}
|
||||||
whenLastCirclePlayed(){
|
whenLastCirclePlayed(){
|
||||||
|
@ -34,6 +34,7 @@ class Scoresheet{
|
|||||||
this.altText(this.elem("nb-good", scoreCont), score.good)
|
this.altText(this.elem("nb-good", scoreCont), score.good)
|
||||||
this.altText(this.elem("nb-fail", scoreCont), score.fail)
|
this.altText(this.elem("nb-fail", scoreCont), score.fail)
|
||||||
this.altText(this.elem("max-combo", scoreCont), score.maxCombo)
|
this.altText(this.elem("max-combo", scoreCont), score.maxCombo)
|
||||||
|
this.altText(this.elem("nb-drumroll", scoreCont), score.drumroll)
|
||||||
|
|
||||||
addEventListener("resize", () => {
|
addEventListener("resize", () => {
|
||||||
this.positionning(scoreCont)
|
this.positionning(scoreCont)
|
||||||
|
@ -21,7 +21,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<th class="header-good stroke-sub" alt="可">可</th>
|
<th class="header-good stroke-sub" alt="可">可</th>
|
||||||
<td class="value nb-good stroke-sub"></td>
|
<td class="value nb-good stroke-sub"></td>
|
||||||
<!--<td class="stroke-sub" alt="連打数">連打数</td><td class="value nb-rendasu stroke-sub"></td>-->
|
<td class="stroke-sub" alt="連打数">連打数</td><td class="value nb-drumroll stroke-sub"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th class="header-fail stroke-sub" alt="不可">不可</th>
|
<th class="header-fail stroke-sub" alt="不可">不可</th>
|
||||||
|
Loading…
Reference in New Issue
Block a user