# How to make the players Z rotation into a varible??

**URL:** <https://forums.unrealengine.com/t/how-to-make-the-players-z-rotation-into-a-varible/1790699>\
**Category:** Verse\
**Tags:** unreal-editor-for-fortnite, fortnite\
**Created:** [April 6, 2024, 10:54am UTC](https://forums.unrealengine.com/t/how-to-make-the-players-z-rotation-into-a-varible/1790699 "2024-04-06T10:54:40Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kelan](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Kelan](https://forums.unrealengine.com/u/Kelan)\
**Post date:** [April 6, 2024, 10:54am UTC](https://forums.unrealengine.com/t/how-to-make-the-players-z-rotation-into-a-varible/1790699/1 "2024-04-06T10:54:40Z")

</div>

How to make the players Z rotation into a varible??

---

<div class="post-metadata">

**Author:** ![Astrotronic](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/astrotronic/32/1194566_2.png) [@Astrotronic](https://forums.unrealengine.com/u/Astrotronic)\
**Post date:** [April 8, 2024, 10:50pm UTC](https://forums.unrealengine.com/t/how-to-make-the-players-z-rotation-into-a-varible/1790699/2 "2024-04-08T22:50:55Z")

</div>

Hi Kelan,

I think you could probably base this logic on what is returned when you call ‘[GetViewRotation](https://dev.epicgames.com/documentation/en-us/uefn/verse-api/fortnitedotcom/characters/fort_character/getviewrotation)’ on a fort\_character.

Getting just the Z out of the rotation struct is an interesting problem though. Ultimately you might not want to break it, but I am seeing a ‘[ToString](https://dev.epicgames.com/documentation/en-us/uefn/verse-api/unrealenginedotcom/temporary/spatialmath)’ function that could be used on rotations.

Hope that helps.
