Elusive UserInputService bug finally tracked down

Please fix this fast, it’s been an issue that plagues my game, and I finally got some info on it:

error text: “Invalid value for enum KeyCode”
error link: http://gyazo.com/40b19c1b1ff75eca78518cdcc5dfeade

what caused the error: mac user typing ‘!’, in chat or out of, no other character seems to trigger it

script line that faults:

function Input(InputObject,Down)
	if InputObject.UserInputType == Enum.UserInputType.Keyboard then
		if InputObject.KeyCode == Enum.KeyCode.LeftShift then -- this line here
		end
	end
end
UserInputService.InputBegan:connect(function(InputObject) Input(InputObject,true) end)
UserInputService.InputEnded:connect(function(InputObject) Input(InputObject,false) end)

Can confirm this happens. I’m on Mac and typed in “!”

Can I have any information from a mod on anything about this bug? like workarounds, or a time when it’s fixed, or even a notice it’s being worked on?

Ah that is what is messing me up, yea this definitely needs to be patched.

Does this only happen on Macs?

pretty sure it’s mac only, although it has been reported on non-macs, I suspect the people who reported it may have been not intelligent enough to know they were on a mac, as I deal with these kind of people all the time, reporting impossible bugs out of their own sheer stupidity.

Fix already, or tell me it’s being worked on, or it’s in the next update.

Bump, how’s it going? is this being worked on, I want to tell my users something on it.

Oh, so that’s what it meant. Always wondering what that Invalid value KeyCode thing was.

There’s also another mac related keycode glitch.

If you hold shift and press X, the X input does not register until you release the shift key. This is only the case for the “X” key, everything other key works while holding shift, so I assume it is probably related to some sort of mac command with shift X.

this bug is still a thing 0.0

I ran in to this bug like 3 months ago if that helps anything, I thought I posted about it here
EDIT: found it Documentation - Roblox Creator Hub

this is the date of the taking of this screen shot, 8/22/14 12:30 AM.

Also this was Mac only related bug. Could not reproduce on Windows.

Also I can confirm the lito’s bug, except It happens to me when I’m holding down Z and try to hit X, although hitting X again a second time sometimes works. it’s got to be a Mac Key Binding error.

EDIT: although I am no long able to reproduce the crash with the ’ key I strictly remember when it was broken back then I fixed the issue by removing this line of code:

keyinputs.APOSTR.Changed:connect(function()
	-- non important stuff
end)

where APOSTR is set by this code (this was not removed)

mouse.KeyDown:connect(function(key)
	-- . . . 
	if key == "'" then
		keyinputs.APOSTR.Value = true
	end
end)

mouse.KeyUp:connect(function(key)
	-- . . . 
	if key == "'" then
		keyinputs.APOSTR.Value = false
	end
end)

This line of code was also present:

IS.InputBegan:connect(function(input)
	if input.KeyCode == Enum.KeyCode.Slash then
		-- non important stuff
	elseif input.KeyCode == Enum.KeyCode.Quote then
		-- non important stuff
	elseif input.KeyCode == Enum.KeyCode.Tab then
		-- non important stuff
	end
end)