Original Post
Hello, I'm currently in the process of creating a final message to be sent out from my server to my client in my networked game. In essence what I'm doing is taking the reliable and unreliable portions of the message and copying them over to a final message which will be passed to my network layer and sent. I'm trying to use memcpy() to copy the contents of one unsigned char buffer to the next using an index and then bump up the index after the copy to get ready for the unreliable portion of the message if there is one. My code looks like the following: Unfortunately, when this message gets to the client, my message has not been copied over correctly as all I end up with on the client side current is a C8 which appears to be part of a memory address. I'm hoping someone here can point me in the right direction because I can't seem to figure out what's wrong at this point. Thanks in advance, Permafried-
// add the reliable message to the buffer
memcpy( &send.m_szData[ iIndex ],
&m_pClients[ i ]->m_storedReliableMessage.m_szData,
m_pClients[ i ]->m_storedReliableMessage.m_iCurrentSize );
// bump up the current size of the message
send.m_iCurrentSize += m_pClients[ i ]->
m_storedReliableMessage.m_iCurrentSize;