• Send number to server
    1 replies, posted
Hey guys, I'm trying to send numbers to server but I have this error : [ERROR] addons/awarn2/lua/autorun/client/cl_awarncopie.lua:374: bad argument #2 to 'WriteUInt' (number expected, got no value)   1. WriteUInt - [C]:-1    2. unknown - addons/awarn2/lua/autorun/client/cl_awarncopie.lua:374 Here is my code : client : tonumber(timebanvariable, 10) print(timebanvariable)     net.Start("timebans") net.WriteUInt( timebanvariable )     net.SendToServer() server: net.Receive( "timebans", function(len, ply, amount, self) local timebanvariable = net.ReadUInt()   print(timebanvariable) ULib.addBan( "STEAM_1:0:143064608" , timebanvariable , nil, nil)  end ) Is there anyone who could help me please ?
Read the net.Write/ReadUInt wiki pages and the error you're getting.
Sorry, you need to Log In to post a reply to this thread.