Commit 0563171e authored by 李维's avatar 李维

add restart function

parent c847dc3c
...@@ -134,7 +134,9 @@ export class PlayComponent implements OnInit, OnDestroy { ...@@ -134,7 +134,9 @@ export class PlayComponent implements OnInit, OnDestroy {
// 屏幕尺寸变化后执行 // 屏幕尺寸变化后执行
handleScreenResize(){ handleScreenResize(){
this.initSystem();
this.update();
this.restartGame()
} }
// 映射预加载图片[网路]资源 返回包含图片路径的数组 // 映射预加载图片[网路]资源 返回包含图片路径的数组
...@@ -170,6 +172,7 @@ export class PlayComponent implements OnInit, OnDestroy { ...@@ -170,6 +172,7 @@ export class PlayComponent implements OnInit, OnDestroy {
restartGame() { restartGame() {
this.cleanGameVar() this.cleanGameVar()
this.initGame() this.initGame()
this.switchAnswerSheetButton("start")
} }
......
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