刘向辉 3 years ago
parent
commit
dfc8c95a95
  1. 6
      src/app/pages/plan/plan.component.ts

6
src/app/pages/plan/plan.component.ts

@ -83,7 +83,7 @@ export class PlanComponent implements OnInit {
}) })
//监听 delete键盘事件 //监听 delete键盘事件
this.game.scene.onBeforeRenderObservable.add(() => { this.game.scene.onBeforeRenderObservable.add(() => {
PlanComponent.instance.ngAfterViewCheckedA(); PlanComponent.instance.onUpdate();
}) })
} }
@ -130,9 +130,9 @@ export class PlanComponent implements OnInit {
} }
/** /**
* *
*/ */
ngAfterViewCheckedA() { onUpdate() {
let currentTime = new Date().getTime(); let currentTime = new Date().getTime();
let space = currentTime - this.lasteUpdateTime; let space = currentTime - this.lasteUpdateTime;
if (space < this.c_frameSpace) { if (space < this.c_frameSpace) {

Loading…
Cancel
Save