How To: Amazon Fire Stick

I do not see a lot of Fire Stick, so I wanted to share a quick video and steps on how to support the Fire Stick:

Video:

Steps:

  1. Go to your Build Settings
  2. Visit Controller Input with Unity (Fire TV) | Amazon Fire TV
    Input Settings:
    -Go to Input in Unity
    -Find Horizontal
    -Make sure its named Horizontal
    -Negative Button = left
    -Positive Button = right
    -Alt Negative Button = a
    -Alt Positive Button = d
    -Gravity = 3
    -Dead = 0.001
    -Sensitivity = 3
    -Type = Joystick Axis (I this can be set to keyboard mouse but dont quote me on it)
    -Axis = 5th Axis (Joystick)
    -Joy Num = Get motion from all joysticks
    Refer to the Amazon Document Link listed above if this setup dos not work
  3. Code Setup
private void Update()
    {
        //direction = new Vector2(Input.GetAxisRaw("Horizontal"), Input.GetAxisRaw("Vertical")) * Time.deltaTime;

        foreach (KeyCode kcode in Enum.GetValues(typeof(KeyCode)))
        {
            //Keypress Method
            if (Input.GetKeyDown(kcode))
            {
                switch (kcode)
                {
                    case KeyCode.Joystick1Button0:
                        Click_Bug();
                        break;
                    case KeyCode.LeftArrow:
                        Click_Random_Bug();
                        break;
                    case KeyCode.RightArrow:
                        Click_Random_Bug();
                        break;
                    case KeyCode.Escape:
                        Click_Home();
                        break;
                    case KeyCode.Menu:
                        Click_Home();
                        break;
                }
            }
        }
    }

My Code snippet is for a simple game I made. Use it as a reference but not a literal guide.

  1. In your Build Settings Select “Player”
    -Other Settings
    -Choose API level 22 as minim
    -Check Android TV Comparability
    -Works with D Pad
  2. Other Documentation/References:
    -Redirect | None

I hope this helps everyone who wants to build for Fire Stick. If I missed a step or something is wrong please post a reply.

1 Like

Just wanted to share with everyone. I got my app approved finally and was able to test. Yes this config seems to work for Fire Stick. I hope to see everyone’s apps on the fire stick soon.

Thanks for the tutorial! I will test it right now with my game that now has controller support!

I have to manually set the devices on Amazon Fire TV and Automotive. Did this happen to you too?

Well I just sent it for approval. Let’s see what happens! =)

It was approved and it’s working! Thanks!

Fishwitch Halloween:Amazon.com:Appstore for Android

Ótimo artigo! Fazia tempo que procurava algo tão esclarecedor. O Amazon Fire Stick é realmente show!

Just a tip, ReWired has great support for the Fire Stick Control Remote and GamePads.

1 Like