I've been using a mechanical rotary encoder for my Asteroids game controller. The resolution it provides is pretty low. It's only got 20 steps which translates to 18 degrees per step.

In this project, I've created a high resolution magnetic rotary encoder using an AS5048A. To make this I cannibalised the mechanical rotary encoder and 3D printed a holder to hold everything together.

It works really well - I think it's sub 0.5 degrees accuracy and could be even better with a bit of averaging of samples.