If statements checking if two values are equivalent breaking [SOLVED]

I’m attempting to check if an ID is equivalent to another ID, and when I print them they are the same but when checking if they are the same the game does not think so.

Code:

print(acc.Added.Value .. " " .. itemId)
if acc.Added.Value == itemId then
       acc:Destroy()
       print(true)
else
       print(false)
end

Prints:

13700820 13700820
false

If these are the exact same value, then why is it happening? Is it an issue with roblox?
(No, I don’t think any other scripts are interfering with this)

1 Like

Maybe one of the value is a string?
You could try use tonumber on the values

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.