diff --git a/src/world/ipc/common_spawn.rs b/src/world/ipc/common_spawn.rs index f95ebd9..c8fdbaf 100644 --- a/src/world/ipc/common_spawn.rs +++ b/src/world/ipc/common_spawn.rs @@ -4,7 +4,31 @@ use crate::CHAR_NAME_MAX_LENGTH; use crate::common::{CustomizeData, read_string, write_string}; use super::position::Position; -use super::{CharacterMode, ObjectKind, StatusEffect}; +use super::{CharacterMode, StatusEffect}; + +#[binrw] +#[brw(repr = u8)] +#[derive(Clone, PartialEq, Debug, Default)] +pub enum ObjectKind { + #[default] + None = 0, + Player = 1, + BattleNpc = 2, + EventNpc = 3, + Treasure = 4, + Aetheryte = 5, + GatheringPoint = 6, + EventObj = 7, + Mount = 8, + Companion = 9, + Retainer = 10, + AreaObject = 11, + HousingEventObject = 12, + Cutscene = 13, + MjiObject = 14, + Ornament = 15, + CardStand = 16, +} #[binrw] #[brw(little)] diff --git a/src/world/ipc/mod.rs b/src/world/ipc/mod.rs index 9c7aee8..1e1d11d 100644 --- a/src/world/ipc/mod.rs +++ b/src/world/ipc/mod.rs @@ -38,7 +38,7 @@ mod npc_spawn; pub use npc_spawn::NpcSpawn; mod common_spawn; -pub use common_spawn::CommonSpawn; +pub use common_spawn::{CommonSpawn, ObjectKind}; use crate::common::read_string; use crate::common::write_string; @@ -128,30 +128,6 @@ pub enum GameMasterCommandType { ChangeTerritory = 0x58, } -#[binrw] -#[brw(repr = u8)] -#[derive(Clone, PartialEq, Debug, Default)] -pub enum ObjectKind { - #[default] - None = 0, - Player = 1, - BattleNpc = 2, - EventNpc = 3, - Treasure = 4, - Aetheryte = 5, - GatheringPoint = 6, - EventObj = 7, - Mount = 8, - Companion = 9, - Retainer = 10, - AreaObject = 11, - HousingEventObject = 12, - Cutscene = 13, - MjiObject = 14, - Ornament = 15, - CardStand = 16, -} - #[binrw] #[brw(repr = u16)] #[derive(Clone, PartialEq, Debug)]