More customisation options for ContextActionService Buttons

What we have at the moment?

Currently, we have a wonderful service called ContextActionService, that allows you to bind actions to not only keypresses but also from mobile buttons. This is incredibly useful as I can cut down on the number of lines I have in my client-side scripts.

The issue

Currently, whenever a new button is created by CAS, it utilises a default circle button backdrop and not much room to customise it natively. Right now, we can customise things such as the text, description, image and position, but if we want to customise elements such as the Size or the backdrop image of a button, we have to physically use :GetButton() and even when we’ve made the changes we want, if we have to unbind the button temporarily, we’d need to redo all the changes we originally made when we rebind the button.

It can be quite messy and strenuous to constantly do this, and its why in most of my projects, I utilise native ImageButtons and UserInputService separately for player input over CAS. However, knowing the value of a context based system that can perform the same action but with fewer lines of code, I figured that if we were granted a method to set a template style for all CAS buttons to adopt, rather than having to :GetButton() each time and use 5 or 7 more lines of code to reach my aesthetic expectations, I might use this cool service more.

I’ve also noticed that the actual design of the current backdrop image looks kind of legacy in comparison to the newer jump button, and shares a similar appearance to the old thumbstick colour scheme, so having a system where I can control the aesthetics of my CAS buttons will allow me to maintain consistency of UI design throughout my game, while also cutting down on the amount of unnecessary code I’d need to put in overall.

21 Likes

Please can this be revisited, being able to customize the style of context action buttons been requested so many times over the years. It doesn’t make sense that for years the button styling remains hardcoded despite feedback in this and many other threads.
We have to add a whole bunch of listeners to adjust the styling to match our projects if we want to actually make use of the context service mobile buttons, which always try to reset it’s images to the hardcoded styling, which clashes with other roblox UI elements.

1 Like