Skip to content

Commit

Permalink
fix(secure): using another function
Browse files Browse the repository at this point in the history
  • Loading branch information
AToska21 committed Sep 30, 2024
1 parent f80551f commit 5fffd1c
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions nex/register_common_secure_server_protocols.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,9 @@ func compareSearchCriteria[T ~uint16 | ~uint32](original T, search string) bool
}
}

func cleanupMatchmakeSessionSearchCriteriasHandler(searchCriterias *types.List[*matchmakingtypes.MatchmakeSessionSearchCriteria]) {
search := searchCriterias.Slice();

for _, searchCriteriasElem := range search {
searchCriteriasElem.Attribs.DeleteIndex(1);
searchCriteriasElem.Attribs.DeleteIndex(4);
}
func cleanupSearchMatchmakeSession(matchmakeSession *match_making_types.MatchmakeSession) {
matchmakeSession.Attributes.DeleteIndex(1);
matchmakeSession.Attributes.DeleteIndex(4);
}

func gameSpecificMatchmakeSessionSearchCriteriaChecksHandler(searchCriteria *matchmakingtypes.MatchmakeSessionSearchCriteria, matchmakeSession *matchmakingtypes.MatchmakeSession) bool {
Expand Down Expand Up @@ -155,7 +151,7 @@ func registerCommonSecureServerProtocols() {
globals.SecureEndpoint.RegisterServiceProtocol(matchmakeExtensionProtocol)
commonMatchmakeExtensionProtocol := commonmatchmakeextension.NewCommonProtocol(matchmakeExtensionProtocol)
matchmakeExtensionProtocol.SetHandlerGetPlayingSession(stubGetPlayingSession)
commonMatchmakeExtensionProtocol.CleanupMatchmakeSessionSearchCriterias = cleanupMatchmakeSessionSearchCriteriasHandler
commonMatchmakeExtensionProtocol.CleanupSearchMatchmakeSession = cleanupSearchMatchmakeSession
commonMatchmakeExtensionProtocol.OnAfterAutoMatchmakeWithParamPostpone = onAfterAutoMatchmakeWithParamPostpone
commonMatchmakeExtensionProtocol.SetManager(globals.MatchmakingManager)

Expand Down

0 comments on commit 5fffd1c

Please sign in to comment.