1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
use crate::command::Command;
use crate::position::Position;

#[derive(Debug, Clone)]
pub struct Shipyard {
    pub owner_id: u32,
    pub position: Position,
}

impl Shipyard {
    pub fn new(owner_id: u32, position: Position) -> Self {
        Shipyard { owner_id, position }
    }

    pub fn spawn(&self) -> Command {
        Command::Spawn
    }
}