#include <launcher.h>
Inheritance diagram for WeaponBullet:
Public Member Functions | |
WeaponBullet (const std::string &name, ExplosiveWeaponConfig &cfg, WeaponLauncher *p_launcher) | |
virtual | ~WeaponBullet () |
virtual void | Refresh () |
Protected Member Functions | |
virtual void | SignalGroundCollision () |
virtual void | SignalOutOfMap () |
virtual void | SignalObjectCollision (PhysicalObj *obj) |
void | DoExplosion () |
Definition at line 83 of file launcher.h.
WeaponBullet::WeaponBullet | ( | const std::string & | name, | |
ExplosiveWeaponConfig & | cfg, | |||
WeaponLauncher * | p_launcher | |||
) |
Definition at line 45 of file launcher.cpp.
00047 : 00048 WeaponProjectile(name, cfg, p_launcher) 00049 { 00050 explode_colliding_character = true; 00051 ResetTimeOut(); 00052 }
Here is the call graph for this function:
virtual WeaponBullet::~WeaponBullet | ( | ) | [inline, virtual] |
void WeaponBullet::DoExplosion | ( | ) | [protected, virtual] |
Reimplemented from WeaponProjectile.
Definition at line 87 of file launcher.cpp.
00088 { 00089 Point2i pos = GetCenter(); 00090 ApplyExplosion (pos, cfg, "", false, ParticleEngine::LittleESmoke); 00091 }
Here is the call graph for this function:
void WeaponBullet::Refresh | ( | ) | [virtual] |
Reimplemented from WeaponProjectile.
Definition at line 81 of file launcher.cpp.
00082 { 00083 WeaponProjectile::Refresh(); 00084 image->SetRotation_rad(GetSpeedAngle()); 00085 }
Here is the call graph for this function:
void WeaponBullet::SignalGroundCollision | ( | ) | [protected, virtual] |
Reimplemented from WeaponProjectile.
Definition at line 55 of file launcher.cpp.
00056 { 00057 jukebox.Play("share", "weapon/ricoche1"); 00058 WeaponProjectile::SignalGroundCollision(); 00059 launcher->IncMissedShots(); 00060 }
Here is the call graph for this function:
void WeaponBullet::SignalObjectCollision | ( | PhysicalObj * | obj | ) | [protected, virtual] |
Reimplemented from WeaponProjectile.
Definition at line 68 of file launcher.cpp.
00069 { 00070 if (typeid(*obj) != typeid(Character)) { 00071 obj->AddDamage(cfg.damage); 00072 Explosion(); 00073 } else { 00074 Character * tmp = (Character*)(obj); 00075 tmp -> SetEnergyDelta (-cfg.damage); 00076 tmp -> AddSpeed (2, GetSpeedAngle()); 00077 Ghost(); 00078 } 00079 }
Here is the call graph for this function:
void WeaponBullet::SignalOutOfMap | ( | ) | [protected, virtual] |
Reimplemented from WeaponProjectile.
Definition at line 62 of file launcher.cpp.
00063 { 00064 WeaponProjectile::SignalOutOfMap(); 00065 launcher->IncMissedShots(); 00066 }
Here is the call graph for this function: