| Revision 88,
1.2 KB
checked in by knowknowledge, 4 years ago
(diff) |
|
Case sensitivity fixes
|
| Line | |
|---|
| 1 | /* |
|---|
| 2 | * Filename : lua.h |
|---|
| 3 | * Author(s) : Chris Thielen (chris@luethy.net) |
|---|
| 4 | * Date Created : Saturday, January 5, 2008 |
|---|
| 5 | * Last Modified : Saturday, January 5, 2008 |
|---|
| 6 | * Purpose : Provides abilities to load, store, and run Lua scripts |
|---|
| 7 | * Notes : To be used in conjunction with various other subsystems, A.I., GUI, etc. |
|---|
| 8 | */ |
|---|
| 9 | |
|---|
| 10 | #ifndef __H_LUA__ |
|---|
| 11 | #define __H_LUA__ |
|---|
| 12 | |
|---|
| 13 | #include "includes.h" |
|---|
| 14 | #include "Lua/src/lua.h" |
|---|
| 15 | #include "Lua/src/lualib.h" |
|---|
| 16 | #include "Lua/src/lauxlib.h" |
|---|
| 17 | #include "Sprites/spritemanager.h" |
|---|
| 18 | |
|---|
| 19 | class Lua { |
|---|
| 20 | public: |
|---|
| 21 | static bool Load( string filename ); |
|---|
| 22 | static bool Run( string line ); |
|---|
| 23 | static bool Update(); |
|---|
| 24 | static vector<string> GetOutput(); |
|---|
| 25 | |
|---|
| 26 | static void RegisterFunctions(); |
|---|
| 27 | static bool SetSpriteList(SpriteManager* the_sprites); |
|---|
| 28 | static SpriteManager* GetSpriteList(); |
|---|
| 29 | |
|---|
| 30 | static int console_echo(lua_State *L); |
|---|
| 31 | static int pause(lua_State *L); |
|---|
| 32 | static int unpause(lua_State *L); |
|---|
| 33 | static int getPlayer(lua_State *luaVM); |
|---|
| 34 | private: |
|---|
| 35 | static vector<string> buffer; |
|---|
| 36 | |
|---|
| 37 | static bool Init(); |
|---|
| 38 | static bool Close(); |
|---|
| 39 | |
|---|
| 40 | // Internal variables |
|---|
| 41 | static SpriteManager* my_sprites; |
|---|
| 42 | static lua_State *luaVM; |
|---|
| 43 | static bool luaInitialized; |
|---|
| 44 | }; |
|---|
| 45 | |
|---|
| 46 | #endif // __H_LUA__ |
|---|
Note: See
TracBrowser
for help on using the repository browser.