diff --git a/crates/formats/src/msb/event.rs b/crates/formats/src/msb/event.rs index 5194245..07f5d63 100644 --- a/crates/formats/src/msb/event.rs +++ b/crates/formats/src/msb/event.rs @@ -66,6 +66,7 @@ pub enum EventData<'a> { Mount(&'a EventDataMount), SignPool(&'a EventDataSignPool), RetryPoint(&'a EventDataRetryPoint), + OnlinePseudoMultiplayer(&'a EventDataOnlinePseudoMultiplayer), } impl<'a> EventData<'a> { @@ -103,6 +104,10 @@ impl<'a> EventData<'a> { 24 => Self::RetryPoint( EventDataRetryPoint::ref_from_prefix(data).ok_or(MsbError::UnalignedValue)?, ), + 25 => Self::OnlinePseudoMultiplayer( + EventDataOnlinePseudoMultiplayer::ref_from_prefix(data) + .ok_or(MsbError::UnalignedValue)?, + ), _ => return Err(MsbError::UnknownEventDataType(event_type)), }) @@ -198,14 +203,36 @@ pub struct EventDataNavmesh { #[repr(packed)] #[allow(unused)] pub struct EventDataPseudoMultiplayer { - host_entity_id: I32, - event_flag_id: I32, + host_entity_id: U32, + event_flag_id: U32, activate_goods_id: I32, - unkc: I32, - unk10: I32, // Seems to be some event flag? - unk14: I32, - unk18: I32, - ceremony_param: I32, + ceremony_id: U32, + invasion_point_id: U32, + ceremony_type: u8, + network_msg_npc_type: i8, + padding16: Padding<2>, + event_text_for_map_id: I32, + ceremony_param_id: I32, + role_param_id_override: I32, +} + +#[derive(FromZeroes, FromBytes, Debug)] +#[repr(packed)] +#[allow(unused)] +pub struct EventDataOnlinePseudoMultiplayer { + host_entity_id: U32, + event_flag_id: U32, + activate_goods_id: I32, + ceremony_id: U32, + host_invasion_point_id: U32, + guest1_invasion_point_id: U32, + guest2_invasion_point_id: U32, + ceremony_type: u8, + network_msg_npc_type: i8, + padding1e: Padding<2>, + event_text_for_map_id: I32, + ceremony_param_id: I32, + role_param_id_override: I32, } #[derive(FromZeroes, FromBytes, Debug)]