Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

What is the script for a money system?

I am making a RP game, and I need to know how to create a moiney system. (The money preferably being gold) Thanks!

1 answer

✓ Accepted answer

Hi there! Leader board is main place where you can display any kind of your game currency!

Lets start:

--first lets create a leaderstats for each player joined the game.
game.Players.PlayerAdded:connect(function(newPlayer)
     local stats = Instance.new('BoolValue')
     stats.Name = 'leaderstats'
     stats.Parent = newPlayer

--Now lets create a gold value for it
    local gold = Instance.new('IntValue')
    gold.Value = 0 --or any other number will give the player that amount of gold when you start the game
    gold.Name = 'Gold'
    gold.Parent = stats
--now you should have Gold in your leader board when you start the game

end)

Hope this helps!

4 comments

0

Thank you so much! I don't know if I can ever repay you!

0

Lol :D you mustn't. You could just get free model. This script is basic stuff in ROBLOX Lua.

0

I have one question though. I tried this script and the Gold isn't appearing on the leaderboard. I am not judging your answer. It still helped a lot. But what kind of script do i use and where do I put it?

0

Whops. Its actually gold.Name not gold.name :D

This discussion is preserved as it was. New answers, comments, and votes are closed.