Basically what I have is a module script, that sets up the server side remote handlers. Inside the module script is a local script, which is immediately parented to starter character scripts as soon as the module script runs. The module script also contains the tool which is returned to a main script which invokes the module via asset ID. The main script then allocates the tool to players that should have it based on the datastore. This enables each individual tool to be updated as needed and all changes will be instantly reflected across all maps, without needing to publish any new place versions. How would you rate my setup?
2 Likes
Sounds like a dictionary filing tool AssetIDs against a datastore save, neat
Is the client script the one invoking the server to give them tools?
The client does not invoke the server to get the tools, the player’s datastore data is queried on Players.PlayerAdded
and the tools are added to backpack on Player.CharacterAdded
depending on which tools the player’s data says they have. Ideally all that needs to be stored is a list of Asset IDs, and a loop would take care of the rest.
1 Like