# How to rotate a pawn without axis constrains?

**URL:** <https://forums.unrealengine.com/t/how-to-rotate-a-pawn-without-axis-constrains/462472>\
**Category:** Community & Industry Discussion\
**Tags:** rotation, limitation, unreal-engine, rotate, pawn, question\
**Created:** [March 15, 2020, 9:48am UTC](https://forums.unrealengine.com/t/how-to-rotate-a-pawn-without-axis-constrains/462472 "2020-03-15T09:48:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![hajnis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@hajnis](https://forums.unrealengine.com/u/hajnis)\
**Post date:** [March 15, 2020, 9:48am UTC](https://forums.unrealengine.com/t/how-to-rotate-a-pawn-without-axis-constrains/462472/1 "2020-03-15T09:48:06Z")

</div>

Hello there,  
I am trying to create handling for spaceship pawn, But got stuck in axis constrains in Roll and Pitch axis.  
I tried AddControllerYawInput(), AddControllerPitchInput(), GetController()-\>SetControlRotation() etc…

Method for roll rotation:

```
void AMyPawn::RotateRightHorizontal(float Amount)
{

    FRotator actorRotation = GetControlRotation();

    FQuat rotationDelta = FQuat::MakeFromEuler(FVector(Amount, 0.f, 0.f));
    FQuat newRotation = actorRotation.Quaternion() * FQuat::MakeFromEuler(FVector(Amount, 0.f, 0.f));
    newRotation.Normalize();

    GetController()->SetControlRotation(newRotation.Rotator()); // works only in angle 90 to -90 
    GetController()->AddActorLocalRotation(rotationDelta); // pruduce error

    //AddControllerRollInput(Amount); // works only in angle 90 to -90 

}

```

All this seems to be stuck on -90, 90 constrains. Why is that? What is blocking it? Is it because this methods updates my actor in world space?

I also tried GetController()-\>AddActorLocalRotation() but this produce an error:

```
Error (active)	E0265	function "AController::AddActorLocalRotation(const FQuat &DeltaRotation, bool bSweep = false, FHitResult *OutSweepHitResult = (FHitResult *)nullptr, ETeleportType Teleport = ETeleportType::None)" (declared at line 390 of "D:\Epic Games\games\UE_4.24\Engine\Source\Runtime\Engine\Classes\GameFramework\Controller.h") is inaccessible	MyProject	D:\myWork\PixelArtGame\MyProject\Source\MyProject\MyPawn.cpp	92	

```

Am I getting something wrong or what is going on? Or how to achieve rotation “freedom” in all axis?

Thanks for answers.

---

<div class="post-metadata">

**Author:** ![ugmoe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ugmoe](https://forums.unrealengine.com/u/ugmoe)\
**Post date:** [March 15, 2020, 10:12pm UTC](https://forums.unrealengine.com/t/how-to-rotate-a-pawn-without-axis-constrains/462472/2 "2020-03-15T22:12:00Z")

</div>

I’m still new to all this, but I think when you normalize something, it clamps the output. So I think that ‘normalize’ part is whats causing the constraints
