How Can One Game Share A Leaderstats With Another!?

Hey, I Need To Have One Leaderstats That Shares That Exact One With Another Place/Game Of Mine That Saves And Everything. Sorry, It’s Hard For Me To Explain But Hope You Understand. I Need This For A Tournament/Match-Making System.

Not sure how to do this but I really need it to complete my project for my game Chaotic Tower. If You Dont Understand Here Is A Picture To Visualise It.

GOOGLE SLIDES: Untitled presentation - Google Slides

Couldn’t Make It Great But It Works! Also I Have The Leaderstats Script And I Think We All Know How To Make One But If You Want To See It Just Tell Me.

Thanks For Reading :smiley:

Can you show picture but another link (example: Gyazo.com, Snippingtool).

if you want to use one script across multiple games then Module Scripts are your solution.

Module scripts allow you to write blocks of code that is reusable anywhere, much like a function. But, you can use it in other games too.

API docs: Module Scripts

Example:

-- In module script
local module = {}

function module.Get(array)
    for i = 1, #array do
        print(array[i])
    end
end

return module
-- in another script that ~= modulescript
local module = require(path.To.Module) -- or module ID e.g: 38742984
local PlayersChildren = game:GetService("Players"):GetChildren()

module.Get(PlayersChildren) -- prints contents of players
1 Like

Okay cool. But I don’t really understand module scripts and how to use them, I need it quick because of the due date of my game. I will try to learn them but it might take a longer time then I need.

The module script wont help you do this.

you could add multiple places to you game and use a datastore. then if a player joins into the game and goes to any of the places the data will be the same

2 Likes

thanks I will try this! If it works i will put this as a Solution