Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Client, send:
- char *BufferToSend;
- float FloatToSend = 4.42;
- BufferToSend = ( char* )&FloatToSend;
- send( Connect, BufferToSend, sizeof(float), 0 );
- // Server, recieve:
- recv( Connect, myBuffer, recvbuflen, 0 );
- float *x;
- x = &myBuffer;
- // *x is now the float you've sent up there, so you can now do:
- float a = *x + 320.0f;
- // etc...
Advertisement
Add Comment
Please, Sign In to add comment