Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Converted with ttyyuu12345's model to script plugin v4
- function sandbox(var,func)
- local env = getfenv(func)
- local newenv = setmetatable({},{
- __index = function(self,k)
- if k=="script" then
- return var
- else
- return env[k]
- end
- end,
- })
- setfenv(func,newenv)
- return func
- end
- cors = {}
- mas = Instance.new("Model",game:GetService("Lighting"))
- Script0 = Instance.new("Script")
- Script0.Name = "Money Leaderboard"
- Script0.Parent = Model0
- table.insert(cors,sandbox(Script0,function()
- print("Cash Leaderboard Loaded")
- function onPlayerEntered(newPlayer)
- local stats = Instance.new("IntValue")
- stats.Name = "leaderstats"
- local cash = Instance.new("IntValue")
- cash.Name = "Tickets" --name of currency (e.g. cash, money, resources, bucks, etc.)
- cash.Value = 1000 --starting money.
- cash.Parent = stats
- stats.Parent = newPlayer
- end
- game.Players.ChildAdded:connect(onPlayerEntered)
- --Script Made by Chibichuba8
- end))
- for i,v in pairs(mas:GetChildren()) do
- v.Parent = workspace
- pcall(function() v:MakeJoints() end)
- end
- mas:Destroy()
- for i,v in pairs(cors) do
- spawn(function()
- pcall(v)
- end)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement