Massive update to start work on asset loading.
This commit is contained in:
parent
8f58570b21
commit
2b312f3494
17 changed files with 346 additions and 58 deletions
|
@ -4,6 +4,7 @@ set(scripts_demo
|
|||
${CMAKE_SOURCE_DIR}/src/scripts/demos/simple_001.lua
|
||||
${CMAKE_SOURCE_DIR}/src/scripts/demos/simple_002.lua
|
||||
${CMAKE_SOURCE_DIR}/src/scripts/demos/simple_003.lua
|
||||
${CMAKE_SOURCE_DIR}/src/scripts/demos/simple_004.lua
|
||||
)
|
||||
|
||||
set(scripts_test
|
||||
|
|
|
@ -50,17 +50,22 @@ int main(int argc,const char** argv) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
std::ifstream input;
|
||||
|
||||
// run a file
|
||||
if (args["file"]) {
|
||||
|
||||
std::ifstream input;
|
||||
|
||||
input.open(args["file"].as<std::string>(),std::ifstream::in);
|
||||
|
||||
if (!input.is_open()) {
|
||||
|
||||
std::cerr << "cannot open '" << args["file"].as<std::string>() << "'" << std::endl;
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
// read as string
|
||||
std::ostringstream sout;
|
||||
std::copy(std::istreambuf_iterator<char>(input),
|
||||
std::istreambuf_iterator<char>(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue