1
0
Fork 0
mirror of https://github.com/doukutsu-rs/doukutsu-rs synced 2024-11-25 23:12:56 +00:00

Fixed basu spawn location

This commit is contained in:
dawnDus 2022-03-19 22:21:21 -04:00
parent 99d7ef67e0
commit 675e321d8f
No known key found for this signature in database
GPG key ID: 972AABDE81848F21

View file

@ -576,7 +576,7 @@ impl NPC {
self.tsc_direction = self.direction as u16; self.tsc_direction = self.direction as u16;
self.npc_flags.set_shootable(true); self.npc_flags.set_shootable(true);
self.x = player.x + self.direction.vector_x() * 16 * 0x2000; self.x = player.x + self.direction.opposite().vector_x() * 16 * 0x2000;
self.vel_x = self.direction.vector_x() * 0x2ff; self.vel_x = self.direction.vector_x() * 0x2ff;
} else { } else {
self.anim_rect = Rect::new(0, 0, 0, 0); self.anim_rect = Rect::new(0, 0, 0, 0);
@ -1234,7 +1234,7 @@ impl NPC {
self.tsc_direction = self.direction as u16; self.tsc_direction = self.direction as u16;
self.npc_flags.set_shootable(true); self.npc_flags.set_shootable(true);
self.x = player.x + self.direction.vector_x() * 16 * 0x2000; self.x = player.x + self.direction.opposite().vector_x() * 16 * 0x2000;
self.vel_x = self.direction.vector_x() * 0x2ff; self.vel_x = self.direction.vector_x() * 0x2ff;
} else { } else {
self.anim_rect = Rect::new(0, 0, 0, 0); self.anim_rect = Rect::new(0, 0, 0, 0);