I have added a document entitled "Example Usage" in the Docs section of this site. It shows a sample C++ program that loads a Lua script (shown in the doc). It retrieves values from the Lua state, it changes those values, and it calls functions that take parameters and return values back to the C++ program. Have a look at this document to see how easy it is to use MIGHTY::Script!
A new package has been uploaded to replace the first one. The code for MIGHTY::Script was not changed in any way. But this package includes the following additions:
- Documentation in a readme about how to use this code.
- A test program, test.cpp, which shows how to use this class with a Lua script.
- A Microsoft Visual Studio v7 project to easily build MIGHTY::Script.
I hope this makes it easy to use this code in your own projects and to help learn how to integrate Lua into your own C/C++ projects.
The files for MIGHTY::Script have been uploaded into CVS today. Feel free to download them using the CVS link, then "Browse CVS Repository".
There is no packaged version of this project. The purpose of MIGHTY::Script is to provide C++ code for a class that encapsulates common functionality of the Lua C API's.
I will be providing some documentation soon, as well as some examples of how to use the MIGHTY::Script class in your own code.... read more