gemercheung 3 年之前
父节点
当前提交
87563d5cd2
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      src/scene/scene.service.ts

+ 3 - 2
src/scene/scene.service.ts

@@ -882,6 +882,7 @@ export class SceneService implements OnModuleInit, OnModuleDestroy {
     if (hasPush.done) {
       this.isJoystickHasStream = true;
       console.log('joystick-hasPush', hasPush);
+      this.frameCnt.next(hasPush.frame);
       if (this.isJoystickHasStream) {
         await this.sleep(20);
       }
@@ -897,7 +898,7 @@ export class SceneService implements OnModuleInit, OnModuleDestroy {
       //   //const lastReply = JSON.stringify(joystickRes);
       //   //this.moveService.updateUser(userId, breakPointId, lastReply);
       // }
-      this.frameCnt.next(hasPush.frame);
+
       /**
        * 这个complementFrame 具体说明 pools 是complementFrame这个返回值
        * 1. 第一次要在200ms后调用, 如有值(pools) 就要返回主流程执行,但设置hasJoystickFocusRepeat为true
@@ -927,7 +928,7 @@ export class SceneService implements OnModuleInit, OnModuleDestroy {
           this.testTimer = 0;
           //this.handleJoystickStop(hasPush);
           this.globalOptLock = false;
-          this.resumeStream();
+          // this.resumeStream();
         }
       } else {
         this.handleJoystickStop(hasPush);