Match phys::System contact listener and group handler forwarders - #184
Merged
Pistonight merged 1 commit intoJul 31, 2026
Merged
Conversation
RobbyV2
force-pushed
the
phys-system-contact-listeners
branch
from
July 29, 2026 21:56
6579af9 to
0f6859e
Compare
Pistonight
reviewed
Jul 30, 2026
Pistonight
left a comment
Collaborator
There was a problem hiding this comment.
@Pistonight reviewed all commit messages and made 1 comment.
Reviewable status: 0 of 4 files reviewed, 1 unresolved discussion (waiting on RobbyV2).
src/KingSystem/Physics/System/physSystem.cpp line 53 at r1 (raw file):
void System::removeSystemGroupHandler(SystemGroupHandler* handler) { mGroupFilters[int(handler->getLayerType())]->removeSystemGroupHandler(handler);
nit: prefer cpp cast static_cast<s32>(...) ( and other places )
RobbyV2
force-pushed
the
phys-system-contact-listeners
branch
from
July 30, 2026 13:10
0f6859e to
1e080b3
Compare
Contributor
Author
|
Done |
Pistonight
approved these changes
Jul 31, 2026
Collaborator
|
Thanks for the PR! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The FIXME'd _128 is indexed by ContactLayerType and its elements take ContactListener calls, so it is sead::FixedPtrArray<ContactListener, 2>, named mContactListeners; the bounds check in the assembly is sead::PtrArrayImpl::at.
freeLayerContactPointInfo drops the info's layer pairs from the listener for its layer type, then frees the info through ContactMgr. registerContactPointLayerPair adds one pair to that same listener. trackLayerPair selects the listener from the first layer's ContactLayerType and returns the ContactLayerCollisionInfo it tracks.
removeSystemGroupHandler indexes mGroupFilters by the handler's layer type and forwards to GroupFilter::removeSystemGroupHandler.
I added getLayerType to LayerContactPointInfo since mLayerType is private.
This change is