Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 31, 2010, 3:37:40 AM (14 years ago)
Author:
landauf
Message:

merged consolecommands3 branch back to trunk.

note: the console command interface has changed completely, but the documentation is not yet up to date. just copy an existing command and change it to your needs, it's pretty self-explanatory. also the include files related to console commands are now located in core/command/. in the game it should work exactly like before, except for some changes in the auto-completion.

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/util/OutputHandler.h

    r6105 r7284  
    104104
    105105            //! Writes to all output devices
    106             static inline const std::string& log(const std::string& text)
    107                 { OutputHandler::getOutStream(0).output(text) << std::endl; return text; }
     106            static inline void log(const std::string& text)
     107                { OutputHandler::getOutStream(0).output(text) << std::endl; }
    108108
    109109            //! Writes an error message to the output
    110             static inline const std::string& error(const std::string& text)
    111                 { OutputHandler::getOutStream(1).output(text) << std::endl; return text; }
     110            static inline void error(const std::string& text)
     111                { OutputHandler::getOutStream(1).output(text) << std::endl; }
    112112
    113113            //! Writes a warning message to the output
    114             static inline const std::string& warning(const std::string& text)
    115                 { OutputHandler::getOutStream(2).output(text) << std::endl; return text; }
     114            static inline void warning(const std::string& text)
     115                { OutputHandler::getOutStream(2).output(text) << std::endl; }
    116116
    117117            //! Writes an informational message to the output
    118             static inline const std::string& info(const std::string& text)
    119                 { OutputHandler::getOutStream(3).output(text) << std::endl; return text; }
     118            static inline void info(const std::string& text)
     119                { OutputHandler::getOutStream(3).output(text) << std::endl; }
    120120
    121121            //! Writes a debug message to the output
    122             static inline const std::string& debug(const std::string& text)
    123                 { OutputHandler::getOutStream(4).output(text) << std::endl; return text; }
     122            static inline void debug(const std::string& text)
     123                { OutputHandler::getOutStream(4).output(text) << std::endl; }
    124124
    125125            //! Registers an object that receives output via a provided std::ostream
Note: See TracChangeset for help on using the changeset viewer.