mirror of
https://github.com/doukutsu-rs/doukutsu-rs
synced 2025-05-20 13:52:39 +00:00
Add offset for Balfrog adds (Fixes #99)
This commit is contained in:
parent
e27d555bc6
commit
890c297437
|
@ -157,7 +157,7 @@ impl BossNPC {
|
|||
|
||||
let mut npc = NPC::create(110, &state.npc_table);
|
||||
npc.cond.set_alive(true);
|
||||
npc.x = self.parts[0].rng.range(4..16) as i32 * 0x2000;
|
||||
npc.x = (self.parts[0].rng.range(4..16) + state.constants.game.tile_offset_x) as i32 * 0x2000;
|
||||
npc.y = self.parts[0].rng.range(0..4) as i32 * 0x2000;
|
||||
npc.direction = Direction::FacingPlayer;
|
||||
|
||||
|
@ -325,7 +325,7 @@ impl BossNPC {
|
|||
let mut npc = NPC::create(110, &state.npc_table);
|
||||
for _ in 0..6 {
|
||||
npc.cond.set_alive(true);
|
||||
npc.x = self.parts[0].rng.range(4..16) as i32 * 0x2000;
|
||||
npc.x = (self.parts[0].rng.range(4..16) + state.constants.game.tile_offset_x) as i32 * 0x2000;
|
||||
npc.y = self.parts[0].rng.range(0..4) as i32 * 0x2000;
|
||||
npc.direction = Direction::FacingPlayer;
|
||||
|
||||
|
|
Loading…
Reference in a new issue