Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 1084


Ignore:
Timestamp:
Apr 16, 2008, 9:22:50 PM (16 years ago)
Author:
rgrieder
Message:
  • updated VC++ files for tolua
  • minor CMLs changes
Location:
code/trunk
Files:
16 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/CMakeLists.txt

    r1076 r1084  
    9393#generate lua bind source files
    9494EXECUTE_PROCESS(COMMAND bin/./tolua-exec-script)
    95 EXECUTE_PROCESS(COMMAND ls)
    9695
    9796#add main source dir
  • code/trunk/bin/levels/sample.oxw

    r1052 r1084  
    115115
    116116<?lua
    117 for i = 1, 226, 1
     117for i = 1, 2, 1
    118118do ?>
    119119  <Model position="<?lua print(math.random(-19597, 18732))?>, <?lua print(math.random(-19597, 18732)) ?>, <?lua print(math.random(-19597, 18732)) ?>" scale="<?lua print(math.random( 20, 119)) ?>" mesh="ast<?lua print(i%6 + 1) ?>.mesh" rotationAxis="<?lua print(math.random()) ?>, <?lua print(math.random()) ?>, <?lua print(math.random()) ?>" rotationRate="<?lua print(math.random(16, 44)) ?>" />
  • code/trunk/src/core/CMakeLists.txt

    r1076 r1084  
    11#get the created files
    22AUX_SOURCE_DIRECTORY(tolua TOLUA_BIND_FILES)
    3 
    4 MESSAGE(STATUS "tolua sources: ${TOLUA_BIND_FILES}")
    53
    64SET( CORE_SRC_FILES
  • code/trunk/src/core/InputManager.cc

    r1066 r1084  
    3939#include "InputHandler.h"
    4040#include "InputBuffer.h"
     41#include "ConsoleCommand.h"
    4142
    4243namespace orxonox
    4344{
     45  ConsoleCommand(InputManager, setInputMode, AccessLevel::Admin, true).setDefaultValue(0, IM_INGAME);
     46
    4447  /**
    4548    @brief Constructor only resets the pointer values to 0.
     
    227230    @remark Only has an affect if the mode actually changes
    228231  */
    229   void InputManager::setInputMode(InputMode mode)
    230   {
    231     this->setMode_ = mode;
     232  void InputManager::setInputMode(int mode)
     233  {
     234    if (mode > 0 && mode < 4)
     235      getSingleton().setMode_ = (InputMode)mode;
    232236  }
    233237
  • code/trunk/src/core/InputManager.h

    r1066 r1084  
    7272    void tick(float dt);
    7373    void setWindowExtents(int width, int height);
    74     void setInputMode(InputMode mode);
    7574    InputMode getInputMode();
    7675
     
    8483    static InputManager& getSingleton();
    8584    static InputManager* getSingletonPtr() { return &getSingleton(); }
     85    static void setInputMode(int mode);
    8686
    8787  private:
  • code/trunk/src/orxonox/Orxonox.cc

    r1066 r1084  
    115115      {
    116116        this->ib_->removeLast();
     117      }
     118      void exit() const
     119      {
     120        CommandExecutor::execute("setInputMode 2");
    117121      }
    118122
     
    405409    ib->registerListener(console, &Testconsole::clear, '§', true);
    406410    ib->registerListener(console, &Testconsole::removeLast, '\b', true);
     411    ib->registerListener(console, &Testconsole::exit, (char)0x1B, true);
    407412
    408413    // first check whether ogre root object has been created
     
    452457      {
    453458        (it)->tick((float)evt.timeSinceLastFrame * this->timefactor_);
    454          it++;
    455      }
     459        it++;
     460      }
    456461
    457462      // don't forget to call _fireFrameStarted in ogre to make sure
  • code/trunk/src/util/CMakeLists.txt

    r1076 r1084  
    11AUX_SOURCE_DIRECTORY(tinyxml TINYXML_SRC_FILES)
    2 AUX_SOURCE_DIRECTORY(tolua   TOLUA_SRC_FILES)
    32
    43SET (UTIL_SRC_FILES
     
    1110  MultiTypeString.cc
    1211  MultiTypeMath.cc
     12  tolua_event.c
     13  tolua_is.c
     14  tolua_map.c
     15  tolua_push.c
     16  tolua_to.c
    1317  ${TINYXML_SRC_FILES}
    14   ${TOLUA_SRC_FILES}
    1518)
    1619
  • code/trunk/visual_studio/base_properties.vsprops

    r1059 r1084  
    88        <Tool
    99                Name="VCCLCompilerTool"
    10                 AdditionalIncludeDirectories="&quot;$(RootDir)src&quot;;&quot;$(RootDir)src\orxonox&quot;;&quot;$(DependencyDir)include&quot;"
     10                AdditionalIncludeDirectories="&quot;$(RootDir)src&quot;;&quot;$(RootDir)src\orxonox&quot;;&quot;$(RootDir)src\util\tolua&quot;;&quot;$(DependencyDir)include&quot;"
    1111                PreprocessorDefinitions="WIN32;__WIN32__;_WIN32;BOOST_ALL_DYN_LINK;OIS_DYNAMIC_LIB; ZLIB_WINAPI"
    1212                WarningLevel="3"
  • code/trunk/visual_studio/base_properties_debug.vsprops

    r1024 r1084  
    1313                BasicRuntimeChecks="3"
    1414                RuntimeLibrary="3"
    15                 DebugInformationFormat="4"
     15                DebugInformationFormat="3"
    1616        />
    1717        <Tool
  • code/trunk/visual_studio/core_properties.vsprops

    r1024 r1084  
    1212        <Tool
    1313                Name="VCLinkerTool"
    14                 AdditionalDependencies="OgreMain$(CS).lib OIS$(CSS).lib lua$(CS).lib"
     14                AdditionalDependencies="OgreMain$(CSS).lib OIS$(CS).lib lua51$(CS).lib"
    1515        />
    1616</VisualStudioPropertySheet>
  • code/trunk/visual_studio/network_properties.vsprops

    r1024 r1084  
    1212        <Tool
    1313                Name="VCLinkerTool"
    14                 AdditionalDependencies="enet$(CSS).lib zlib$(CSS).lib"
     14                AdditionalDependencies="enet$(CS).lib zlib$(CS).lib"
    1515                IgnoreDefaultLibraryNames="LIBCMT;LIBCMTD"
    1616        />
  • code/trunk/visual_studio/orxonox_properties.vsprops

    r1024 r1084  
    1414        <Tool
    1515                Name="VCLinkerTool"
    16                 AdditionalDependencies="OgreMain$(CS).lib OIS$(CSS).lib"
     16                AdditionalDependencies="OgreMain$(CSS).lib OIS$(CS).lib"
    1717                OutputFile="$(OutDir)$(ProjectName)$(CS).exe"
    1818                IgnoreDefaultLibraryNames=""
  • code/trunk/visual_studio/tolua++_properties.vsprops

    r1024 r1084  
    66        InheritedPropertySheets=".\directory_properties.vsprops"
    77        >
    8         <Tool
    9                 Name="VCLinkerTool"
    10                 AdditionalDependencies="lua$(CS).lib"
    11         />
    128</VisualStudioPropertySheet>
  • code/trunk/visual_studio/util_properties.vsprops

    r890 r1084  
    1212        <Tool
    1313                Name="VCLinkerTool"
    14                 AdditionalDependencies="OgreMain$(CS).lib"
     14                AdditionalDependencies="OgreMain$(CSS).lib"
    1515        />
    1616</VisualStudioPropertySheet>
  • code/trunk/visual_studio/vc8/core.vcproj

    r1059 r1084  
    249249                        </File>
    250250                        <File
    251                                 RelativePath="..\..\src\core\ToLuaBind.cc"
    252                                 >
    253                         </File>
    254                         <File
    255251                                RelativePath="..\..\src\core\XMLPort.cc"
    256252                                >
    257253                        </File>
     254                        <Filter
     255                                Name="tolua"
     256                                >
     257                                <File
     258                                        RelativePath="..\..\src\core\tolua\tolua_bind.cc"
     259                                        >
     260                                        <FileConfiguration
     261                                                Name="Debug|Win32"
     262                                                >
     263                                                <Tool
     264                                                        Name="VCCLCompilerTool"
     265                                                />
     266                                        </FileConfiguration>
     267                                </File>
     268                        </Filter>
    258269                </Filter>
    259270                <Filter
     
    411422                        </File>
    412423                        <File
    413                                 RelativePath="..\..\src\core\ToLuaBind.h"
    414                                 >
    415                         </File>
    416                         <File
    417424                                RelativePath="..\..\src\core\XMLPort.h"
    418425                                >
    419426                        </File>
     427                        <Filter
     428                                Name="tolua"
     429                                >
     430                                <File
     431                                        RelativePath="..\..\src\core\tolua\tolua_bind.h"
     432                                        >
     433                                </File>
     434                        </Filter>
    420435                </Filter>
    421436        </Files>
  • code/trunk/visual_studio/vc8/tolua++.vcproj

    r1064 r1084  
    133133                                RelativePath="..\..\src\util\tolua\tolua.c"
    134134                                >
     135                                <FileConfiguration
     136                                        Name="Debug|Win32"
     137                                        ExcludedFromBuild="true"
     138                                        >
     139                                        <Tool
     140                                                Name="VCCLCompilerTool"
     141                                        />
     142                                </FileConfiguration>
    135143                        </File>
    136144                        <File
     
    157165                                RelativePath="..\..\src\util\tolua\toluabind.c"
    158166                                >
     167                                <FileConfiguration
     168                                        Name="Debug|Win32"
     169                                        ExcludedFromBuild="true"
     170                                        >
     171                                        <Tool
     172                                                Name="VCCLCompilerTool"
     173                                        />
     174                                </FileConfiguration>
    159175                        </File>
    160176                </Filter>
Note: See TracChangeset for help on using the changeset viewer.