summaryrefslogtreecommitdiff
path: root/src/entities/home.rs
blob: 6f7f53dc084e083d64c68bee55bcf7bddd91805d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
use geometry::*;
use hitbox::*;

#[derive(Debug, Clone)]
pub struct Home {
    pub pos: Vec2d
}

impl Home {
    pub fn new(x: f64, y: f64) -> Home {
        Home {
            pos: Vec2d {
                x: x,
                y: y
            }
        }
    }
}

impl CircleHitbox for Home {
    fn pos(&self) -> Vec2d {
        self.pos
    }
    fn radius(&self) -> f64 {
        100.
    }
}