i want to make a universal dictionary so i can send data from the server to the client (for example what gun the player is using etc.)
currently i am using a modulescript, but the problem is that whenever i update the data inside of it on the server, it stays the same on the client. i have also tried _G, but the client and the server have a separate _G so that didnt work either.
Modulescripts do not send data between the client and server. You need to use remotes for that.
i just want to send the data from the server to the client though. the only thing that comes to my mind is creating a folder that would act like a dictionary, but i feel like that wouldnt be the most optimal solution
Thats too broad as theres lots of ways to do that and the best way will depend on what exactly that data is. Its possible to make a system that generically keeps a dictionary across the client and server, but it will be unbearable to use and have performance issues very early on.