Skip to content

Commit

Permalink
Update MoveObject.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
yaleksander authored and Wano-k committed Jul 24, 2024
1 parent 24a9e41 commit 8d67056
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/EventCommand/MoveObject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ class MoveObject extends Base {
Record<string, any>): Orientation | boolean
{
if (object) {
object.lookAt(Orientation.North);
object.lookAt((Orientation.North + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
return true;
}
return Orientation.North;
Expand All @@ -739,7 +739,7 @@ class MoveObject extends Base {
Record<string, any>): Orientation | boolean
{
if (object) {
object.lookAt(Orientation.South);
object.lookAt((Orientation.South + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
return true;
}
return Orientation.South;
Expand All @@ -756,7 +756,7 @@ class MoveObject extends Base {
Record<string, any>): Orientation | boolean
{
if (object) {
object.lookAt(Orientation.West);
object.lookAt((Orientation.West + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
return true;
}
return Orientation.West;
Expand All @@ -773,7 +773,7 @@ class MoveObject extends Base {
Record<string, any>): Orientation | boolean
{
if (object) {
object.lookAt(Orientation.East);
object.lookAt((Orientation.East + (this.isCameraOrientation ? Scene.Map.current.orientation : 0)) % 4);
return true;
}
return Orientation.East;
Expand Down Expand Up @@ -918,7 +918,7 @@ class MoveObject extends Base {
options.sid = object.currentStateInstance.speedID;
}
object.currentStateInstance.indexX = object.frame.value;
object.currentStateInstance.indexY = object.orientation;
object.currentStateInstance.indexY = object.orientationEye;
object.changeState();
}
return Orientation.None;
Expand Down Expand Up @@ -948,7 +948,7 @@ class MoveObject extends Base {
options.fid = object.currentStateInstance.frequencyID;
}
object.currentStateInstance.indexX = object.frame.value;
object.currentStateInstance.indexY = object.orientation;
object.currentStateInstance.indexY = object.orientationEye;
object.changeState();
}
return Orientation.None;
Expand Down

0 comments on commit 8d67056

Please sign in to comment.