/*-----------------------------------------------------------------------------* | headerfile MInput.h | | | | version 1.10 | | date: (29.04.2007) | | | | author: Michal vantner | | | | for Irrlicht engine | | store keyboard and mouse input in structures "key" and "mouse" | *-----------------------------------------------------------------------------*/ #ifndef MINPUT_H #define MINPUT_H #include "irrlicht/irrlicht.h" using namespace irr; struct IKeys { bool pressed(EKEY_CODE keycode) { return code[keycode]; } bool pressed_once(EKEY_CODE keycode) { if(code[keycode]) { code[keycode] = false; return true; } return false; } void reset() { for(s32 i=0; i