GeezerVison is showing github.com — GitHub - tyroneneill/konami-manager-ts: Implementation of the Komani Manager (vanilla javascript) in TypeScript
Folders and files
| Name | Name | Last commit message | Last commit date |
|---|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
|
Repository files navigation
TypeScript konami manager

<script src="konami-manager.js"></script>
<script>
var konamiManager = new KonamiManager(window);
/**
* Attach Konami { ← ← a }
*/
konamiManager.add(attackFireball, [Keyboard.LEFT, Keyboard.LEFT, Keyboard.A]);
/**
* Attach Konami { → → a }
*/
konamiManager.add(attackIceball, [Keyboard.RIGHT, Keyboard.RIGHT, Keyboard.A]);
/**
* Attack Fireball callback handler
*/
function attackFireball() {
console.log('Fireball attack');
}
/**
* Attack Iceball callback handler
*/
function attackIceball() {
console.log('Iceball attack');
}
</script>
About
Implementation of the Komani Manager (vanilla javascript) in TypeScript
Resources
Stars
0 stars
Watchers
2 watching
Forks