Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 4, 2006, 2:43:20 PM (18 years ago)
Author:
bensch
Message:

added laser_cannon

File:
1 copied

Legend:

Unmodified
Added
Removed
  • branches/presentation/src/world_entities/weapons/laser_cannon.cc

    r9127 r9131  
    1 
    2 
    31/*
    42   orxonox - the future of 3D-vertical-scrollers
     
    2119#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON
    2220
    23 #include "test_gun.h"
     21#include "laser_cannon.h"
    2422#include "world_entities/projectiles/projectile.h"
    2523
     
    3331#include "fast_factory.h"
    3432
    35 CREATE_FACTORY(TestGun, CL_TEST_GUN);
     33CREATE_FACTORY(LaserCannon, CL_LASER_CANNON);
    3634
    3735/**
     
    4038   creates a new weapon
    4139*/
    42 TestGun::TestGun ( int leftRight)
     40LaserCannon::LaserCannon ( int leftRight)
    4341  : Weapon()
    4442{
     
    9189
    9290
    93 TestGun::TestGun(const TiXmlElement* root)
     91LaserCannon::LaserCannon(const TiXmlElement* root)
    9492{
    9593  this->init();
     
    10199 *  standard deconstructor
    102100*/
    103 TestGun::~TestGun ()
     101LaserCannon::~LaserCannon ()
    104102{
    105103  // model will be deleted from WorldEntity-destructor
     
    107105
    108106
    109 void TestGun::init()
    110 {
    111   this->setClassID(CL_TEST_GUN, "TestGun");
    112 
    113 //  this->model = (Model*)ResourceManager::getInstance()->load("models/guns/test_gun.obj", OBJ, RP_CAMPAIGN);
    114 
    115   this->loadModel("models/guns/test_gun.obj");
     107void LaserCannon::init()
     108{
     109  this->setClassID(CL_LASER_CANNON, "LaserCannon");
     110
     111//  this->model = (Model*)ResourceManager::getInstance()->load("models/guns/laser_cannon.obj", OBJ, RP_CAMPAIGN);
     112
     113  this->loadModel("models/guns/laser_cannon.obj");
    116114
    117115  this->setStateDuration(WS_SHOOTING, .1);
     
    135133
    136134
    137 void TestGun::loadParams(const TiXmlElement* root)
     135void LaserCannon::loadParams(const TiXmlElement* root)
    138136{
    139137  Weapon::loadParams(root);
     
    149147   been armed out.
    150148*/
    151 void TestGun::activate()
     149void LaserCannon::activate()
    152150{
    153151}
     
    161159   been armed out.
    162160*/
    163 void TestGun::deactivate()
     161void LaserCannon::deactivate()
    164162{
    165163}
     
    172170   @todo: the ObjectManager deliveres Projectiles not TestBullets! this should be diffrent
    173171*/
    174 void TestGun::fire()
     172void LaserCannon::fire()
    175173{
    176174  Projectile* pj =  this->getProjectile();
     
    192190 *  this will draw the weapon
    193191*/
    194 void TestGun::draw () const
     192void LaserCannon::draw () const
    195193{
    196194  /* draw gun body */
Note: See TracChangeset for help on using the changeset viewer.