generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: leaderstats

Previous Thread :: Next Thread 
Succulence is not online. Succulence
Joined: 24 Sep 2012
Total Posts: 1437
22 Jun 2014 12:19 PM
how do i make it so there is 2 leaderstats?

for 1 leaderstat



function onPlayerEntered(newPlayer)--when people come into the game

local stats = Instance.new("IntValue")--makes wallet
stats.Name = "leaderstats" --names the wallet leaderstats and it's best to keep it leaderstats

local Money = Instance.new("IntValue")
Money.Name = "Level" --name of the currency
Money.Value = 1-- how much you start of with

Money.Parent = stats-- change Money to your currency in all places
stats.Parent = newPlayer

end
game.Players.ChildAdded:connect(onPlayerEntered)
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
22 Jun 2014 12:20 PM
function onPlayerEntered(newPlayer)--when people come into the game

local stats = Instance.new("IntValue")--makes wallet
stats.Name = "leaderstats" --names the wallet leaderstats and it's best to keep it leaderstats

local Money = Instance.new("IntValue")
Money.Name = "Level" --name of the currency
Money.Value = 1-- how much you start of with

Money.Parent = stats-- change Money to your currency in all places

local Money2 = Instance.new("IntValue") -------------------------------this
Money2.Name = "Money" --name of the currency
Money2.Value = 1-- how much you start of with

Money2.Parent = stats-- change Money to your currency in all places ---to this
stats.Parent = newPlayer


end
game.Players.ChildAdded:connect(onPlayerEntered)
Report Abuse
Succulence is not online. Succulence
Joined: 24 Sep 2012
Total Posts: 1437
22 Jun 2014 12:21 PM
ty
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image