Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9916 in orxonox.OLD for trunk/src


Ignore:
Timestamp:
Nov 3, 2006, 9:29:16 PM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: Windows runs again without any segfaults
it seems, that windows links object files differently… and extremely strange

Location:
trunk/src/lib
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/script_engine/Makefile.am

    r9869 r9916  
    1313
    1414libORXscript_a_SOURCES = \
     15                script_class.cc \
     16                script_method.cc \
    1517                script.cc \
    1618                script_manager.cc \
    17                 script_class.cc \
    18                 script_method.cc \
    1919                executor_lua_state.cc
    2020
  • trunk/src/lib/script_engine/script.cc

    r9869 r9916  
    2424
    2525ObjectListDefinition(Script);
    26 
    27 CREATE_SCRIPTABLE_CLASS(Script,
    28                     addMethod("addObject", Executor2<Script, lua_State*,const std::string&, const std::string& >(&Script::addObject))
    29                     ->addMethod("registerClass", Executor1<Script, lua_State*,const std::string&>(&Script::registerClass))
    30                     ->addMethod("selectFunction", Executor2ret<Script, lua_State*, bool, const std::string&, int >(&Script::selectFunction))
    31                     ->addMethod("executeFunction", Executor0ret<Script, lua_State*,bool >(&Script::executeFunction))
    32                      );
    3326
    3427
  • trunk/src/lib/script_engine/script_class.cc

    r9897 r9916  
    1717
    1818#include "script_class.h"
     19#include "script.h"
     20#include "debug.h"
    1921#include <cassert>
    2022
    2123ObjectListDefinition(ScriptClass);
     24
     25CREATE_SCRIPTABLE_CLASS(Script,
     26                    addMethod("addObject", Executor2<Script, lua_State*,const std::string&, const std::string& >(&Script::addObject))
     27                    ->addMethod("registerClass", Executor1<Script, lua_State*,const std::string&>(&Script::registerClass))
     28                    ->addMethod("selectFunction", Executor2ret<Script, lua_State*, bool, const std::string&, int >(&Script::selectFunction))
     29                    ->addMethod("executeFunction", Executor0ret<Script, lua_State*,bool >(&Script::executeFunction))
     30                     );
    2231/**
    2332 * @brief standard constructor
     
    2736    : BaseObject(name), _classID(classID)
    2837{
     38  PRINTF(4)("Name %s\n", name.c_str());
    2939  assert(scriptMethods != NULL);
    3040  this->registerObject(this, ScriptClass::_objectList);
  • trunk/src/lib/shell/shell.cc

    r9869 r9916  
    3030namespace OrxShell
    3131{
    32 
    33   SHELL_COMMAND(clear, Shell, clear)
    34   ->describe("Clears the shell from unwanted lines (empties all buffers)")
    35   ->setAlias("clear");
    36   SHELL_COMMAND(deactivate, Shell, deactivate)
    37   ->describe("Deactivates the Shell. (moves it into background)")
    38   ->setAlias("hide");
    39   SHELL_COMMAND(textsize, Shell, setTextSize)
    40   ->describe("Sets the size of the Text size, linespacing")
    41   ->defaultValues(15, 0);
    42   SHELL_COMMAND(textcolor, Shell, setTextColor)
    43   ->describe("Sets the Color of the Shells Text (red, green, blue, alpha)")
    44   ->defaultValues(SHELL_DEFAULT_TEXT_COLOR);
    45   SHELL_COMMAND(backgroundcolor, Shell, setBackgroundColor)
    46   ->describe("Sets the Color of the Shells Background (red, green, blue, alpha)")
    47   ->defaultValues(SHELL_DEFAULT_BACKGROUND_COLOR);
    48   SHELL_COMMAND(backgroundimage, Shell, setBackgroundImage)
    49   ->describe("sets the background image to load for the Shell")
    50   ->completionPlugin(0, OrxShell::CompletorFileSystem());
    51   SHELL_COMMAND(font, Shell, setFont)
    52   ->describe("Sets the font of the Shell")
    53   ->defaultValues(SHELL_DEFAULT_FONT)
    54   ->completionPlugin(0, OrxShell::CompletorFileSystem(".ttf", "fonts/"));
    55 
    5632  ObjectListDefinition(Shell);
    5733
     
    557533    this->shellBuffer->debug();
    558534  }
    559 
    560   /**
    561    * @brief a Handy Function, to Test the behaviour of the Shell.
    562    */
    563   void Shell::testShell() const
    564   {
    565     for (unsigned int i = 0; i < 100; i++)
    566       PRINT(0)("%d\n", i);
    567   }
    568   SHELL_COMMAND(test, Shell, testShell);
    569 
    570535}
  • trunk/src/lib/shell/shell.h

    r9869 r9916  
    8282    void debug() const;
    8383
    84     void testShell() const;
    8584  private:
    8685    void updateResolution(unsigned int width);
  • trunk/src/lib/shell/shell_command.cc

    r9899 r9916  
    1919#include "shell_command_class.h"
    2020
     21#include "shell_input.h"
     22#include "shell.h"
     23
    2124#include "compiler.h"
    2225#include "helper_functions.h"
     
    2831{
    2932  ObjectListDefinition(ShellCommand);
     33
    3034  SHELL_COMMAND(debug, ShellCommandClass, help);
    3135
     36  SHELL_COMMAND(help, ShellInput, help)
     37  ->describe("retrieve some help about the input mode")
     38  ->setAlias("help");
     39
     40  SHELL_COMMAND(clear, Shell, clear)
     41  ->describe("Clears the shell from unwanted lines (empties all buffers)")
     42  ->setAlias("clear");
     43  SHELL_COMMAND(deactivate, Shell, deactivate)
     44  ->describe("Deactivates the Shell. (moves it into background)")
     45  ->setAlias("hide");
     46  SHELL_COMMAND(textsize, Shell, setTextSize)
     47  ->describe("Sets the size of the Text size, linespacing")
     48  ->defaultValues(15, 0);
     49  SHELL_COMMAND(textcolor, Shell, setTextColor)
     50  ->describe("Sets the Color of the Shells Text (red, green, blue, alpha)")
     51  ->defaultValues(SHELL_DEFAULT_TEXT_COLOR);
     52  SHELL_COMMAND(backgroundcolor, Shell, setBackgroundColor)
     53  ->describe("Sets the Color of the Shells Background (red, green, blue, alpha)")
     54  ->defaultValues(SHELL_DEFAULT_BACKGROUND_COLOR);
     55  SHELL_COMMAND(backgroundimage, Shell, setBackgroundImage)
     56  ->describe("sets the background image to load for the Shell")
     57  ->completionPlugin(0, OrxShell::CompletorFileSystem());
     58  SHELL_COMMAND(font, Shell, setFont)
     59  ->describe("Sets the font of the Shell")
     60  ->defaultValues(SHELL_DEFAULT_FONT)
     61  ->completionPlugin(0, OrxShell::CompletorFileSystem(".ttf", "fonts/"));
    3262
    3363  /**
     
    3969  ShellCommand::ShellCommand(const std::string& commandName, const std::string& className, Executor<const SubString>* executor)
    4070  {
     71    PRINTF(4)("create shellcommand '%s' for class '%s'\n", commandName.c_str(), className.c_str());
    4172    this->registerObject(this, ShellCommand::_objectList);
    42     PRINTF(4)("create shellcommand '%s' for class '%s'\n", commandName.c_str(), className.c_str());
    4373    this->setName(commandName);
    4474
  • trunk/src/lib/shell/shell_input.cc

    r9869 r9916  
    2828namespace OrxShell
    2929{
    30   SHELL_COMMAND(help, ShellInput, help)
    31   ->describe("retrieve some help about the input mode")
    32   ->setAlias("help");
    33 
    3430  ObjectListDefinition(ShellInput);
    3531
Note: See TracChangeset for help on using the changeset viewer.