This is the script to save the reviews Thumbs Up, but when someone review it Dosnt add any reviews and Sometimes adds like 30 Reviews to the value when Its suppose to add 1
local ReviewName = "ThumbsUp"
local DS = game:GetService("DataStoreService"):GetDataStore("ReviewThumbsUp9785292371")
if not DS:GetAsync(ReviewName.."-Review") then
DS:SetAsync(ReviewName.."-Review",0)
end
local Reviews = DS:GetAsync(ReviewName.."-Review")
game.Workspace.ReviewValues.ThumbsDown.Value = DS:GetAsync(ReviewName.."-Review")
function PrintOut(Value)
print(Value)
end
game.Workspace.ReviewValues.ThumbsUp.Changed:Connect(function()
DS:IncrementAsync(ReviewName.."-Review",game.Workspace.ReviewValues.ThumbsUp.Value)
DS:OnUpdate(ReviewName.."-Review",PrintOut)
wait(1)
game.Workspace.ReviewValues.ThumbsUp.Value = DS:GetAsync(ReviewName.."-Review")
end)
coroutine.resume(coroutine.create(function()
while wait() do
local Reviews = DS:GetAsync(ReviewName.."-Review")
game.Workspace.ReviewValues.ThumbsUp.Value = DS:GetAsync(ReviewName.."-Review")
end
end))

3 comments
How does it not work properly? (also indent your code)
When someone reviews the value dosnt go up and sometimes adds like 30 reviews to the value
I dont even know what your trying to do.. You cant just post a question and paste some code. You will need to explain to us.