Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6827


Ignore:
Timestamp:
May 3, 2010, 11:20:00 AM (14 years ago)
Author:
scheusso
Message:

rocket does spawn and is visible now
however speed and scaling not yet correct

Location:
code/branches/rocket/src/modules/weapons
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/rocket/src/modules/weapons/projectiles/SimpleRocket.cc

    r6818 r6827  
    7676
    7777            Model* model = new Model(this);
    78             model->setMeshSource("Rocket.mesh");
     78            model->setMeshSource("rocket.mesh");
    7979            //model->scale(0.7f);
    8080            this->attach(model);
  • code/branches/rocket/src/modules/weapons/weaponmodes/SimpleRocketFire.cc

    r6814 r6827  
    6161    void SimpleRocketFire::fire()
    6262    {
    63         //SimpleRocket* rocket = new SimpleRocket(this);
    64                 RocketController* con = new RocketController(this);
     63        SimpleRocket* rocket = new SimpleRocket(this);
     64        RocketController* con = new RocketController(this);
    6565
    6666
    6767        this->computeMuzzleParameters(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn()->getAimPosition());
    68         con->getControllableEntity()->setOrientation(this->getMuzzleOrientation());
    69         con->getControllableEntity()->setPosition(this->getMuzzlePosition());
    70         /* rocket->setVelocity(this->getMuzzleDirection() * this->speed_);
    71         rocket->scale(2);
     68        rocket->setOrientation(this->getMuzzleOrientation());
     69        rocket->setPosition(this->getMuzzlePosition());
     70        rocket->scale(10);
     71        rocket->setVelocity(this->getMuzzleDirection() * this->speed_);
     72        rocket->setOwner(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn());
     73        rocket->setDamage(this->getDamage());
     74        //rocket->scale(2);
    7275
    73         rocket->setOwner(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn());
    74         rocket->setDamage(this->getDamage());*/
    7576    }
    7677}
Note: See TracChangeset for help on using the changeset viewer.