• The Net/ReadInt
    2 replies, posted
Hi Facepunch Guys ! I have a new question for you. 3 days ago, I posted some help about passing information from Server side to client side. You reply me the net/* library. That's work really fine, but I have a problem about ReadInt(). I send that to my client: [CODE]local argent = ply:GetPData( "money", 0 ) util.AddNetworkString( "player_money" ) -- On envoie le nom complet au client pour le HUD net.Start( "player_money" ) net.WriteString( argent ) net.Send( ply )[/CODE] In my HUD, I have that: [CODE]net.Receive( "player_money", function( Length ) money = net.ReadInt(32) print(money) end )[/CODE] The problem is that money is 808,465,714 WTF ? Thanks for reply guys!
You're using WriteString to send it, and you're using ReadInt to read it, that's not going to work. For money you'd be best of using WriteFloat and ReadFloat.
Ok, thank you, love U and all your family <3 See you soon !
Sorry, you need to Log In to post a reply to this thread.