Browse Source

dont restrict boxes to episodes. use minor values for maps

pbs
Andy Newjack 4 years ago
parent
commit
f747376898
  1. 22
      src/ship/map.rs

22
src/ship/map.rs

@ -378,13 +378,13 @@ impl MapObject {
(RawMapObject {otype: 146, ..}, _) => MapObjectType::FixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 147, ..}, _) => MapObjectType::EnemyFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 149, ..}, _) => MapObjectType::EmptyFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 353, ..}, Episode::One) => MapObjectType::RuinsFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 354, ..}, Episode::One) => MapObjectType::RuinsBox,
(RawMapObject {otype: 355, ..}, Episode::One) => MapObjectType::RuinsEnemyFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 356, ..}, Episode::One) => MapObjectType::RuinsEnemyBox,
(RawMapObject {otype: 357, ..}, Episode::One) => MapObjectType::RuinsEmptyBox,
(RawMapObject {otype: 512, ..}, Episode::Two) => MapObjectType::CcaBox,
(RawMapObject {otype: 515, ..}, Episode::Two) => MapObjectType::CcaFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 353, ..}, _) => MapObjectType::RuinsFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 354, ..}, _) => MapObjectType::RuinsBox,
(RawMapObject {otype: 355, ..}, _) => MapObjectType::RuinsEnemyFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
(RawMapObject {otype: 356, ..}, _) => MapObjectType::RuinsEnemyBox,
(RawMapObject {otype: 357, ..}, _) => MapObjectType::RuinsEmptyBox,
(RawMapObject {otype: 512, ..}, _) => MapObjectType::CcaBox,
(RawMapObject {otype: 515, ..}, _) => MapObjectType::CcaFixedBox(FixedBoxDropType::from_object(raw.field1, raw.field2, raw.field3, raw.field4)),
_ => return Err(MapObjectError::UnknownObjectType(raw.otype, raw))
};
@ -883,11 +883,11 @@ impl MapVariant {
MapArea::VrTempleBeta => format!("data/maps/map_ruins02_0{}_0{}o.dat", self.major, self.minor),
MapArea::VrSpaceshipAlpha => format!("data/maps/map_space01_0{}_0{}o.dat", self.major, self.minor),
MapArea::VrSpaceshipBeta => format!("data/maps/map_space02_0{}_0{}o.dat", self.major, self.minor),
MapArea::Cca => format!("data/maps/map_jungle01_0{}o.dat", self.major),
MapArea::JungleAreaNorth => format!("data/maps/map_jungle02_0{}o.dat", self.major),
MapArea::JungleAreaEast => format!("data/maps/map_jungle03_0{}o.dat", self.major),
MapArea::Cca => format!("data/maps/map_jungle01_0{}o.dat", self.minor),
MapArea::JungleAreaNorth => format!("data/maps/map_jungle02_0{}o.dat", self.minor),
MapArea::JungleAreaEast => format!("data/maps/map_jungle03_0{}o.dat", self.minor),
MapArea::Mountain => format!("data/maps/map_jungle04_0{}_0{}o.dat", self.major, self.minor),
MapArea::Seaside => format!("data/maps/map_jungle05_0{}o.dat", self.major),
MapArea::Seaside => format!("data/maps/map_jungle05_0{}o.dat", self.minor),
MapArea::SeabedUpper => format!("data/maps/map_seabed01_0{}_0{}o.dat", self.major, self.minor),
MapArea::SeabedLower => format!("data/maps/map_seabed02_0{}_0{}o.dat", self.major, self.minor),
MapArea::GalGryphon => "data/maps/map_boss05o.dat".into(),

Loading…
Cancel
Save