Player stats list
#10
Well, that was just an example of how it worked.

Per-player, I would do something like this:

-- Assuming the blocks broken is 34 or something like that...
local BlocksBroken = 34

-- If the player\'s key name does not exist, add it
if SomeIniFile:FindKey(Player:GetUUID()) == -1 then
    SomeIniFile:AddKeyName(Player:GetUUID())
end

-- Write the amount of blocks broken under the \'BlocksBroken\' value under the Player\'s UUID
SomeIniFile:SetValueI(Player:GetUUID(), "BlocksBroken", BlocksBroken)

-- Write the file to disk
SomeIniFile:WriteFile(FilePath)

And to access it:
-- Read the file off of the disk
SomeIniFile:ReadFile(FilePath)
 
-- Set value of NumBlocks to the amount stored under the Player\'s key name and \'BlocksBroken\' value name
local NumBlocks = SomeIniFile:GetValueI(Player:GetUUID(), "BlocksBroken")
Reply
Thanks given by:


Messages In This Thread
Player stats list - by Boo - 04-19-2015, 07:44 PM
RE: Player stats list - by worktycho - 04-19-2015, 09:16 PM
RE: Player stats list - by Boo - 04-19-2015, 09:29 PM
RE: Player stats list - by worktycho - 04-19-2015, 09:36 PM
RE: Player stats list - by Boo - 04-19-2015, 09:55 PM
RE: Player stats list - by xoft - 04-19-2015, 10:08 PM
RE: Player stats list - by Boo - 04-20-2015, 05:33 PM
RE: Player stats list - by DiamondToaster - 04-21-2015, 05:55 AM
RE: Player stats list - by NiLSPACE - 04-21-2015, 06:00 AM
RE: Player stats list - by DiamondToaster - 04-21-2015, 07:56 AM



Users browsing this thread: 1 Guest(s)