diff --git a/src/PlayerManager.cpp b/src/PlayerManager.cpp index d28fb78..434f807 100644 --- a/src/PlayerManager.cpp +++ b/src/PlayerManager.cpp @@ -190,14 +190,13 @@ static void sendNanoBookSubset(CNSocket *sock) { for (int i = id - pkt.elementOffset; id < NANO_COUNT && i < 10; id++, i = id - pkt.elementOffset) pkt.element[i] = plr->Nanos[id]; - // TODO: add NANO_BOOK_SUBSET to Defines.c, so we can switch this to the new system later - sock->sendPacket((void*)&pkt, P_FE2CL_REP_NANO_BOOK_SUBSET, sizeof(sP_FE2CL_REP_NANO_BOOK_SUBSET)); + sock->sendPacket(pkt, P_FE2CL_REP_NANO_BOOK_SUBSET); } #endif } static void enterPlayer(CNSocket* sock, CNPacketData* data) { - auto* enter = (sP_CL2FE_REQ_PC_ENTER*)data->buf; + auto enter = (sP_CL2FE_REQ_PC_ENTER*)data->buf; INITSTRUCT(sP_FE2CL_REP_PC_ENTER_SUCC, response); // TODO: check if serialkey exists, if it doesn't send sP_FE2CL_REP_PC_ENTER_FAIL diff --git a/src/core/Packets.cpp b/src/core/Packets.cpp index 0d0a431..9700689 100644 --- a/src/core/Packets.cpp +++ b/src/core/Packets.cpp @@ -531,6 +531,11 @@ std::map Packets::packets = { PACKET(P_FE2CL_GM_REP_REWARD_RATE_SUCC), PACKET(P_FE2CL_REP_PC_ITEM_ENCHANT_SUCC), PACKET(P_FE2CL_REP_PC_ITEM_ENCHANT_FAIL), + +#ifdef ACADEMY + // Academy-specific + PACKET(P_FE2CL_REP_NANO_BOOK_SUBSET), +#endif }; std::string Packets::p2str(int val) {