Commit 27cd4d2f authored by Tt's avatar Tt

fix: 在nextPage中添加游戏结束条件检查

parent b8e56880
......@@ -521,6 +521,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
nextPage() {
// 切换到下一页
Game.getIns().addPage();
// 判断是否已经是最后一题,如果是则触发游戏结束
if (Game.getIns().isOver) {
this.gameOver();
return;
}
this.showPage();
}
......
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