So, I am trying to make it so the server can see the UserInputService's events for a player. Here is what I got.
local events = { 'DeviceAccelerationChanged'; 'DeviceGravityChanged'; 'DeviceRotationChanged'; 'GamepadConnected'; 'GamepadDisconnected'; 'InputBegan'; 'InputChanged'; 'InputEnded'; 'JumpRequest'; 'LastInputTypeChanged'; 'TextBoxFocusReleased'; 'TextBoxFocused'; 'TouchEnded'; 'TouchLongPress'; 'TouchMoved'; 'TouchPan'; 'TouchPinch'; 'TouchRotate'; 'TouchStarted'; 'TouchSwipe'; 'TouchTap'; 'TouchTapInWorld'; 'UserCFrameChanged'; 'WindowFocusReleased'; 'WindowFocused'; } for _, event in pairs(events) do print('Connecting event for '..event) userservice[event]:Connect(function(a, b, c, d, e) print('An event occured with UserInputService. Name : '..event..'. Data :["'..tostring(a)..'", "'..tostring(b)..'"'..tostring(c)..'", "'..tostring(d)..'"'..tostring(e)..'"]') user.Events[event]:FireServer(a, b. c, d, e) end) end
"userservice" is just UserInputService and user is the folder I put the events in. But, whenever I move my mouse, I get Players.YouWillNeverGuessMy.PlayerGui.Services:215: attempt to index local 'b' (a boolean value)
. This does not error if I fire it through the command bar. Any ideas? Thanks.
I think you added a period where you should have used a comma on line 32.
user.Events[event]:FireServer(a, b. c, d, e)
should be
user.Events[event]:FireServer(a, b, c, d, e)