#Remove data from profilestore module (by loleris)

1 messages · Page 1 of 1 (latest)

mild flare
#

i have two values on my data that i want to delete. how do i do that?

#

ill send my code hold on

#
function DataManager.ResetData(player: Player)
    local profile = DataManager.Profiles[player]
    
    if not profile then return end
    
    --????
    
    profile.Data = nil --will this even work??
    
end


raven crane
#

profile.Data = {}

#

that would just set the data of the profile to a empty table, I think nil would error in the profilestore module

#

I don't know exactly tho but just do .Data = {}

#

and if you want to delete an specific value you can just index

#

profile.Data.myValue = nil