toddw123 / RotMG_Clientless

Compatible with version X16.0.0
MIT License
11 stars 4 forks source link

Just to be safe #46

Closed VoOoLoX closed 7 years ago

VoOoLoX commented 7 years ago

Fix for the memcpy and memset errors

toddw123 commented 7 years ago

PacketIO.cpp has "Packet.h" included, which already has #include <string>. So theres no need to add it to the PacketIO.h file (you want to limit as many headers as you can in .h files and instead try to put as many as possible into the .cpp file).

I also dont get any warning or anything in regards to the micropather file needing it either.

VoOoLoX commented 7 years ago

I just updated my system and tried to compile it. And got errors about memcpy and memset . Yeah i noticed Packet.h has a string included but check this out http://i.imgur.com/lDEYZ4G.png

toddw123 commented 7 years ago

Mmkay. Redo this though and put the header in the .cpp files instead. Then ill pull this into the master branch.

VoOoLoX commented 7 years ago

memset is used in micropather header file so couldn't move that one

toddw123 commented 7 years ago

memset is used in micropather header file so couldn't move that one

That makes sense. With it moved to the .cpp file for PacketIO, were you able to compile without issue?

VoOoLoX commented 7 years ago

Yeah since memcpy is used in source file only, not in the header file.