#include </home/clem/local/src/opie/noncore/games/qasteroids/view.h>
Collaboration diagram for KAsteroidsView:

Signals | |
| void | shipKilled () |
| void | rockHit (int size) |
| void | rocksRemoved () |
| void | updateVitals () |
Public Member Functions | |
| KAsteroidsView (QWidget *parent=0, const char *name=0) | |
| virtual | ~KAsteroidsView () |
| void | reset () |
| void | setRockSpeed (double rs) |
| void | addRocks (int num) |
| void | newGame () |
| void | endGame () |
| void | newShip () |
| void | rotateLeft (bool r) |
| void | rotateRight (bool r) |
| void | thrust (bool t) |
| void | shoot (bool s) |
| void | setShield (bool s) |
| void | teleport (bool te) |
| void | brake (bool b) |
| void | pause (bool p) |
| void | showText (const QString &text, const QColor &color, bool scroll=TRUE) |
| void | hideText () |
| int | shots () const |
| int | hits () const |
| int | power () const |
| int | teleportCount () const |
| int | brakeCount () const |
| int | shieldCount () const |
| int | shootCount () const |
Public Attributes | |
| int | refreshRate |
Protected Member Functions | |
| void | readSprites () |
| void | wrapSprite (QCanvasItem *) |
| void | rockHit (QCanvasItem *) |
| void | reducePower (int val) |
| void | addExhaust (double x, double y, double dx, double dy, int count) |
| void | processMissiles () |
| void | processShip () |
| void | processPowerups () |
| void | processShield () |
| double | randDouble () |
| int | randInt (int range) |
| virtual void | resizeEvent (QResizeEvent *event) |
| virtual void | timerEvent (QTimerEvent *) |
Private Slots | |
| void | hideShield () |
Private Attributes | |
| QCanvas | field |
| QCanvasView | view |
| QIntDict< QCanvasPixmapArray > | animation |
| QPtrList< QCanvasSprite > | rocks |
| QPtrList< KMissile > | missiles |
| QPtrList< KBit > | bits |
| QPtrList< KExhaust > | exhaust |
| QPtrList< KPowerup > | powerups |
| KShield * | shield |
| QCanvasSprite * | ship |
| QCanvasText * | textSprite |
| bool | rotateL |
| bool | rotateR |
| bool | thrustShip |
| bool | shootShip |
| bool | teleportShip |
| bool | brakeShip |
| bool | pauseShip |
| bool | shieldOn |
| bool | vitalsChanged |
| int | shipAngle |
| int | rotateSlow |
| int | rotateRate |
| int | shipPower |
| int | shotsFired |
| int | shotsHit |
| int | shootDelay |
| int | mBrakeCount |
| int | mShieldCount |
| int | mTeleportCount |
| int | mShootCount |
| double | shipDx |
| double | shipDy |
| int | textDy |
| int | mFrameNum |
| bool | mPaused |
| int | mTimerId |
| double | rockSpeed |
| double | powerupSpeed |
| bool | can_destroy_powerups |
| QTimer * | shieldTimer |
|
||||||||||||
|
Definition at line 85 of file view.cpp. References bits, can_destroy_powerups, exhaust, FALSE, field, hideShield(), IMG_BACKGROUND, Opie::Core::OResource::loadPixmap(), MAX_POWER_LEVEL, missiles, mPaused, mTimerId, powerups, readSprites(), REFRESH_DELAY, refreshRate, rocks, QPtrCollection::setAutoDelete(), shield, shieldOn, shieldTimer, shipPower, textSprite, TRUE, view, and vitalsChanged. |
|
|
|
|
||||||||||||||||||||||||
|
Definition at line 521 of file view.cpp. References animation, QPtrList< type >::append(), exhaust, field, i, ID_EXHAUST, and randDouble(). Referenced by processShip(). |
|
|
Definition at line 270 of file view.cpp. References animation, QPtrList< type >::append(), field, i, ID_ROCK_MEDIUM, randDouble(), randInt(), rocks, and rockSpeed. Referenced by KAstTopLevel::slotNewGame(), and KAstTopLevel::slotRocksRemoved(). |
|
|
Definition at line 230 of file view.cpp. References brakeShip, FALSE, mBrakeCount, ROTATE_RATE, rotateL, rotateR, rotateRate, and thrustShip. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 73 of file view.h. References mBrakeCount. Referenced by KAstTopLevel::slotUpdateVitals(). |
|
|
Definition at line 172 of file view.cpp. Referenced by KAstTopLevel::slotShipKilled(). |
|
|
Definition at line 862 of file view.cpp. References FALSE, mShieldCount, shield, and shieldOn. Referenced by KAsteroidsView(), and setShield(). |
|
|
Definition at line 321 of file view.cpp. References TEXT_SPEED, and textDy. Referenced by KAstTopLevel::keyReleaseEvent(), and KAstTopLevel::slotNewGame(). |
|
|
Definition at line 69 of file view.h. References shotsHit. Referenced by KAstTopLevel::doStats(), processMissiles(), processPowerups(), and processShip(). |
|
|
Definition at line 157 of file view.cpp. References FALSE, mTimerId, REFRESH_DELAY, reset(), shield, shieldOn, and updateVitals(). Referenced by KAstTopLevel::slotNewGame(). |
|
|
Definition at line 190 of file view.cpp. References brakeShip, FALSE, field, MAX_POWER_LEVEL, mBrakeCount, mShieldCount, mShootCount, mTeleportCount, ROTATE_RATE, rotateL, rotateR, rotateRate, rotateSlow, shield, shieldOn, shieldTimer, ship, shipAngle, shipDx, shipDy, shipPower, shootDelay, shootShip, teleportShip, thrustShip, and TRUE. Referenced by KAstTopLevel::keyReleaseEvent(), and KAstTopLevel::slotNewGame(). |
|
|
Definition at line 176 of file view.cpp. References mPaused, mTimerId, and REFRESH_DELAY. Referenced by KAstTopLevel::focusInEvent(), KAstTopLevel::focusOutEvent(), KAstTopLevel::hideEvent(), and KAstTopLevel::showEvent(). |
|
|
Definition at line 70 of file view.h. References shipPower. Referenced by KAstTopLevel::slotUpdateVitals(). |
|
|
Definition at line 534 of file view.cpp. References QPtrListIterator< type >::current(), KMissile::expired(), KMissile::growOlder(), hits(), ID_ROCK_LARGE, ID_ROCK_SMALL, missiles, QPtrList< type >::removeRef(), rockHit(), shotsHit, TRUE, and wrapSprite(). Referenced by timerEvent(). |
|
|
Definition at line 787 of file view.cpp. References can_destroy_powerups, QPtrListIterator< type >::current(), KPowerup::expired(), KPowerup::growOlder(), hits(), ID_BRAKE_POWERUP, ID_ENERGY_POWERUP, ID_MISSILE, ID_SHIELD_POWERUP, ID_SHOOT_POWERUP, ID_TELEPORT_POWERUP, QPtrList< type >::isEmpty(), MAX_BRAKES, MAX_FIREPOWER, MAX_POWER_LEVEL, MAX_SHIELDS, mBrakeCount, mShieldCount, mShootCount, mTeleportCount, powerups, QPtrList< type >::removeRef(), shield, ship, shipPower, TRUE, vitalsChanged, and wrapSprite(). Referenced by timerEvent(). |
|
|
|
|
|
Definition at line 573 of file view.cpp. References addExhaust(), animation, QPtrList< type >::append(), bits, BRAKE_ON_COST, brakeShip, QPtrList< type >::count(), fabs(), FALSE, field, hits(), i, ID_BIT, ID_MISSILE, ID_ROCK_LARGE, ID_ROCK_MEDIUM, ID_ROCK_SMALL, M_PI, MAX_SHIP_SPEED, mBrakeCount, MISSILE_SPEED, missiles, mShieldCount, mShootCount, PI_X_2, randDouble(), randInt(), reducePower(), rockHit(), ROTATE_RATE, rotateL, rotateR, rotateRate, rotateSlow, KBit::setDeath(), shield, SHIELD_HIT_COST, SHIELD_ON_COST, shieldOn, ship, SHIP_STEPS, shipAngle, shipDx, shipDy, shipKilled(), shootDelay, shootShip, shotsFired, teleportShip, thrustShip, TRUE, and vitalsChanged. Referenced by timerEvent(). |
|
|
Definition at line 869 of file view.cpp. References v. Referenced by addExhaust(), addRocks(), processShip(), and rockHit(). |
|
|
Definition at line 875 of file view.cpp. Referenced by addRocks(), processShip(), and rockHit(). |
|
|
Definition at line 248 of file view.cpp. References animation, field, i, ID_SHIELD, ID_SHIP, QIntDict< type >::insert(), QPEApplication::qpeDir(), shield, and ship. Referenced by KAsteroidsView(). |
|
|
Definition at line 505 of file view.cpp. References FALSE, shield, shieldOn, shipPower, thrustShip, TRUE, and vitalsChanged. Referenced by processShip(). |
|
|
Definition at line 129 of file view.cpp. References bits, QPtrList< type >::clear(), exhaust, FALSE, mFrameNum, missiles, mPaused, powerups, powerupSpeed, rocks, rockSpeed, shield, ship, shotsFired, and shotsHit. Referenced by newGame(). |
|
|
|
|
|
Definition at line 416 of file view.cpp. References animation, QPtrList< type >::append(), QPtrList< type >::count(), field, i, ID_BRAKE_POWERUP, ID_ENERGY_POWERUP, ID_ROCK_LARGE, ID_ROCK_MEDIUM, ID_ROCK_SMALL, ID_SHIELD_POWERUP, ID_SHOOT_POWERUP, MAX_ROCK_SPEED, powerups, randDouble(), randInt(), QPtrList< type >::removeRef(), rockHit(), rocks, rockSpeed, and rocksRemoved(). |
|
|
Referenced by processMissiles(), processShip(), and rockHit(). |
|
|
Referenced by rockHit(). |
|
|
Definition at line 56 of file view.h. References rotateL, and rotateSlow. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 57 of file view.h. References rotateR, and rotateSlow. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 50 of file view.h. References rockSpeed. Referenced by KAstTopLevel::slotNewGame(), and KAstTopLevel::slotRocksRemoved(). |
|
|
Definition at line 220 of file view.cpp. References hideShield(), mShieldCount, shieldOn, and shieldTimer. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 74 of file view.h. References mShieldCount. Referenced by KAstTopLevel::slotUpdateVitals(). |
|
|
Referenced by processShip(). |
|
|
Definition at line 59 of file view.h. References shootDelay, and shootShip. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 75 of file view.h. References mShootCount. Referenced by KAstTopLevel::slotUpdateVitals(). |
|
|
Definition at line 68 of file view.h. References shotsFired. Referenced by KAstTopLevel::doStats(). |
|
||||||||||||||||
|
Definition at line 301 of file view.cpp. References field, TEXT_SPEED, textDy, and textSprite. Referenced by KAstTopLevel::doStats(), and KAstTopLevel::slotShipKilled(). |
|
|
Definition at line 61 of file view.h. References mTeleportCount, and teleportShip. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 72 of file view.h. References mTeleportCount. |
|
|
Definition at line 58 of file view.h. References shipPower, and thrustShip. Referenced by KAstTopLevel::keyPressEvent(), and KAstTopLevel::keyReleaseEvent(). |
|
|
Definition at line 337 of file view.cpp. References bits, exhaust, FALSE, field, QPtrList< type >::first(), mFrameNum, QPtrList< type >::next(), processMissiles(), processPowerups(), processShip(), QPtrList< type >::removeRef(), rocks, ship, textDy, textSprite, updateVitals(), vitalsChanged, and wrapSprite(). |
|
|
Referenced by newGame(), and timerEvent(). |
|
|
Definition at line 398 of file view.cpp. References field, Opie::MM::x, and Opie::MM::y. Referenced by processMissiles(), processPowerups(), and timerEvent(). |
|
|
Definition at line 105 of file view.h. Referenced by addExhaust(), addRocks(), processShip(), readSprites(), and rockHit(). |
|
|
Definition at line 108 of file view.h. Referenced by KAsteroidsView(), processShip(), reset(), and timerEvent(). |
|
|
Definition at line 120 of file view.h. Referenced by brake(), newShip(), and processShip(). |
|
|
Definition at line 151 of file view.h. Referenced by KAsteroidsView(), and processPowerups(). |
|
|
Definition at line 109 of file view.h. Referenced by addExhaust(), KAsteroidsView(), reset(), and timerEvent(). |
|
|
Definition at line 103 of file view.h. Referenced by addExhaust(), addRocks(), KAsteroidsView(), newShip(), processShip(), readSprites(), resizeEvent(), rockHit(), showText(), timerEvent(), and wrapSprite(). |
|
|
Definition at line 135 of file view.h. Referenced by brake(), brakeCount(), newShip(), processPowerups(), and processShip(). |
|
|
Definition at line 144 of file view.h. Referenced by reset(), and timerEvent(). |
|
|
Definition at line 107 of file view.h. Referenced by KAsteroidsView(), processMissiles(), processShip(), and reset(). |
|
|
Definition at line 145 of file view.h. Referenced by KAsteroidsView(), pause(), and reset(). |
|
|
Definition at line 136 of file view.h. Referenced by hideShield(), newShip(), processPowerups(), processShip(), setShield(), and shieldCount(). |
|
|
Definition at line 138 of file view.h. Referenced by newShip(), processPowerups(), processShip(), and shootCount(). |
|
|
Definition at line 137 of file view.h. Referenced by newShip(), processPowerups(), teleport(), and teleportCount(). |
|
|
Definition at line 146 of file view.h. Referenced by KAsteroidsView(), newGame(), and pause(). |
|
|
|
|
|
Definition at line 110 of file view.h. Referenced by KAsteroidsView(), processPowerups(), reset(), and rockHit(). |
|
|
Definition at line 149 of file view.h. Referenced by reset(). |
|
|
Definition at line 47 of file view.h. Referenced by KAsteroidsView(). |
|
|
Definition at line 106 of file view.h. Referenced by addRocks(), KAsteroidsView(), reset(), rockHit(), and timerEvent(). |
|
|
Definition at line 148 of file view.h. Referenced by addRocks(), reset(), rockHit(), and setRockSpeed(). |
|
|
Definition at line 115 of file view.h. Referenced by brake(), newShip(), processShip(), and rotateLeft(). |
|
|
Definition at line 116 of file view.h. Referenced by brake(), newShip(), processShip(), and rotateRight(). |
|
|
Definition at line 128 of file view.h. Referenced by brake(), newShip(), and processShip(). |
|
|
Definition at line 127 of file view.h. Referenced by newShip(), processShip(), rotateLeft(), and rotateRight(). |
|
|
Definition at line 111 of file view.h. Referenced by hideShield(), KAsteroidsView(), newGame(), newShip(), processPowerups(), processShip(), readSprites(), reducePower(), and reset(). |
|
|
Definition at line 122 of file view.h. Referenced by hideShield(), KAsteroidsView(), newGame(), newShip(), processShip(), reducePower(), and setShield(). |
|
|
Definition at line 153 of file view.h. Referenced by KAsteroidsView(), newShip(), and setShield(). |
|
|
Definition at line 112 of file view.h. Referenced by newShip(), processPowerups(), processShip(), readSprites(), reset(), and timerEvent(). |
|
|
Definition at line 126 of file view.h. Referenced by newShip(), and processShip(). |
|
|
Definition at line 140 of file view.h. Referenced by newShip(), and processShip(). |
|
|
Definition at line 141 of file view.h. Referenced by newShip(), and processShip(). |
|
|
Definition at line 129 of file view.h. Referenced by KAsteroidsView(), newShip(), power(), processPowerups(), reducePower(), and thrust(). |
|
|
Definition at line 133 of file view.h. Referenced by newShip(), processShip(), and shoot(). |
|
|
Definition at line 118 of file view.h. Referenced by newShip(), processShip(), and shoot(). |
|
|
Definition at line 131 of file view.h. Referenced by processShip(), reset(), and shots(). |
|
|
Definition at line 132 of file view.h. Referenced by hits(), processMissiles(), and reset(). |
|
|
Definition at line 119 of file view.h. Referenced by newShip(), processShip(), and teleport(). |
|
|
Definition at line 143 of file view.h. Referenced by hideText(), showText(), and timerEvent(). |
|
|
Definition at line 113 of file view.h. Referenced by KAsteroidsView(), showText(), and timerEvent(). |
|
|
Definition at line 117 of file view.h. Referenced by brake(), newShip(), processShip(), reducePower(), and thrust(). |
|
|
Definition at line 104 of file view.h. Referenced by KAsteroidsView(), and resizeEvent(). |
|
|
Definition at line 124 of file view.h. Referenced by KAsteroidsView(), processPowerups(), processShip(), reducePower(), and timerEvent(). |
1.4.2