![]() |
Extending your PureBasic applications! |
home · introduction · requirements · obtaining · installation · documentation · contact · license & warranty · acknowledgments
This is a PureBasic extension (PureLibrary) and a DLL with import libraries for PureBasic, that allows execution of Lua 5.0.2 scripts from within PureBasic applications or games. PureBasic is a programming language based on established BASIC rules. The key features of PureBasic are portability (Windows, AmigaOS and Linux are currently fully supported), the production of very fast and highly optimized executables and, of course, the very simple BASIC syntax. Lua is a powerful light-weight programming language designed for extending applications and support general procedural programming with data description facilities It also offers support for object-oriented programming, functional programming, and data-driven programming.
This PureLibrary is partly tested with PureBasic 3.90 running on Microsoft Windows XP Pro (SP1), but it will very likely work with other Microsoft Windows and / or PureBasic versions.
The package can be downloaded as a Windows-compatible .ZIP file, which contains the complete project files with the PureLibrary version, a DLL version, a resident file, sources and simple examples. It is available here (2004/06/22)
If you're going to use the PureLibrary version, extract the "..\lib\PBLua" file to your "..\Purebasic\PureLibraries\UserLibraries" and the "..\res\PBLua.res" file to your "..\Purebasic\Residents" folder. For the DLL version you will find the precompiled DLL and a .pbl file, for use with the DLL-Importer in "..\dll". The resident file is the same.
Currently there is no documentation provided
for this PureLibrary. Because nearly the complete C Lua API is
available, the C API documentation is a good starting point.
It can be found here.
The following API functions are currently supported:
lua_atpanic |
lua_baselibopen |
lua_call |
lua_checkstack |
lua_close |
lua_concat |
lua_cpcall |
lua_dblibopen |
lua_dobuffer |
lua_dofile |
lua_dostring |
lua_dump |
lua_equal |
lua_error |
lua_getfenv |
lua_getgccount |
lua_getgcthreshold |
lua_gethook |
lua_gethookcount |
lua_gethookmask |
lua_getinfo |
lua_getlocal |
lua_getmetatable |
lua_getstack |
lua_gettable |
lua_gettop |
lua_getupvalue |
lua_insert |
lua_iolibopen |
lua_iscfunction |
lua_isnumber |
lua_isstring |
lua_isuserdata |
lua_lessthan |
lua_load |
lua_loadlibopen |
lua_mathlibopen |
lua_newtable |
lua_newthread |
lua_newuserdata |
lua_next |
lua_open |
lua_pcall |
lua_pushboolean |
lua_pushcclosure |
lua_pushlightuserdata |
lua_pushlstring |
lua_pushnil |
lua_pushnumber |
lua_pushstring |
lua_pushupvalues |
lua_pushvalue |
lua_pushvfstring |
lua_rawequal |
lua_rawget |
lua_rawgeti |
lua_rawset |
lua_rawseti |
lua_remove |
lua_replace |
lua_resume |
lua_setfenv |
lua_setgcthreshold |
lua_sethook |
lua_setlocal |
lua_setmetatable |
lua_settable |
lua_settop |
lua_setupvalue |
lua_strlen |
lua_strlibopen |
lua_tablibopen |
lua_toboolean |
lua_tocfunction |
lua_tonumber |
lua_topointer |
lua_tostring |
lua_tothread |
lua_touserdata |
lua_type |
lua_typename |
lua_version |
lua_xmove |
lua_yield |
Send email to Florian Schäfer I appreciate any comments, bug reports, source examples and notices.
The PureLibrary can be used for both academic and commercial purposes at absolutely no cost.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Lua 5.0.2 is Copyright © 2003 - 2004 Tecgraf, PUC-Rio.
PureBasic is Copyright © 2003 Fantaisie Software.
home · introduction · requirements · obtaining · installation · documentation · contact · license & warranty · acknowledgments
Last modified by Florian Schäfer |