Setting a limit to a command?

Hello everyone, I’ve been trying to figure this out for the past two days and I can’t figure it out! I need to basically set a limit to using this command to 1 so they can only type it once instead of being able to spam it and it automatically going to a map-vote just because on person is spamming (!rtv)

Here’s the basic command:

        elseif lowtext == "!rtv" then

function RTV.AddVote(ply)
	if ![ply:SteamID()] and ! then
		table.insert(, ply:SteamID())
		announcment({Color(204,102,0), ply:Name(), Color(255,255,255), " has rocked the vote!"})

[lua] if ![ply:SteamID()] and ! then
table.insert(, ply:SteamID())[/lua]

Looks like you already have something to prevent the player from doing it more than once. You’re just inserting the players into the table wrong.
Don’t use table.insert in this case, do this instead:

[lua][ply:SteamID()] = true[/lua]

This should do what you want.

Sadly that doesn’t work. Even though it does limit how many times they can do it it doesn’t pop open the menu when 2/2 players have typed the command.

Then there’s probably a problem with your RTV.CheckIfReady function.