Changing the Mac Studio Command Keycode: Control vs Meta

Hey developers,

In an effort to make Roblox Studio more consistent with the client, we are planning on making the keycode associated with the command keys on Mac use Enum.KeyCode.LeftMeta and Enum.KeyCode.RightMeta, which is what the client currently does. Roblox Studio currently uses Enum.KeyCode.LeftControl.

This will not affect Windows users.

If you are using UserInputService or ContextActionService for user input in a plugin, and are specifically checking for Enum.KeyCode.LeftControl, this may change the behavior when a user presses the command key on a Mac.

We would like to reach out to communicate this in case it will have an impact on any plugin support. Please let us know of any concerns.

Thanks!

100 Likes

This topic was automatically opened after 10 minutes.

As a Mac and Windows user, these changes will be very helpful and will allow for a more efficient and easier environment when I’m developing on the go. Thank you so much!

One question: If something were to be affected by this change, what error in the output would show up? I would like to know just incase.

8 Likes

This is a good heads up, but what is the date of this change occurring? It’d be good to code in an automatic transition ahead of time instead of getting surprised by errors on mac devices on an unexpected time.

Also, it’d be great if the DevHub’s Enum.KeyCode reference is updated with this info. Currently, although self-explanatory without descriptions for the other keys, it would be confusing to returning users who would expect to use Left/Right Control instead of Meta. A short little reminder there would be nice.

4 Likes

I believe what they are referring to in this form is that on Roblox Studio, while testing, it provides a different KeyCode than if you were on the client, so they are fixing it, and making it work properly for testing in Roblox Studio as the client already works properly.

7 Likes

Always good to have things consistent, especially when testing in Roblox Studio. Never knew about that issue being a thing, but still good to know. Thank you.

2 Likes

Can you elaborate on this? Does this mean the Mac’s command key was previously mapped to Enum.KeyCode.LeftControl, but will instead map to Enum.KeyCode.LeftMeta, and likewise with Enum.KeyCode.RightControl and Enum.KeyCode.RightMeta?

5 Likes

So this basically just changes the input?

4 Likes

Will this alter some of the default Roblox Studio keyboard shortcuts for Apple devices that begin with the command key , or is it intended to only make modifications to the Enum.KeyCode that plugins could listen for through UserInputService & ContextActionService?

I presume it’s the latter, but I’d just like to be sure.

4 Likes

I personally don’t think it will lead to any keyboard shortcut changes and instead just the name used in the working of Roblox. To you it will still be the command key and everything will function exactly the same, but in the working of Roblox it will be just considered Control.

How I know Roblox does stuff is that LeftMeta and RightMeta will deprecate but still be functional (like mostly all deprecated functions and events). So plugins, functions, events, etc. that use LeftMeta and RightMeta inputs will not immediately break when this change is pushed.

So, there will be no errors for anyone on any device (on any game). Roblox usually always approaches deletion and creation of functions/events like this and will continue like this. It’s so older games on Roblox don’t immediately burn down due to a simple update (minus really required ones like FilteringEnabled).

3 Likes

The Mac’s command key (both left and right) was previously mapped to Enum.KeyCode.LeftControl. They now will map to Enum.KeyCode.LeftMeta and Enum.KeyCode.RightMeta.

4 Likes

You presume correctly, this will not alter any keyboard inputs in Roblox Studio. This is just a change to make scripts run in Studio behave like the client. Users shouldn’t see any difference.

3 Likes

Just out of curiosity, is the meta key the Start key on Windows? I know they’re in pretty much the same place, was just wondering if this is the case or not.

4 Likes

If you are going to make a change like this, I request plugins get access to GetPlatform, since this will allow plugin developers to correctly tailor their user input.

While Windows does not have the Meta key (or i seriously hope it doesn’t). This is a feature we need if Studio were to continue being different between Windows and Mac, as this update seems to be doing.

5 Likes

Mac Studio is widely acknowledged to be a horrid experience for developers, full of memory leaks and other bugs. I know from painful experience that these have been left unfixed for years and have transitioned to Windows for Roblox development.

Are you guys going to start taking Mac more seriously?

4 Likes

I cannot emphasize that enough. It’s a huge problem that isn’t really being acknowledged or solved. The same problems arent even limited to Roblox Studio though. Roblox doesn’t take advantage of dedicated GPUs in macOS, not to mention that memory leaks are very much commonplace.

That doesn’t include the many other issues though… :frowning:

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.