Skip to content

Commit

Permalink
Fix rotation bug
Browse files Browse the repository at this point in the history
Prevents all pickups from rotating regardless of rotating pickup
flag. Bug introduced in previous commit.
  • Loading branch information
SubprimeMover authored and dpjudas committed Feb 17, 2024
1 parent f3f6fe7 commit b00ce7c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions SurrealEngine/UObject/UActor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -784,6 +784,15 @@ void UActor::TickFlying(float elapsed)

void UActor::TickRotating(float elapsed)
{
UInventory* inventory = TryCast<UInventory>(this);
if (inventory)
{
if (!inventory->bRotatingPickup())
{
return; // All pickups will rotate without this.
}
}

if (bRotateToDesired())
{
if (Rotation() != DesiredRotation())
Expand Down

0 comments on commit b00ce7c

Please sign in to comment.