so basily i have a keybind systum i just need help with saving all you guys need to do is tell me how to use datastores to thigs on the client and have it come up with a random string to i identify a specific bind that other bids cant overright.
You will need to create a datastore function that saves your table of key binds the player has with can be done with the datastore with only excepts certain values, and it would be a big mess to save them all as different values in a stroke of code so you’d have to use
HttpService:JsonEncode(table)
so get a somewhat working prototype
( i don’t know if you still need it but there ya go! )
I don’t see why you’ve arrived at generating a random string to identify a key-bind. Key-bindings are actions associated with keys-strokes, and there is a finite, constant set of actions. You need only store what key-stroke is set to what action. This can be represented as a dictionary which maps the action name to the value of the KeyCode enum (not to be confused with the enum itself). During the deserialization stage, the KeyCode
enum can be reproduced with Enum:FromValue.
To ensure the key-bindings can be saved, the server must have its own copy of the client’s key-bind settings. This can be cached as the settings are downloaded from the data-store, and the cache can be updated each time a key-binding is changed. The server simply saves the cache. The client requests the cache when it’s ready via a RemoteFunction, and notifies the server of key-bind changes through a RemoteEvent
bit late but il try thx
word limmet