blob: e85bc036f9ef589f0cdc393c98a0e3e1ca2b8778 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include <map>
extern "C" {
#include <lua.h>
#include <lauxlib.h>
#include <lualib.h>
}
#include <irrlicht.h>
#include "scene/icamera.hpp"
#include "scene/imesh.hpp"
#include "scene/ilight.hpp"
#include <shared/lua_api/common.hpp>
using namespace irr;
using namespace video;
using namespace scene;
extern IrrlichtDevice* device;
void load_scenefuncs(lua_State* L){
lua_newtable(L);//{}
lua_setglobal(L,"scene");//
//scene things
icamera_register(L);
imesh_register(L);
ilight_register(L);
//INode flags
set_const(L,EMF_WIREFRAME);
set_const(L,EDS_OFF);
set_const(L,EDS_BBOX);
set_const(L,EDS_NORMALS);
set_const(L,EDS_SKELETION);
set_const(L,EDS_MESH_WIRE_OVERLAY);
set_const(L,EDS_HALF_TRANSPARENCY);
set_const(L,EDS_BBOX_BUFFERS);
set_const(L,EDS_BBOX_ALL);
set_const(L,EDS_FULL);
//lua_pop(L, 1);
}
|