diff --git a/src/add_modify_obj_patches.rs b/src/add_modify_obj_patches.rs index d14d242b..30714a22 100644 --- a/src/add_modify_obj_patches.rs +++ b/src/add_modify_obj_patches.rs @@ -929,12 +929,14 @@ pub fn patch_add_bomb_slot<'r>( } as usize; let deps = vec![ - (0x82A1E868, b"CMDL"), - (0xD64787E8, b"TXTR"), - (0x53A74797, b"CMDL"), + // platform + (0x3852C9CF, b"CMDL"), (0x5B4D184E, b"TXTR"), - (0x563799A1, b"TXTR"), - (0xC11B62AF, b"DCLN"), + (0x89CC3758, b"DCLN"), + + // glow actor + (0xA88267E6, b"CMDL"), + (0xD64787E8, b"TXTR"), ]; let deps_iter = deps.iter() .map(|&(file_id, fourcc)| structs::Dependency { @@ -942,7 +944,7 @@ pub fn patch_add_bomb_slot<'r>( asset_type: FourCC::from_bytes(fourcc), } ); - area.add_dependencies(game_resources, 0, deps_iter); + area.add_dependencies(game_resources, layer, deps_iter); let bomb_slot_id = config.platform_id.unwrap_or(area.new_object_id_from_layer_id(layer)); let glow_ring_id = config.actor_id.unwrap_or(area.new_object_id_from_layer_id(layer)); @@ -973,7 +975,7 @@ pub fn patch_add_bomb_slot<'r>( extent: [0.0, 0.0, 0.0].into(), scan_offset: [0.0, 0.0, 0.0].into(), - cmdl: ResId::::new(0x3F802F32), + cmdl: ResId::::new(0x3852C9CF), ancs: structs::scly_structs::AncsProp { file_id: ResId::invalid(), @@ -1023,7 +1025,7 @@ pub fn patch_add_bomb_slot<'r>( speed: 1.0, active: 1, - dcln: ResId::::new(0xC11B62AF), + dcln: ResId::::new(0x89CC3758), health_info: structs::scly_structs::HealthInfo { health: 1.0, @@ -1055,7 +1057,7 @@ pub fn patch_add_bomb_slot<'r>( knockback_resistance: 1.0 }, damage_vulnerability: DoorType::Disabled.vulnerability(), - cmdl: ResId::::new(0x9BC5E7C6), + cmdl: ResId::::new(0xA88267E6), ancs: structs::scly_structs::AncsProp { file_id: ResId::invalid(), // None node_index: 0, diff --git a/src/custom_assets.rs b/src/custom_assets.rs index ad5454ba..08d13df0 100644 --- a/src/custom_assets.rs +++ b/src/custom_assets.rs @@ -1198,6 +1198,9 @@ pub fn collect_game_resources<'r>( (0x5B4D184E, FourCC::from_bytes(b"TXTR")), (0x563799A1, FourCC::from_bytes(b"TXTR")), (0xC11B62AF, FourCC::from_bytes(b"DCLN")), + (0x3852C9CF, FourCC::from_bytes(b"CMDL")), + (0x89CC3758, FourCC::from_bytes(b"DCLN")), + (0xA88267E6, FourCC::from_bytes(b"CMDL")), ]; looking_for.extend(bomb_slot_deps); diff --git a/src/generic_edit.rs b/src/generic_edit.rs index 0bb231ce..a28ab756 100644 --- a/src/generic_edit.rs +++ b/src/generic_edit.rs @@ -160,6 +160,10 @@ pub fn patch_edit_objects<'r> water.alpha_in_time *= value; water.alpha_out_time *= value; }, + structs::Thardus::OBJECT_TYPE => { + let thardus = obj.property_data.as_thardus_mut().unwrap(); + thardus.values[0] *= value; + }, _ => {}, } @@ -193,7 +197,18 @@ pub fn patch_edit_objects<'r> } if let Some(value) = config.health { - set_health(obj, value, None); + match obj.property_data.object_type() { + structs::Thardus::OBJECT_TYPE => { + let thardus = obj.property_data.as_thardus_mut().unwrap(); + thardus.values[3] *= value; + thardus.values[4] *= value; + }, + _ => {}, + } + + if obj.property_data.supports_health_infos() { + set_health(obj, value, None); + } } if let Some(values) = &config.healths {