#include "stdafx.h"

#include "lua.hpp"

extern "C" 
{
	static int test(lua_State* state)
	{
		lua_pushnumber(state, 1);
		return 1;
	}

	static const struct luaL_Reg cfunctions[] = {
		{"test", test},
		{NULL, NULL}
	};

	int __declspec(dllexport) luaopen_fpscui(lua_State* state) 
	{
		luaL_newlibtable(state, cfunctions);
		luaL_setfuncs(state, cfunctions, 0);
		return 1;
	}
}