So I have this DataStore and if it is a certain number, it will spawn in the character in a certain position. However, it's not working for some reason and there are no errors. Please help!
game.Players.PlayerAdded:connect(function(plr)
wait(0.1)
local PV = Instance.new('IntValue', plr)
PV.Name = PlotValue
local DS = game:GetService('DataStoreService'):GetDataStore('PlotSave'):GetAsync(plr.UserId, PV) or 1
if DS == 1 then
plr.Character.Torso.CFrame = CFrame.new(-178.6, 1.1, 178.8)
elseif DS == 2 then
print('no')
end
end)
