You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
347 B
18 lines
347 B
2 weeks ago
|
#define SOL_ALL_SAFETIES_ON 1
|
||
|
#include <sol/sol.hpp>
|
||
|
|
||
|
#include <iostream>
|
||
|
|
||
|
int main(int, char*[]) {
|
||
|
std::cout << "=== opening a state ===" << std::endl;
|
||
|
|
||
|
sol::state lua;
|
||
|
// open some common libraries
|
||
|
lua.open_libraries(sol::lib::base, sol::lib::package);
|
||
|
lua.script("print('bark bark bark!')");
|
||
|
|
||
|
std::cout << std::endl;
|
||
|
|
||
|
return 0;
|
||
|
}
|