diff options
Diffstat (limited to 'src/net/eathena/charserverhandler.cpp')
-rw-r--r-- | src/net/eathena/charserverhandler.cpp | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/net/eathena/charserverhandler.cpp b/src/net/eathena/charserverhandler.cpp index 3dd5134e0..af3c012dd 100644 --- a/src/net/eathena/charserverhandler.cpp +++ b/src/net/eathena/charserverhandler.cpp @@ -71,6 +71,7 @@ CharServerHandler::CharServerHandler() : SMSG_CHAR_DELETE_FAILED, SMSG_CHAR_MAP_INFO, SMSG_CHANGE_MAP_SERVER, + SMSG_CHAR_PINCODE_STATUS, 0 }; handledMessages = _messages; @@ -114,6 +115,10 @@ void CharServerHandler::handleMessage(Net::MessageIn &msg) processChangeMapServer(msg); break; + case SMSG_CHAR_PINCODE_STATUS: + processPincodeStatus(msg); + break; + default: break; } @@ -371,4 +376,36 @@ void CharServerHandler::processChangeMapServer(Net::MessageIn &msg) BLOCK_END("CharServerHandler::processChangeMapServer") } +void CharServerHandler::processPincodeStatus(Net::MessageIn &msg) +{ + msg.readInt32("pincode seed"); + msg.readInt32("account id"); + const uint16_t state = static_cast<uint16_t>(msg.readInt16("state")); + switch (state) + { + case 0: // pin ok + break; + case 1: // ask for pin + break; + case 2: // create new pin + break; + case 3: // pin must be changed + break; + case 4: // create new pin? + break; + case 5: // client show error? + break; + case 6: // Unable to use your KSSN number + break; + case 7: // char select window shows a button + break; + case 8: // pincode was incorrect + break; + default: + logger->log("processPincodeStatus: unknown pin state: %d", + static_cast<int>(state)); + break; + } +} + } // namespace EAthena |