gemercheung пре 3 година
родитељ
комит
52f1b77ef0
1 измењених фајлова са 4 додато и 3 уклоњено
  1. 4 3
      src/scene/scene.service.ts

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

@@ -882,10 +882,11 @@ export class SceneService implements OnModuleInit, OnModuleDestroy {
     if (hasPush.done) {
     if (hasPush.done) {
       this.isJoystickHasStream = true;
       this.isJoystickHasStream = true;
       console.log('joystick-hasPush', hasPush);
       console.log('joystick-hasPush', hasPush);
+      // if (this.isJoystickHasStream) {
+      //   await this.sleep(20);
+      // }
+      await this.sleep(20);
       this.frameCnt.next(hasPush.frame);
       this.frameCnt.next(hasPush.frame);
-      if (this.isJoystickHasStream) {
-        await this.sleep(20);
-      }
       this.moveService.sendingFrameForJoystick = false;
       this.moveService.sendingFrameForJoystick = false;
       const data = joystickRes as StreamReplyType;
       const data = joystickRes as StreamReplyType;
       console.log('handlejoystick-isIDR:' + data.isIDR);
       console.log('handlejoystick-isIDR:' + data.isIDR);