DataStore problems

I’m trying to change the data of someone offline, but the script doesn’t seem to work it says the userdata2 is a nil value which its not.
This is the script:
image

it worked for me in my last game but now it isn’t again. Any Help is appreciated!

1 Like

I would say to use a plugin designed for this task like DataStore Editor.

Uh, I’m changing someone’s data with a script not plugin? and How would other players use the plugin when it costs 150 robux?

1 Like

I want to be able to change someone’s data in game, so a plugin wouldn’t be the right job for it.

Recomendo ler esse artigo: Documentation - Roblox Creator Hub

1 Like

I recommend reading this article: Documentation - Roblox Creator Hub

1 Like

Não pedi para fazer um script de datasave, queria saber como esse script não obteve os dados dos jogadores usando GetAsync, quando não há nada de errado com ele.

does this player have saved data?

1 Like

yes it does, I’ve played on it many times and the data always saved

so the data is being saved, but not being recovered? and sorry for my english, i’m using google translator

1 Like

Basically, GetAsync doesn’t seem to be working and says the data is nil. and your english is perfectly fine

I will make some changes to your code to see if it will work

1 Like

Alright, Hopefully it works and thanks.

em vez de “game:GetService(‘Players’):GetUserIdFromNameAsync” porque não usa “plr.UserId”?

1 Like

Não estou tentando obter meus dados, outra pessoa está usando o nome

try this:

Sem título

Code.txt (748 Bytes)

1 Like

I sent the download of another code, here is the correct one:

Code.txt (748 Bytes)

1 Like

image always comes back as nil

But is this error related to the code?

1 Like

Yes it is sadly, I’ve looked at the output while firing the remoteevent.