keyCascader is a handy solution for dealing with the ESC key on desktops, and the Android back button (although it can be used with any key or button input).
Typically, you need the behavior of these keys to cascade through a number of different elements in your UI, but it's a tedious pain to handle this cleanly. I got tired of custom writing this functionality with every game I made, so I made keyCascader as a general solution for any key you want to cascade through a prioritized list of GameObjects.
Handle any key or button cascades:
- Android Back Button on mobile
- ESC/ENTER Button on desktop
- Perfect for letting your user quickly navigate past nested menus and popups
- No coding required, just two components!
keyCascader has been battle tested on half a dozen shipped mobile and desktop games. Through these iterations, it has become extremely simple and streamlined and very easy to use. If it saves you a couple of hours or days of coding and testing, please leave a five star rating to help other developers find it!