- Timestamp:
- Oct 6, 2015, 9:37:11 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/towerdefenseFabien/src/modules/weapons/weaponmodes/SplitGun.cc
r10606 r10627 56 56 this->numberOfSplits_ = 2; 57 57 this->numberOfChilds_ = 3; 58 this->splitTime_ = 0.3; 59 this->spread_ = 0.1; 58 this->splitTime_ = 0.3f; 59 this->spread_ = 0.1f; 60 this->damageReduction_ = 1.0f; 60 61 61 this->setMunitionName(" LaserMunition");62 this->setMunitionName("SplitMunition"); 62 63 this->setDefaultSound("sounds/Weapon_LightningGun.ogg"); 63 64 } … … 79 80 XMLPortParam(SplitGun, "splittime", setSplitTime, getSplitTime, xmlelement, mode); 80 81 XMLPortParam(SplitGun, "spread", setSpread, getSpread, xmlelement, mode); 82 XMLPortParam(SplitGun, "damagereduction", setDamageReduction, getDamageReduction, xmlelement, mode); 81 83 } 82 84 … … 95 97 projectile->setVelocity(this->getMuzzleDirection() * this->speed_); 96 98 97 // Pass important information to the projectile: Number of splits, Number of childs, split time, spread 99 // Pass important information to the projectile: Number of splits, Number of childs, split time, spread and the damage reduction 98 100 projectile->setNumberOfSplits(getNumberOfSplits()); 99 101 projectile->setNumberOfChilds(getNumberOfChilds()); 100 102 projectile->setSplitTime(getSplitTime()); 101 103 projectile->setSpread(getSpread()); 104 projectile->setDamageReduction(getDamageReduction()); 102 105 103 106 projectile->setShooter(this->getWeapon()->getWeaponPack()->getWeaponSystem()->getPawn());
Note: See TracChangeset
for help on using the changeset viewer.