Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Sep 27, 2009, 7:28:09 PM (15 years ago)
Author:
rgrieder
Message:

Moved Radar Management from GSLevel to Scene.

File:
1 edited

Legend:

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

    r5738 r5813  
    3636#include "infos/PlayerInfo.h"
    3737#include "overlays/Map.h"
     38#include "Radar.h"
     39#include "Scene.h"
    3840
    3941namespace orxonox
     
    5658    SetConsoleCommand(HumanController, dropItems,     true);
    5759    SetConsoleCommand(HumanController, useItem,       true);
     60    SetConsoleCommand(HumanController, cycleNavigationFocus,   true);
     61    SetConsoleCommand(HumanController, releaseNavigationFocus, true);
    5862
    5963    CreateUnloadableFactory(HumanController);
     
    200204            return NULL;
    201205    }
     206
     207    void HumanController::cycleNavigationFocus()
     208    {
     209        if (HumanController::localController_s && HumanController::localController_s->controllableEntity_)
     210            HumanController::localController_s->controllableEntity_->getScene()->getRadar()->cycleFocus();
     211    }
     212
     213    void HumanController::releaseNavigationFocus()
     214    {
     215        if (HumanController::localController_s && HumanController::localController_s->controllableEntity_)
     216            HumanController::localController_s->controllableEntity_->getScene()->getRadar()->releaseFocus();
     217    }
    202218}
Note: See TracChangeset for help on using the changeset viewer.