So im getting this error, and as i see script can’t see the things under key 5?
This is what on line 67. I want to update do function UpdateKeybinds and also give it a dictionary with all keybinds, but it gives an error.
As you can see on screenshot 1 under key 5 is table with all keybinds and to print it i did: print(game.HttpService:JSONEncode(data))
But when i try to get only key 5 it gives error. I also tryed doing any other things with key 5 (like printing only it/other functions) but this still gave an error. What im doing wrong?
This is list of functions that i do when data changing.
When client got data from server i hold it under variable called “data”
and do all update functions:
for a, b in pairs(data) do
local f = DataChangedEvents[a]
if f then
spawn(f)
end
end
But it gives an error when i test it intantly when this function happens. have no idea why
So according to error, you’re trying to call a nil value as a function so looking at the line that caused the error, it means that GuiService:UpdateKeybinds doesn’t exist.
oh nevermind this wasn’t working since :UpdateKeybinds() was inside another function. I put it there to make it easier to change variables inside that parent function. I put it outside and now it works