How to get DPad values in Unity TVOS

Struggled some time to get the dpad values and the delta touch positions in my Unity TVOS project. Its kind of strange to set it up but it works.

In the unity scripting reference you can find this value for this


and my thought was to call this in Awake or Start but that was exactly my misconception.

To get it working you have to call it in update just before you read the values like this:

public Dpad DpadDir = Dpad.none;
public enum Dpad { none, left, right, up, down };

void Update()
if (Input.touches[0].phase == TouchPhase.Began)
UnityEngine.Apple.TV.Remote.reportAbsoluteDpadValues = true;
float padLR = Input.GetAxisRaw("Horizontal");
float padUD = Input.GetAxisRaw("Vertical");
if (Mathf.Abs(padUD) + Mathf.Abs(padLR) > 0.5f)
//filter input to not get like up and left at the same time
if (Mathf.Abs(padLR) > Mathf.Abs(padUD))
if (padLR > 0.5f)
this.DpadDir = Dpad.right;
this.DpadDir = Dpad.left;
if (padUD > 0.5f)
this.DpadDir = Dpad.up;
this.DpadDir = Dpad.down;

Hope this helps you in your future or current projects!


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: