Skip to content

Commit 20c5c50

Browse files
committed
Applying some changes from PR #32 from Russo
1 parent 711dec7 commit 20c5c50

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

src/EventCommand/MoveObject.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -749,7 +749,7 @@ class MoveObject extends Base {
749749
parameters: Record<string, any>
750750
): Orientation | boolean {
751751
if (object) {
752-
object.lookAt((Orientation.North + (this.isCameraOrientation ? Scene.Map.current.orientation + 2 : 0)) % 4);
752+
object.lookAt((Orientation.North + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
753753
return true;
754754
}
755755
return Orientation.North;
@@ -768,7 +768,7 @@ class MoveObject extends Base {
768768
parameters: Record<string, any>
769769
): Orientation | boolean {
770770
if (object) {
771-
object.lookAt((Orientation.South + (this.isCameraOrientation ? Scene.Map.current.orientation + 2 : 0)) % 4);
771+
object.lookAt((Orientation.South + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
772772
return true;
773773
}
774774
return Orientation.South;
@@ -787,7 +787,7 @@ class MoveObject extends Base {
787787
parameters: Record<string, any>
788788
): Orientation | boolean {
789789
if (object) {
790-
object.lookAt((Orientation.West + (this.isCameraOrientation ? Scene.Map.current.orientation + 2 : 0)) % 4);
790+
object.lookAt((Orientation.West + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
791791
return true;
792792
}
793793
return Orientation.West;
@@ -806,7 +806,7 @@ class MoveObject extends Base {
806806
parameters: Record<string, any>
807807
): Orientation | boolean {
808808
if (object) {
809-
object.lookAt((Orientation.East + (this.isCameraOrientation ? Scene.Map.current.orientation + 2 : 0)) % 4);
809+
object.lookAt((Orientation.East + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
810810
return true;
811811
}
812812
return Orientation.East;

src/Scene/ChangeLanguage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ class ChangeLanguage extends Base {
231231
this.windowChoicesMain.onKeyPressed(key, this);
232232
if (Datas.Keyboards.checkActionMenu(key)) {
233233
this.action();
234-
} else if (Datas.Keyboards.checkCancelMenu) {
234+
} else if (Datas.Keyboards.checkCancelMenu(key)) {
235235
this.cancel();
236236
}
237237
break;

src/Scene/Map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1113,7 +1113,7 @@ class Map extends Base {
11131113
super.update();
11141114

11151115
// Update camera hiding
1116-
if (Datas.Systems.moveCameraOnBlockView.getValue()) {
1116+
if (Game.current !== null && Datas.Systems.moveCameraOnBlockView.getValue()) {
11171117
this.camera.forceNoHide = false;
11181118
this.camera.hidingDistance = -1;
11191119
let pointer = Manager.GL.toScreenPosition(

0 commit comments

Comments
 (0)