调整核心玩法细节表现
This commit is contained in:
@@ -30,8 +30,6 @@ export class DOBlock {
|
||||
this.data.show = show
|
||||
if (show == this.get_correct())
|
||||
this.checked = true
|
||||
if (this.get_checked() || show == 0)
|
||||
this.clean_notes()//正确或者擦除
|
||||
StorageManager.getInstance().onChanged()
|
||||
}
|
||||
|
||||
@@ -46,14 +44,18 @@ export class DOBlock {
|
||||
public get_notes(): Array<number> {
|
||||
return this.data.notes
|
||||
}
|
||||
public add_note(noteNumber: number): boolean {
|
||||
var b = false
|
||||
public add_note(noteNumber: number): void {
|
||||
if (this.data.notes.indexOf(noteNumber) < 0) {
|
||||
this.data.notes.push(noteNumber)
|
||||
StorageManager.getInstance().onChanged()
|
||||
b = true
|
||||
}
|
||||
return b
|
||||
}
|
||||
public remove_note(noteNumber: number): void {
|
||||
var find = this.data.notes.indexOf(noteNumber)
|
||||
if (find >= 0) {
|
||||
this.data.notes.splice(find, 1)
|
||||
StorageManager.getInstance().onChanged()
|
||||
}
|
||||
}
|
||||
public clean_notes(): void {
|
||||
if (this.data.notes.length > 0) {
|
||||
|
||||
Reference in New Issue
Block a user