Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 27, 2008, 10:56:51 PM (16 years ago)
Author:
rgrieder
Message:
  • Added support for dedicated server. Could not network test it yet, client still segfaults me.
  • Also kicked GraphicsEngine::levelSceneManager_, there are only the statistic methods left.
  • GSDedicated also derives from GSLevel, but GSLevel is not anymore a real GameState.
  • CameraHandler and LevelManager get created in GSLevel now.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/objecthierarchy/src/orxonox/gamestates/GSStandalone.cc

    r1989 r2023  
    3030#include "GSStandalone.h"
    3131
    32 #include "core/input/InputManager.h"
    33 #include "core/ConsoleCommand.h"
    3432#include "core/Core.h"
    3533
     
    3735{
    3836    GSStandalone::GSStandalone()
    39         : GSLevel("standalone")
     37        : GameState<GSGraphics>("standalone")
    4038    {
    4139    }
     
    4745    void GSStandalone::enter()
    4846    {
    49         GSLevel::enter();
     47        Core::setIsStandalone(true);
    5048
    51         Core::setIsStandalone(true);
    52         this->loadLevel();
    53 
    54         // add console commands
    55         FunctorMember<GSLevel>* functor = createFunctor(&GSLevel::setTimeFactor);
    56         functor->setObject(this);
    57         CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(functor, "setTimeFactor")).accessLevel(AccessLevel::Offline).defaultValue(0, 1.0);;
    58 
    59         // level is loaded: we can start capturing the input
    60         InputManager::getInstance().requestEnterState("game");
     49        GSLevel::enter(this->getParent()->getViewport());
    6150    }
    6251
    6352    void GSStandalone::leave()
    6453    {
    65         InputManager::getInstance().requestLeaveState("game");
    66 
    67         // TODO: Remove and destroy console command
    68 
    69         this->unloadLevel();
    70 
    7154        GSLevel::leave();
    7255
Note: See TracChangeset for help on using the changeset viewer.