OpenMortal Apocalypse mirror
Sourceforge mirror
SourceForge.net Logo
      News | Info | Characters | Arenas | Screenshots | Forums | Download  
Developer: Making of | Character-HOWTO | AI Design | Submit a Character
Documentation: Main Page | Modules | Class Hierarchy | Class List | File List

Event.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                           Event.h  -  description
00003                              -------------------
00004     begin                : Sat Feb 14 2004
00005     copyright            : (C) 2004 by upi
00006     email                : upi@feel
00007  ***************************************************************************/
00008 
00009 
00010 #ifndef EVENT_H
00011 #define EVENT_H
00012 
00013 
00014 enum TMortalEventEnum
00015 {
00016     Me_NOTHING,
00017     Me_QUIT,
00018     Me_MENU,
00019     Me_SKIP,
00020     Me_PLAYERKEYDOWN,
00021     Me_PLAYERKEYUP,
00022 };
00023 
00024 
00025 enum TMortalKeysEnum
00026 {
00027     Mk_UP       = 0,
00028     Mk_DOWN     = 1,
00029     Mk_LEFT     = 2,
00030     Mk_RIGHT    = 3,
00031     Mk_BLOCK    = 4,
00032     Mk_LPUNCH   = 5,
00033     Mk_HPUNCH   = 6,
00034     Mk_LKICK    = 7,
00035     Mk_HKICK    = 8,
00036 };
00037 
00041 struct SMortalEvent
00042 {
00043     TMortalEventEnum    m_enType;
00044     int                 m_iPlayer;
00045     int                 m_iKey;
00046 };
00047 
00048 bool TranslateEvent( const SDL_Event* a_poInSDLEvent, SMortalEvent* a_poOutEvent );
00049 bool MortalPollEvent( SMortalEvent& a_roOutEvent );
00050 void MortalWaitEvent( SMortalEvent& a_roOutEvent );
00051 
00052 
00053 #endif
00054