# How to move independent of rotation?

**URL:** <https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [December 3, 2015, 12:51pm UTC](https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398 "2015-12-03T12:51:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_277c86b9](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_277c86b9](https://forums.unrealengine.com/u/anonymous_user_277c86b9)\
**Post date:** [December 3, 2015, 12:51pm UTC](https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398/1 "2015-12-03T12:51:28Z")

</div>

Hi . these are functions to move and rotate but my character moves to direction which it faces.  
I wand movement to be independent of rotation. how can id fix it. I am trying to do the `TwinStickShooter` tutorial series in c++.

```
void AHeroCharacter::MoveUp(float Value)
{
	if ((Value != 0.0f))
	{
		
		AddMovementInput(GetActorForwardVector(), Value);
	}

}
void AHeroCharacter::MoveRight(float Value)
{
	if ((Value != 0.0f))
	{

		AddMovementInput(GetActorRightVector(), Value);
	}

}

void AHeroCharacter::lookUp(float Value)
{
	AddControllerYawInput(Value * 40 * GetWorld()->GetDeltaSeconds());
}

void AHeroCharacter::LookRight(float Value)
{
	AddControllerYawInput(Value * 40 * GetWorld()->GetDeltaSeconds());
}

```

---

<div class="post-metadata">

**Author:** ![Mhousse1247](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mhousse1247](https://forums.unrealengine.com/u/Mhousse1247)\
**Post date:** [December 3, 2015, 1:01pm UTC](https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398/2 "2015-12-03T13:01:33Z")

</div>

You can use FVector::RightVector & FVector::ForwardVector to have a movement independent of rotation

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_277c86b9](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_277c86b9](https://forums.unrealengine.com/u/anonymous_user_277c86b9)\
**Post date:** [December 3, 2015, 1:11pm UTC](https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398/3 "2015-12-03T13:11:50Z")

</div>

How? please help me more

---

<div class="post-metadata">

**Author:** ![Mhousse1247](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mhousse1247](https://forums.unrealengine.com/u/Mhousse1247)\
**Post date:** [December 3, 2015, 1:15pm UTC](https://forums.unrealengine.com/t/how-to-move-independent-of-rotation/340398/4 "2015-12-03T13:15:14Z")

</div>

Change :

GetActorForwardVector() to FVector::ForwardVector

GetActorRightVector() to FVector::RightVector
