diff options
| author | Freya Murphy <freya@freyacat.org> | 2025-11-14 23:30:05 -0500 |
|---|---|---|
| committer | Freya Murphy <freya@freyacat.org> | 2025-11-14 23:30:05 -0500 |
| commit | 65f5143d3e01e111afb960451e0741ddb37be240 (patch) | |
| tree | d59bc1e885aa31743fd87ebadab8e1728e2cd683 /graphics/src/lib.rs | |
| parent | graphics: use 32bit color for atlas (diff) | |
| download | DungeonCrawl-65f5143d3e01e111afb960451e0741ddb37be240.tar.gz DungeonCrawl-65f5143d3e01e111afb960451e0741ddb37be240.tar.bz2 DungeonCrawl-65f5143d3e01e111afb960451e0741ddb37be240.zip | |
graphics: add text message rendering (and sans ig)
Diffstat (limited to 'graphics/src/lib.rs')
| -rw-r--r-- | graphics/src/lib.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/graphics/src/lib.rs b/graphics/src/lib.rs index d12eac0..0fdcedb 100644 --- a/graphics/src/lib.rs +++ b/graphics/src/lib.rs @@ -32,8 +32,11 @@ pub enum Key { Down, Left, Right, + // Interact + Return, // Debug keys F3, + F4, // Unknown/Unused key Unknown(KeyboardKey), } @@ -51,8 +54,11 @@ impl From<KeyboardKey> for Key { K::KEY_DOWN => Self::Down, K::KEY_LEFT => Self::Left, K::KEY_RIGHT => Self::Right, + // Interact + K::KEY_ENTER => Self::Return, // Debug keys K::KEY_F3 => Self::F3, + K::KEY_F4 => Self::F4, // Unknown/Unused key _ => Self::Unknown(key), } @@ -71,8 +77,11 @@ impl From<Key> for KeyboardKey { Key::Down => Self::KEY_DOWN, Key::Left => Self::KEY_LEFT, Key::Right => Self::KEY_RIGHT, + // Interact + Key::Return => Self::KEY_ENTER, // Debug keys Key::F3 => Self::KEY_F3, + Key::F4 => Self::KEY_F4, // Unknown/Unused key Key::Unknown(k) => k, } |