1
0
Fork 0
mirror of https://github.com/doukutsu-rs/doukutsu-rs synced 2024-11-17 11:22:52 +00:00
doukutsu-rs/src/npc/first_cave.rs

26 lines
638 B
Rust
Raw Normal View History

2020-09-06 00:37:42 +00:00
use crate::ggez::GameResult;
use crate::npc::NPC;
use crate::player::Player;
use crate::SharedGameState;
impl NPC {
pub(crate) fn tick_n059_eye_door(&mut self, state: &mut SharedGameState, player: &Player) -> GameResult {
self.npc_flags.set_event_when_touched(true);
match self.action_num {
0 | 1 => {
if self.action_num == 0 {
self.action_num = 1;
}
self.anim_rect = state.constants.npc.n059_eye_door[self.anim_num as usize];
}
2 => {}
3 => {}
_ => {}
}
Ok(())
}
}