1
0
Fork 0
mirror of https://github.com/doukutsu-rs/doukutsu-rs synced 2024-12-12 07:35:08 +00:00

bug / warning fixes

This commit is contained in:
Alula 2020-12-27 09:30:02 +01:00
parent 4ecb11e89d
commit 5949d51270
No known key found for this signature in database
GPG key ID: 3E00485503A1D8BA
2 changed files with 3 additions and 2 deletions

View file

@ -113,6 +113,7 @@ impl NPC {
if self.life <= 100 {
npc_list.create_death_smoke(self.x, self.y, self.display_bounds.right, 8, state, &self.rng);
state.sound_manager.play_sfx(25);
self.cond.set_alive(false);
let mut npc = NPC::create(45, &state.npc_table);
npc.cond.set_alive(true);

View file

@ -263,7 +263,7 @@ impl NPCList {
heart_pick.y = npc.y;
heart_pick.exp = if npc.exp > 6 { 6 } else { 2 };
let _ = self.spawn(0x100, heart_pick.clone());
let _ = self.spawn(0x100, heart_pick);
}
1 if can_drop_missile => {
let mut missile_pick = NPC::create(86, &state.npc_table);
@ -273,7 +273,7 @@ impl NPCList {
missile_pick.y = npc.y;
missile_pick.exp = if npc.exp > 6 { 3 } else { 1 };
let _ = self.spawn(0x100, missile_pick.clone());
let _ = self.spawn(0x100, missile_pick);
}
_ => {
npc.create_xp_drop(state, self);