mirror of
https://github.com/Noratrieb/game-wip-dontplay.git
synced 2026-01-16 12:25:02 +01:00
Make light offset of tiles variable
This commit is contained in:
parent
07c7d628ee
commit
79e2ba7b83
7 changed files with 71 additions and 33 deletions
|
|
@ -1,7 +1,7 @@
|
|||
use fnv::FnvHashSet;
|
||||
use sfml::window::{mouse, Event, Key};
|
||||
|
||||
use crate::graphics::ScreenPos;
|
||||
use crate::graphics::ScreenVec;
|
||||
|
||||
#[derive(Default, Debug)]
|
||||
pub struct Input {
|
||||
|
|
@ -9,7 +9,7 @@ pub struct Input {
|
|||
pressed: FnvHashSet<Key>,
|
||||
pub lmb_down: bool,
|
||||
pub rmb_down: bool,
|
||||
pub mouse_down_loc: ScreenPos,
|
||||
pub mouse_down_loc: ScreenVec,
|
||||
pub mid_pressed: bool,
|
||||
}
|
||||
|
||||
|
|
@ -24,7 +24,7 @@ impl Input {
|
|||
self.down.remove(code);
|
||||
}
|
||||
&Event::MouseButtonPressed { button, x, y } => {
|
||||
self.mouse_down_loc = ScreenPos {
|
||||
self.mouse_down_loc = ScreenVec {
|
||||
x: x as i16,
|
||||
y: y as i16,
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue