Skip to content

Conversation

@henrymkw
Copy link
Contributor

@henrymkw henrymkw commented Jul 9, 2025

Bulk of work is matching NetManager functions, particularly the ones that don't call DWC functions that haven't been defined in the project as of this moment. Other than that, the various headers and functions of other net classes have been worked on. Looking for feedback on names

A few notes:

  • RACEHEADER1Handler::courseValid() and NetManager::getFriendJoinableStatus() have regswaps (Link and Link), and are also the two with the most awkward implementations. I don't know what the general policy is for merging functions with regswaps like this
  • There are a lot of room related enums, with subtle distinctions, not sure about their names. See FriendInfo.hpp
  • Is rk_common.h the best place for the MAX_FRIEND_COUNT and MAX_PLAYER_COUNT to live?

henrymkw added 2 commits July 8, 2025 18:58
Bulk of work is matching NetManager functions that don't call DWC functions, as those aren't defined and are not in scope of this commit

Additionally, various progress has been made, both on the source and header, of other net related classes
@decomp-dev
Copy link

decomp-dev bot commented Jul 9, 2025

Report for RMCP01 (1d03278 - 929bf50)

📈 Matched code: 5.69% (+0.04%, +2180 bytes)

✅ 15 new matches:
Unit Function Bytes Before After
StaticR/net/NetManager Net::NetManager::handleError() +352 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::updateAidMapping() +352 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::joinFriendPublicVS(unsigned long, unsigned char) +304 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::joinFriendPublicBT(unsigned long, unsigned char) +304 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::resetFriends() +196 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::initMMInfos() +164 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::getConnectionState() const +132 0.00% 100.00%
StaticR/net/MiscPacketHandler Net::MiscPacketHandler::isPlayerLocal(unsigned long) +112 0.00% 100.00%
StaticR/net/MiscPacketHandler Net::MiscPacketHandler::MiscPacketHandler() +88 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::resetPlayerIdToAidMap() +56 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::resetFriendData(unsigned long) +48 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::updateDWCServersAsyncCallback(unsigned long, unsigned long, Net::NetManager*) +28 0.00% 100.00%
StaticR/net/MiscPacketHandler Net::MiscPacketHandler::clearAidFromUnkBitfield(unsigned long) +24 0.00% 100.00%
StaticR/net/NetManager Net::NetManager::DWCSetBuddyFriendCallback(unsigned long, Net::NetManager*) +12 0.00% 100.00%
StaticR/net/packets/SELECT Net::SELECTHandler::getPlayerIdToAidMapping() const +8 0.00% 100.00%
📈 1 improvements in unmatched functions:
Unit Function Bytes Before After
StaticR/net/NetManager Net::NetManager::getFriendJoinableStatus(unsigned long) const +240 0.00% 88.24%
📉 294 regressions in unmatched functions:
Unit Function Bytes Before After
StaticR/auto_00_00142E54_text RKNetPacketCreator_initStaticInstance 0 0.00% 0.00%
StaticR/auto_00_00142E54_text RKNetPacketCreator_destroyStaticInstance 0 0.00% 0.00%
StaticR/auto_00_00142E54_text RKNetPacketCreator_init 0 0.00% 0.00%
StaticR/auto_00_00142E54_text RKNetPacketCreator_calc 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1435AC 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143708 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143854 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143904 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143960 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1439C4 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143A28 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143A40 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143A98 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143AD8 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143B18 0 0.00% 0.00%
StaticR/auto_00_00142E54_text MiscPacketHandler_updateAsSpectator 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_143C84 0 0.00% 0.00%
StaticR/auto_00_00142E54_text MiscPacketHandler_updateAsRacer 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1440F4 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1441B4 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_144228 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_144368 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_144380 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_14438C 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_144398 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1443A4 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_1443B0 0 0.00% 0.00%
StaticR/auto_00_00142E54_text fn_1_14445C 0 0.00% 0.00%
StaticR/auto_00_00142E54_text MiscPacketHandler_isPlayerConnected 0 0.00% 0.00%
StaticR/auto_00_00142E54_text MiscPacketHandler_isPlayerLocal 0 0.00% 0.00%

...and 264 more regressions in unmatched functions

@henrymkw henrymkw marked this pull request as ready for review July 9, 2025 01:55
Copy link
Contributor

@em-eight em-eight left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very clean documentation, thank you!

Copy link
Owner

@snailspeed3 snailspeed3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work :)

@snailspeed3 snailspeed3 merged commit 6eed2ce into snailspeed3:master Jul 11, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants