summaryrefslogtreecommitdiff
path: root/plugins/MirLua/src/mlua.cpp
blob: ee6d91e117a7f06f0fe81e49c733ac74117e5342 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include "stdafx.h"

CMLua::CMLua()
{
	lua = luaL_newstate();

	luaL_openlibs(lua);
	luaL_newlib(lua, CMLua::CoreFunctions);
	lua_setglobal(lua, "M");
}

CMLua::~CMLua()
{
	lua_close(lua);
}

void CMLua::Load(const char *name)
{
	luaL_dofile(lua, name);
}