I am trying to get the letters/numbers at the end of a string after a ':' (ex: test:56, I would want 56). I tried using string match but it just shows as nil.
local RepStore = game:GetService("ReplicatedStorage") local vote = RepStore:WaitForChild("Remotes"):WaitForChild("Vote") local votes = game:GetService("ServerStorage"):WaitForChild("Votes") vote.OnServerEvent:Connect(function(_p, v, pv, pvn, n) assert(type(v) == "number", "v must be a number") assert(type(pv) == "number", "pv must be a number") if pv == 0 then votes[v].Value = n.."_1" else print(string.match(votes[pv].Value, ":(.*)")) -- Output: nil votes[pv].Value = pvn.."_"..string.match(votes[pv].Value, ":(.*)") - 1 votes[v].Value = n.."_"..string.match(votes[v].Value, ":(.*)") + 1 end end)