Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

ParaShoot Class Reference

#include </home/clem/local/src/opie/noncore/games/parashoot/interface.h>

Collaboration diagram for ParaShoot:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ParaShoot (QWidget *parent=0, const char *name=0, WFlags f=0)
void clear ()
void gameOver ()
void levelUp ()
void moveFaster ()

Static Public Member Functions

static QString appName ()

Public Attributes

int mancount

Protected Member Functions

virtual void keyPressEvent (QKeyEvent *)
virtual void keyReleaseEvent (QKeyEvent *)
virtual void resizeEvent (QResizeEvent *e)
virtual void focusOutEvent (QFocusEvent *)
virtual void focusInEvent (QFocusEvent *)

Private Slots

void increaseScore (int)
void newGame ()
void play ()
void wait ()

Private Member Functions

void showScore (int score, int level)

Private Attributes

QCanvasView * pb
QCanvas canvas
Cannoncannon
Basebase
QLabel * levelscore
int nomen
int level
int oldscore
int updatespeed
QTimer * autoDropTimer
QTimer * pauseTimer
bool gamestopped
bool waitover
Sound fanfare
int score
int lastcannonkey

Constructor & Destructor Documentation

ParaShoot::ParaShoot QWidget *  parent = 0,
const char *  name = 0,
WFlags  f = 0
 

Definition at line 31 of file interface.cpp.

References QPEApplication::AlwaysOff, autoDropTimer, canvas, FALSE, QPEApplication::grabKeyboard(), levelscore, Opie::Core::OResource::loadPixmap(), newGame(), pauseTimer, pb, play(), qApp, QPEApplication::setInputMethodHint(), showScore(), Opie::Core::OResource::SmallIcon, tr, TRUE, updatespeed, and wait().


Member Function Documentation

static QString ParaShoot::appName  )  [inline, static]
 

Definition at line 42 of file interface.h.

References QString::fromLatin1().

void ParaShoot::clear  ) 
 

Definition at line 143 of file interface.cpp.

References autoDropTimer, canvas, and l.

Referenced by newGame().

void ParaShoot::focusInEvent QFocusEvent *   )  [protected, virtual]
 

Definition at line 106 of file interface.cpp.

References canvas, gamestopped, and updatespeed.

void ParaShoot::focusOutEvent QFocusEvent *   )  [protected, virtual]
 

Definition at line 100 of file interface.cpp.

References canvas, and gamestopped.

void ParaShoot::gameOver  ) 
 

Definition at line 153 of file interface.cpp.

References autoDropTimer, cannon, canvas, gamestopped, Bullet::getShotCount(), l, pauseTimer, score, Cannon::shotsFired(), Helicopter::silenceAll(), tr, and waitover.

Referenced by play().

void ParaShoot::increaseScore int   )  [private, slot]
 

Definition at line 204 of file interface.cpp.

References level, levelUp(), score, and showScore().

Referenced by newGame().

void ParaShoot::keyPressEvent QKeyEvent *   )  [protected, virtual]
 

Definition at line 242 of file interface.cpp.

References cannon, gamestopped, Key_F1, Key_F9, lastcannonkey, Cannon::Left, newGame(), Cannon::Right, Cannon::shoot(), and waitover.

void ParaShoot::keyReleaseEvent QKeyEvent *   )  [protected, virtual]
 

Definition at line 276 of file interface.cpp.

References cannon, lastcannonkey, Cannon::NoDir, and Cannon::pointCannon().

void ParaShoot::levelUp  ) 
 

Definition at line 212 of file interface.cpp.

References canvas, fanfare, level, moveFaster(), nomen, Sound::play(), and Bullet::setLimit().

Referenced by increaseScore().

void ParaShoot::moveFaster  ) 
 

Definition at line 233 of file interface.cpp.

References canvas, and updatespeed.

Referenced by levelUp().

void ParaShoot::newGame  )  [private, slot]
 

Definition at line 118 of file interface.cpp.

References autoDropTimer, base, cannon, canvas, clear(), Helicopter::deleteAll(), gamestopped, increaseScore(), nomen, pauseTimer, score, Bullet::setLimit(), Man::setManCount(), Bullet::setNobullets(), Bullet::setShotCount(), showScore(), updatespeed, and waitover.

Referenced by keyPressEvent(), and ParaShoot().

void ParaShoot::play  )  [private, slot]
 

Definition at line 193 of file interface.cpp.

References Base::baseDestroyed(), canvas, gameOver(), Man::getManCount(), and nomen.

Referenced by ParaShoot().

void ParaShoot::resizeEvent QResizeEvent *  e  )  [protected, virtual]
 

Definition at line 78 of file interface.cpp.

References base, cannon, canvas, Opie::Core::OResource::loadImage(), and s.

void ParaShoot::showScore int  score,
int  level
[private]
 

Definition at line 112 of file interface.cpp.

References levelscore, and tr.

Referenced by increaseScore(), newGame(), and ParaShoot().

void ParaShoot::wait  )  [private, slot]
 

Definition at line 187 of file interface.cpp.

References pauseTimer, and waitover.

Referenced by ParaShoot().


Member Data Documentation

QTimer* ParaShoot::autoDropTimer [private]
 

Definition at line 75 of file interface.h.

Referenced by clear(), gameOver(), newGame(), and ParaShoot().

Base* ParaShoot::base [private]
 

Definition at line 69 of file interface.h.

Referenced by newGame(), and resizeEvent().

Cannon* ParaShoot::cannon [private]
 

Definition at line 68 of file interface.h.

Referenced by gameOver(), keyPressEvent(), keyReleaseEvent(), newGame(), and resizeEvent().

QCanvas ParaShoot::canvas [private]
 

Definition at line 67 of file interface.h.

Referenced by clear(), focusInEvent(), focusOutEvent(), gameOver(), levelUp(), moveFaster(), newGame(), ParaShoot(), play(), and resizeEvent().

Sound ParaShoot::fanfare [private]
 

Definition at line 79 of file interface.h.

Referenced by levelUp().

bool ParaShoot::gamestopped [private]
 

Definition at line 77 of file interface.h.

Referenced by focusInEvent(), focusOutEvent(), gameOver(), keyPressEvent(), and newGame().

int ParaShoot::lastcannonkey [private]
 

Definition at line 81 of file interface.h.

Referenced by keyPressEvent(), and keyReleaseEvent().

int ParaShoot::level [private]
 

Definition at line 72 of file interface.h.

Referenced by increaseScore(), and levelUp().

QLabel* ParaShoot::levelscore [private]
 

Definition at line 70 of file interface.h.

Referenced by ParaShoot(), and showScore().

int ParaShoot::mancount
 

Definition at line 47 of file interface.h.

int ParaShoot::nomen [private]
 

Definition at line 71 of file interface.h.

Referenced by levelUp(), newGame(), and play().

int ParaShoot::oldscore [private]
 

Definition at line 73 of file interface.h.

QTimer* ParaShoot::pauseTimer [private]
 

Definition at line 76 of file interface.h.

Referenced by gameOver(), newGame(), ParaShoot(), and wait().

QCanvasView* ParaShoot::pb [private]
 

Definition at line 66 of file interface.h.

Referenced by ParaShoot().

int ParaShoot::score [private]
 

Definition at line 80 of file interface.h.

Referenced by gameOver(), increaseScore(), and newGame().

int ParaShoot::updatespeed [private]
 

Definition at line 74 of file interface.h.

Referenced by focusInEvent(), moveFaster(), newGame(), and ParaShoot().

bool ParaShoot::waitover [private]
 

Definition at line 78 of file interface.h.

Referenced by gameOver(), keyPressEvent(), newGame(), and wait().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 17:44:16 2005 for OPIE by  doxygen 1.4.2