i’m sending a table full of keybinds to the client, the tablename is supposed to be the enum and looks like this:
however the client can’t get the keycode by itself and instead adds “token” before the enum, and it’s no longer considered an enum which is a problem
I believe passing anything but primitive types (string, booleans, numbers, etc.) as keys create “tokens” like these. Put the keycode within the table itself instead of the index.
Yeah, it’s Roblox’s way of denoting custom userdata types as opposed to primitive value types.
I know this is solved, however you can name the key in your case “Q”
local keycodes = {}
keycodes.Q = {
Move = "Summon",
Cooldown = 1
}
Accessing it would look something like
local path = keycodes[Enum.KeyCode.Name]
if (path) then
print(path)
end