A lot more work on a bunch of different parts of the system.
This commit is contained in:
@@ -1,2 +1,32 @@
|
||||
use crate::dynamic_data::models::pokemon::Pokemon;
|
||||
use std::sync::Arc;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct ChoiceQueue {}
|
||||
pub struct ChoiceQueue {
|
||||
queue: Vec<Arc<ChoiceQueue>>,
|
||||
current: usize,
|
||||
}
|
||||
|
||||
impl ChoiceQueue {
|
||||
pub fn new(queue: Vec<Arc<ChoiceQueue>>) -> Self {
|
||||
Self { queue, current: 0 }
|
||||
}
|
||||
|
||||
pub fn dequeue(&mut self) -> &Arc<ChoiceQueue> {
|
||||
let c = &self.queue[self.current];
|
||||
self.current += 1;
|
||||
c
|
||||
}
|
||||
|
||||
pub fn peek(&mut self) -> &Arc<ChoiceQueue> {
|
||||
&self.queue[self.current]
|
||||
}
|
||||
|
||||
pub fn has_next(&self) -> bool {
|
||||
self.current < self.queue.len()
|
||||
}
|
||||
|
||||
pub fn move_pokemon_choice_next(&mut self, _pokemon: &Pokemon) {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user