Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 9, 2009, 3:18:11 AM (15 years ago)
Author:
landauf
Message:

Several small adjustments in the weaponsystem (like additional const keyword, includes moved from .h to .cc where possible, …)

Firemode is now an unsigned int instead of an Enum. Instead of "fire" and "altFire" use "fire 0" and "fire 1"

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/weapons/src/orxonox/objects/controllers/HumanController.cc

    r2872 r2912  
    4646    SetConsoleCommand(HumanController, rotateRoll,    true).setAsInputCommand();
    4747    SetConsoleCommand(HumanController, fire,          true).keybindMode(KeybindMode::OnHold);
    48     SetConsoleCommand(HumanController, altFire,       true).keybindMode(KeybindMode::OnHold);
    4948    SetConsoleCommand(HumanController, boost,         true).keybindMode(KeybindMode::OnHold);
    5049    SetConsoleCommand(HumanController, greet,         true);
     
    109108    }
    110109
    111     void HumanController::fire()
     110    void HumanController::fire(unsigned int firemode)
    112111    {
    113112        if (HumanController::localController_s && HumanController::localController_s->controllableEntity_)
    114             HumanController::localController_s->controllableEntity_->fire(WeaponMode::fire);
    115     }
    116 
    117     void HumanController::altFire()
    118     {
    119         if (HumanController::localController_s && HumanController::localController_s->controllableEntity_)
    120             HumanController::localController_s->controllableEntity_->fire(WeaponMode::altFire);
     113            HumanController::localController_s->controllableEntity_->fire(firemode);
    121114    }
    122115
Note: See TracChangeset for help on using the changeset viewer.