diff --git a/editions.yaml b/editions.yaml index b1ae006..ecd0513 100644 --- a/editions.yaml +++ b/editions.yaml @@ -2,6 +2,7 @@ wii-u-chat: include-in-checkall: true features: - prudpv1 + - third-notif-param - v3-3-2 settings: AUTH_REPORT_VERSION: "branch:origin/project/wup-agmj build:3_8_15_2004_0" diff --git a/rnex-core/Cargo.toml b/rnex-core/Cargo.toml index 6617a92..66b9f79 100644 --- a/rnex-core/Cargo.toml +++ b/rnex-core/Cargo.toml @@ -44,8 +44,10 @@ guest_login = [] friends = ["guest_login", "database-support"] big_pid = [] v3-3-2 = [] -v3-5-0 = ["v3-3-2"] -v3-8-15 = ["rmc_struct_header", "v3-5-0"] +third-notif-param = [] +v3-4-0 = ["v3-3-2", "third-notif-param", "rmc_struct_header"] +v3-5-0 = ["v3-4-0"] +v3-8-15 = ["v3-5-0"] v4-3-11 = ["v3-8-15"] nx = ["big_pid"] datastore = ["database-support", "v3-8-15", "dep:aws-sdk-s3", "dep:aws-config"] diff --git a/rnex-core/src/nex/matchmake.rs b/rnex-core/src/nex/matchmake.rs index cd172ee..fd6632e 100644 --- a/rnex-core/src/nex/matchmake.rs +++ b/rnex-core/src/nex/matchmake.rs @@ -232,7 +232,7 @@ impl ExtendedMatchmakeSession { param_1: self.session.gathering.self_gid as PID, param_2: other_pid, str_param: "".into(), - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, }) .await; @@ -265,7 +265,7 @@ impl ExtendedMatchmakeSession { param_1: self.session.gathering.self_gid as PID, param_2: *pid, str_param: join_msg.clone(), - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: self.connected_players.len() as _, }) .await; @@ -288,7 +288,7 @@ impl ExtendedMatchmakeSession { param_1: self.session.gathering.self_gid as PID, param_2: new_conn_pid, str_param: join_msg.clone(), - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: self.connected_players.len() as _, }) .await; diff --git a/rnex-core/src/nex/user.rs b/rnex-core/src/nex/user.rs index 995d40d..2f87397 100644 --- a/rnex-core/src/nex/user.rs +++ b/rnex-core/src/nex/user.rs @@ -463,7 +463,7 @@ impl MatchmakeExtension for User { notif_type: REQUEST_JOIN_GATHERING * 1000, param_1, param_2, - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, str_param, }) @@ -476,7 +476,7 @@ impl MatchmakeExtension for User { notif_type: END_GATHERING * 1000, param_1, param_2, - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, str_param, }) @@ -554,7 +554,7 @@ impl Matchmake for User { pid_source: self.pid, param_1: gid as PID, param_2: self.pid, - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, str_param: "".to_string(), }) @@ -576,7 +576,7 @@ impl Matchmake for User { pid_source: self.pid, param_1: gid as PID, param_2: self.pid, - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, str_param: "".to_string(), }) @@ -612,7 +612,7 @@ impl Matchmake for User { pid_source: self.pid, param_1: gid as PID, param_2: *candidate as PID, - #[cfg(feature = "v3-5-0")] + #[cfg(feature = "third-notif-param")] param_3: 0, str_param: "".to_string(), }) diff --git a/rnex-core/src/rmc/protocols/notifications.rs b/rnex-core/src/rmc/protocols/notifications.rs index a0aa508..e66f8fe 100644 --- a/rnex-core/src/rmc/protocols/notifications.rs +++ b/rnex-core/src/rmc/protocols/notifications.rs @@ -10,17 +10,17 @@ pub mod notification_types { } cfg_if::cfg_if! { - if #[cfg(feature = "v3-5-0")]{ -#[derive(RmcSerialize, Debug, Default, Clone)] -#[rmc_struct(0)] -pub struct NotificationEvent { - pub pid_source: PID, - pub notif_type: u32, - pub param_1: PID, - pub param_2: PID, - pub str_param: String, - pub param_3: PID, -} + if #[cfg(feature = "third-notif-param")]{ + #[derive(RmcSerialize, Debug, Default, Clone)] + #[rmc_struct(0)] + pub struct NotificationEvent { + pub pid_source: PID, + pub notif_type: u32, + pub param_1: PID, + pub param_2: PID, + pub str_param: String, + pub param_3: PID, + } } else { #[derive(RmcSerialize, Debug, Default, Clone)] #[rmc_struct(0)]