Minor issue

I hit a problem afte I used the PrintTable() function:

Example:



function GetBut(ply, cmd, arg)
	ply:SetRace(PrintTable(arg))
	print("HEY")
	print(PrintTable(arg))
end
concommand.Add("but", GetBut) 

It now prints out: 1 = 1.00 which give me an error at the ply:SetRace(PrintTable(arg)) part.
I need it to be a whole number, so i can use it.

PrintTable prints a table to the console and nothing more. You don’t use it inside other functions.

[lua]
function GetBut(ply, cmd, arg)
PrintTable(arg)
ply:SetRace(arg[1])
end
concommand.Add(“but”, GetBut)
[/lua]

Thanks! It had to be whole number, so i added: ply:SetRace(tonumber(arg[1]))