Hi all,
Here is a snippet of code that I'm trying to improve upon:
switch (event.type) {
case ENET_EVENT_TYPE_RECEIVE:
// XXX Are we really going to do a memcpy here?
memcpy(P, event.packet->data, event.packet->dataLength);
break;
}
I've got this block of code in a source file that I want to contain ALL of the
networking code and therefore don't want to have to include enet/enet.h
anywhere else. My C skills are rusty so here goes... How do I convert the
EnetPacket* to a void* without simply copying it to a char[]?
--
Take care and have fun,
Mike Diehl.
_______________________________________________
ENet-discuss mailing list
[email protected]
http://lists.cubik.org/mailman/listinfo/enet-discuss