summaryrefslogtreecommitdiff
path: root/src/net/tmwa/network.h
AgeCommit message (Collapse)AuthorFilesLines
2025-05-12TMWA: Added debug logging of sent messagesThorbjørn Lindeijer1-0/+2
2025-01-21Replaced include guards with #pragma onceThorbjørn Lindeijer1-4/+1
Thanks to https://github.com/cgmb/guardonce and a follow-up replace to remove duplicated newlines at end of file: find src -type f -name '*.h' -exec \ sed --in-place -e :a -e '/^\n*$/{$d;N;};/\n$/ba' {} \; Source: https://unix.stackexchange.com/questions/81685/how-to-remove-multiple-newlines-at-eof Fixes compile on macOS, which appears to have been due to the EVENT_H include guard.
2024-10-18General code cleanupsThorbjørn Lindeijer1-1/+1
2024-04-18Simplify TmwAthena::MessageOutThorbjørn Lindeijer1-4/+2
Since for tmwAthena we're writing messages directly into the output buffer, the MessageOut implementation does not need any members. Also used SDL_SwapLE16 and SDL_SwapLE32 for convenience.
2024-02-13Updated tmwAthena network protocolThorbjørn Lindeijer1-13/+11
* The code defining the message IDs and sizes are now generated by the tools/protocol.py script in the tmwAthena repository. * Reduced client version from 20 to 6, because that is currently the minimum supported version, and any adjustments needed for later likely still need to be made. * Removed use of no longer handled messages: - CMSG_SKILL_USE_BEING - CMSG_SKILL_USE_POSITION - CMSG_SKILL_USE_MAP - SMSG_PARTY_MOVE - CMSG_WHO_REQUEST - SMSG_WHO_ANSWER - SMSG_MVP - SMSG_BEING_MOVE2 - SMSG_BEING_CHANGE_LOOKS * Some messages were renamed to match the server side - CMSG_PLAYER_ATTACK -> CMSG_PLAYER_CHANGE_ACT - CMSG_PLAYER_RESTART -> CMSG_PLAYER_REBOOT - SMSG_ADMIN_IP -> SMSG_BEING_IP_RESPONSE Part of addressing issues #55 and #47, which we now know are about handling SMSG_PLAYER_HP and SMSG_NPC_COMMAND respectively. The client will now ignore them (with a warning) instead of crash.
2024-01-28Added support for map/layer maskThorbjørn Lindeijer1-0/+1
A custom "Mask" property on a layer or a "foregroundXmask" property on a map can now be used in combination with the SMSG_MAP_MASK to dynamically disable certain map layers from the server. Feature previously seen on ManaPlus and implemented for Mana client for compatibility. Also added a ResourceRef class for automating the Resource reference counting. Closes #44
2024-01-26Apply C++11 fixitsThorbjørn Lindeijer1-2/+2
modernize-use-auto modernize-use-nullptr modernize-use-override modernize-use-using
2024-01-26Added support for the "persistentIp" server info settingThorbjørn Lindeijer1-1/+1
This option was added in ManaPlus and support for it is required to connect to The Mana World as it is currently set up, since the server sends 127.0.0.1 for the character server and map server IP. Can't play yet, because of an unknown packet 0x226 being received once connecting to the map server.
2012-01-26Updated copyrights to 2012Thorbjørn Lindeijer1-1/+1
2011-09-16Instead of SDL_mutex, use Mutex wrapper and MutexLocker for safetyBen Longbons1-1/+3
Reviewed-by: Thorbjørn Lindeijer <thorbjorn@lindeijer.nl>
2010-04-17Changed eAthena protocol name to TmwAthena and changed the config files ↵Bertram1-0/+130
accordingly. This makes room for the actual eAthena protocol future inclusion.