Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

I want to make currency.. but how? [closed]

Asked by 4 years ago

I am currently trying to make currency for my game, "Adventure Run". I would appreciate it if you tell me how.

Thank you!

-- WOWgamerboyYT

0
You can make currency by... making currency Nguyenlegiahung 1091 — 4y

Closed as Not Constructive by jediplocoon, Nguyenlegiahung, Wiscript, and JesseSong

This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.

Why was this question closed?

1 answer

Log in to vote
0
Answered by 4 years ago

Easy to do! First, insert a server script inside ServerScriptService.

Script:

local Players = game:GetService("Players")

Players.PlayerAdded:Connect(function(player)

    local leaderstats = Instance.new("Folder")
    leaderstats.Parent = player

    local Cash = Instance.new("IntValue")
    Cash.Name = "Cash"
    Cash.Value = 50
    Cash.Parent = leaderstats

end)

Explanation

We use PlayerAdded function so that it fires whenever a player joins. We create a folder and name it leaderstats, parent it to the player. We create an IntValue, name it Cash, Set it's value and parent it inside the leaderstats!

Ad