04-21-2015, 07:56 AM
(This post was last modified: 04-21-2015, 07:57 AM by DiamondToaster.)
Well, that was just an example of how it worked.
Per-player, I would do something like this:
And to access it:
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")

