BazookaRocket Class Reference

#include <bazooka.h>

Inheritance diagram for BazookaRocket:

Inheritance graph
[legend]
Collaboration diagram for BazookaRocket:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 BazookaRocket (ExplosiveWeaponConfig &cfg, WeaponLauncher *p_launcher)
void Refresh ()

Protected Member Functions

void SignalOutOfMap ()
void SignalDrowning ()

Private Attributes

ParticleEngine smoke_engine

Detailed Description

Definition at line 26 of file bazooka.h.


Constructor & Destructor Documentation

BazookaRocket::BazookaRocket ( ExplosiveWeaponConfig cfg,
WeaponLauncher p_launcher 
)

Definition at line 34 of file bazooka.cpp.

00035                                                               :
00036   WeaponProjectile ("rocket", cfg,p_launcher), smoke_engine(20)
00037 {
00038   explode_colliding_character = true;
00039 }


Member Function Documentation

void BazookaRocket::Refresh (  )  [virtual]

Reimplemented from WeaponProjectile.

Definition at line 41 of file bazooka.cpp.

00042 {
00043   WeaponProjectile::Refresh();
00044   if(!IsDrowned())
00045   {
00046     image->SetRotation_rad(GetSpeedAngle());
00047     smoke_engine.AddPeriodic(Point2i(GetX() + GetWidth() / 2,
00048                                      GetY() + GetHeight()/ 2), particle_DARK_SMOKE, false, -1, 2.0);
00049   }
00050   else
00051   {
00052     image->SetRotation_rad(M_PI_2);
00053   }
00054 }

Here is the call graph for this function:

void BazookaRocket::SignalDrowning (  )  [protected, virtual]

Reimplemented from WeaponProjectile.

Definition at line 62 of file bazooka.cpp.

00063 {
00064   smoke_engine.Stop();
00065   WeaponProjectile::SignalDrowning();
00066 }

Here is the call graph for this function:

void BazookaRocket::SignalOutOfMap (  )  [protected, virtual]

Reimplemented from WeaponProjectile.

Definition at line 56 of file bazooka.cpp.

00057 {
00058   GameMessages::GetInstance()->Add (_("The rocket has left the battlefield..."));
00059   WeaponProjectile::SignalOutOfMap();
00060 }

Here is the call graph for this function:


Member Data Documentation

ParticleEngine BazookaRocket::smoke_engine [private]

Definition at line 28 of file bazooka.h.


The documentation for this class was generated from the following files:
Generated on Mon Jan 1 13:35:22 2007 for Wormux by  doxygen 1.4.7