Me and some friends are currently working on a game, and a lot of work is done allready. I'm in head of the programming, and im wondering;
Players will be able to create and customize their own character before they start playing(its a multiplayer rpg), so when this is done the client will send data like visual details(beards, hairstyle) as well as gamespecific details(what class they are(warrior, dwarf, etc), statpoints ).
What would the best way to send this be?
this:
sf::Packet << sf::Uint(class-identifier) << std::string(hairstyle) << etc;
or create a class containing all this configuration, and send it like:
sf::Packet << bleh::CharacterDataSet(this->CurrentData);
by overriding the << and >> ?
Also how would you override the streamfunctions of a Packet in a safe way for own-written classes?
Hope you get what I'm trying to do, any help is much appreciated.