Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4443 in orxonox.OLD for orxonox/trunk/src/util/loading


Ignore:
Timestamp:
Jun 1, 2005, 10:16:23 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: removed the old command node files and cleaned up the last references to them

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/util/loading/game_loader.cc

    r4411 r4443  
    2222#include "orxonox.h"
    2323#include "camera.h"
    24 #include "command_node.h"
    2524#include "vector.h"
    2625#include "resource_manager.h"
     
    3736GameLoader* GameLoader::singletonRef = 0;
    3837
    39 
     38/*
     39  \brief simple constructor
     40 */
    4041GameLoader::GameLoader ()
    4142{
     
    4445
    4546
     47/*
     48  \brief simple deconstructor
     49 */
    4650GameLoader::~GameLoader () {}
    4751
     
    132136}
    133137
     138
     139/**
     140    \brief starts the current entity
     141    \returns error code if this action has caused a error   
     142*/
    134143ErrorMessage GameLoader::start()
    135144{
     
    139148
    140149
     150/**
     151    \brief stops the current entity
     152    \returns error code if this action has caused a error
     153
     154    ATTENTION: this function shouldn't call other functions, or if so, they must return
     155    after finishing. If you ignore or forget to do so, the current entity is not able to
     156    terminate and it will run in the background or the ressources can't be freed or even
     157    worse: are freed and the program will end in a segmentation fault!
     158    hehehe, have ya seen it... :)
     159*/
    141160ErrorMessage GameLoader::stop()
    142161{
     
    147166
    148167
     168/**
     169    \brief pause the current entity
     170    \returns error code if this action has caused a error
     171
     172    this pauses the current entity or passes this call forth to the running entity.
     173*/
    149174ErrorMessage GameLoader::pause()
    150175{
     
    155180
    156181
     182/**
     183    \brief resumes a pause
     184    \returns error code if this action has caused a error
     185
     186    this resumess the current entity or passes this call forth to the running entity.
     187*/
    157188ErrorMessage GameLoader::resume()
    158189{
     
    161192    this->currentCampaign->resume();
    162193}
     194
    163195
    164196/**
     
    223255/**
    224256   \brief handle keyboard commands
    225    \param cmd: the command to handle
    226    \returns true if the command was handled by the system
    227 */
    228 bool GameLoader::worldCommand (Command* cmd)
    229 {
    230   if( !strcmp( cmd->cmd, CONFIG_NAME_NEXT_WORLD))
    231     {
    232       if( !cmd->bUp)
    233         {
    234           this->nextLevel();
    235         }
    236       return true;
    237     }
    238   else if( !strcmp( cmd->cmd, CONFIG_NAME_PREV_WORLD))
    239     {
    240       if( !cmd->bUp)
    241         {
    242           this->previousLevel();
    243         }
    244       return true;
    245     }
    246   else if( !strcmp( cmd->cmd, CONFIG_NAME_PAUSE))
    247     {
    248       if( !cmd->bUp)
    249         {
    250           if(this->isPaused)
    251             this->resume();
    252           else
    253             this->pause();
    254         }
    255       return true;
    256     }
    257   else if( !strcmp( cmd->cmd, CONFIG_NAME_QUIT))
    258     {
    259       if( !cmd->bUp) this->stop();
    260       return true;
    261     }
    262   return false;
    263 }
    264 
    265 
    266 
    267 
     257   \param the event to handle
     258*/
    268259void GameLoader::process(const Event& event)
    269260{
     
    298289}
    299290
     291
    300292/*
    301293  \brief this changes to the next level
     
    319311}
    320312
     313
    321314/**
    322315   \brief add a Factory to the Factory Q
     
    332325        else first->registerFactory( factory);
    333326}
     327
    334328
    335329/**
Note: See TracChangeset for help on using the changeset viewer.