28 lines
520 B
Rust
28 lines
520 B
Rust
|
use crate::*;
|
||
|
|
||
|
use std::sync::Arc;
|
||
|
|
||
|
use super::super::traits::*;
|
||
|
|
||
|
pub struct MapRightSide {
|
||
|
snippet: Arc<GuiSnippet>,
|
||
|
}
|
||
|
|
||
|
impl MapRightSide {
|
||
|
pub fn new(game_handle: &GameHandle, path: &str) -> Result<Self> {
|
||
|
let snippet = game_handle.gui_snippet(path)?;
|
||
|
|
||
|
Ok(Self { snippet })
|
||
|
}
|
||
|
}
|
||
|
|
||
|
impl RightSide for MapRightSide {
|
||
|
fn refresh(&mut self, _game_handle: &GameHandle, _hero: Entity) -> Result<()> {
|
||
|
Ok(())
|
||
|
}
|
||
|
|
||
|
fn base(&self) -> &Arc<GuiSnippet> {
|
||
|
&self.snippet
|
||
|
}
|
||
|
}
|