Enum.KeyCode.KeypadEnter only works in studio

Hello people,

I have made a LocalScript which is inside of Starterplayerscripts.

local UserInputService = game:GetService("UserInputService")
local val = 0


UserInputService.InputEnded:Connect(function(input)
	if input.KeyCode == Enum.KeyCode.KeypadZero then
		val = 0
		print(game.Players.LocalPlayer.Name.." pressed 0")
	elseif input.KeyCode == Enum.KeyCode.KeypadOne then
		val = 1
		print(game.Players.LocalPlayer.Name.." pressed 1")
	elseif input.KeyCode == Enum.KeyCode.KeypadTwo then
		val = 2
		print(game.Players.LocalPlayer.Name.." pressed 2")
	elseif input.KeyCode == Enum.KeyCode.KeypadThree then
		val = 3
		print(game.Players.LocalPlayer.Name.." pressed 3")
	elseif input.KeyCode == Enum.KeyCode.KeypadFour then
		val = 4
		print(game.Players.LocalPlayer.Name.." pressed 4")
	elseif input.KeyCode == Enum.KeyCode.KeypadFive then
		val = 5
		print(game.Players.LocalPlayer.Name.." pressed 5")
	elseif input.KeyCode == Enum.KeyCode.KeypadEnter then
		print(game.Players.LocalPlayer.Name.." pressed enter")
		local remevent = game:GetService("ReplicatedStorage"):FindFirstChild("JokeOver") --game.Players.LocalPlayer.Name
		if remevent then
			print("remevent found")
			remevent:FireServer(val)
		end
		
	end
end)

All these prints works perfectly fine in studio testing
However in the real game, the KeypadEnter one does not work anymore and the event does not fire either.
(Yes, i am talking about KeypadEnter, not the Return key.)

I hope that anyone can tell me why that happens.