diff --git a/Source/Engine/Level/Actor.cs b/Source/Engine/Level/Actor.cs
index 661b350cb..dbe8a89b5 100644
--- a/Source/Engine/Level/Actor.cs
+++ b/Source/Engine/Level/Actor.cs
@@ -364,13 +364,20 @@ namespace FlaxEngine
/// The point (world-space).
/// The axis (normalized).
/// The angle (in degrees).
- public void RotateAround(Vector3 point, Vector3 axis, float angle)
+ /// /// Whether to orient the actor the same amount as rotation.
+ public void RotateAround(Vector3 point, Vector3 axis, float angle, bool orientActor = true)
{
var transform = Transform;
var q = Quaternion.RotationAxis(axis, angle * Mathf.DegreesToRadians);
- var dif = (transform.Translation - point) * q;
- transform.Translation = point + dif;
- transform.Orientation = q;
+ if (Vector3.NearEqual(point, transform.Translation) && orientActor)
+ transform.Orientation *= q;
+ else
+ {
+ var dif = (transform.Translation - point) * q;
+ transform.Translation = point + dif;
+ if (orientActor)
+ transform.Orientation *= q;
+ }
Transform = transform;
}