Skip to content
Snippets Groups Projects
Verified Commit 0f2d5179 authored by João Magalhães's avatar João Magalhães :rocket:
Browse files

feat: new validation

parent 3a6478e0
No related branches found
No related tags found
1 merge request!3Working version of the neo implementation 🥳
Pipeline #616 passed
......@@ -212,11 +212,17 @@ impl Chip8Neo {
}
pub fn key_press(&mut self, key: u8) {
if key >= KEYS_SIZE as u8 {
return;
}
self.keys[key as usize] = true;
self.last_key = key;
}
pub fn key_lift(&mut self, key: u8) {
if key >= KEYS_SIZE as u8 {
return;
}
self.keys[key as usize] = false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment