scripting engine libraries
scripting engine libraries
has anyone found any cross-platform, cross-compiler scripting libraries?
I looked at both caLUA and toLUA, and it seems they're both limited to MSVC.
I am trying to support Win32 (MSVC+DEVCPP) and linux (gcc).
I am looking for any scripting language that is vaguely C-like, so Python would work as well as LUA. It should plug into C, but C++ object support is a plus.
I looked at both caLUA and toLUA, and it seems they're both limited to MSVC.
I am trying to support Win32 (MSVC+DEVCPP) and linux (gcc).
I am looking for any scripting language that is vaguely C-like, so Python would work as well as LUA. It should plug into C, but C++ object support is a plus.
a screen cap is worth 0x100000 DWORDS
toLua can be used under Linux; I used an older version - http://habitat3d.sf.net.
tell ya what if somebody finds one lemme know too ;-)
heh yeh really dude, HELP! i have already plugged CaLua into fmorg, but like you say, its really a c lib, and i cant do neat stuff like register objects with it. simkin was mentioned in another thread, but i couldnt get it to compile at all, plus it's actually rather poorly documented i thought. another i have looked at is called angelscript, and that one is REALLY poorly documented and not only that, but it makes you manually load it's DLL, which means you must include the windows.h header, which causes all sort of foul ups in my compile. (not sure why that is actually) so for that its rather totally NON cross platform at all.
it occurs to me, that a very similar method to the way im handling the network messages could prolly be applied to doing scripting. i could write the scripts in XML, ALA simkin, read them in like i do with the config files, and then parse them very much like i parse the network messages.
not sure how well that would work in practice, but it's a thought, and would mean that anything that the server and client could tell each other, a script could do too. although there are several areas it still wouldn't really cover, like combat or effects, and most significantly the AI.
there seems to be a lack of truly well-documented, cross-platform, WORKING scripting languages to embed in C++, or maybe they are just hard to find....
or maybe it's just me;-)
i think my best option right now is to work with the best one i have found so far, which is CaLua, and see how i can extend it to be more O-O
-Ted
it occurs to me, that a very similar method to the way im handling the network messages could prolly be applied to doing scripting. i could write the scripts in XML, ALA simkin, read them in like i do with the config files, and then parse them very much like i parse the network messages.
not sure how well that would work in practice, but it's a thought, and would mean that anything that the server and client could tell each other, a script could do too. although there are several areas it still wouldn't really cover, like combat or effects, and most significantly the AI.
there seems to be a lack of truly well-documented, cross-platform, WORKING scripting languages to embed in C++, or maybe they are just hard to find....
or maybe it's just me;-)
i think my best option right now is to work with the best one i have found so far, which is CaLua, and see how i can extend it to be more O-O
-Ted
My irrlicht-based projects have gone underground for now, but if you want, check out my webcomic instead! http://brokenboomerang.net
AngelScript is a scripting engine based on C++ syntax, very easy to implement: http://www.angelcode.com/angelscript/
heh thanks dude...
hehe yeh thanks for the vote of confidence in my abilities LOL
actually i hadnt noticed tolua++ until last night really, and i ran it on some simple stuff and the output looked promising. i havent tried pluggin it into the app(fmorg) as a whole yet, but im certain i shall soon enough. swig, neat, might let me embed PERL 
cool
-Ted


cool

-Ted
My irrlicht-based projects have gone underground for now, but if you want, check out my webcomic instead! http://brokenboomerang.net
-
- Posts: 602
- Joined: Sat Aug 23, 2003 2:03 am
- Location: Pottstown, PA
- Contact:
Scripting is just an extension of your normally c++ code. It primary bonus is that you can tweak functions and not have to create a whole new build. It's good for things like behavioral logic, combat logic (damage/accuracy), etc..
This is crucial for large projects that get to the point that a rebuild would take hours to finish.
This is crucial for large projects that get to the point that a rebuild would take hours to finish.
Crud, how do I do this again?
-
- Posts: 602
- Joined: Sat Aug 23, 2003 2:03 am
- Location: Pottstown, PA
- Contact:
As I said before, look at the source here:
http://habitat3d.sf.net
The source is messy and the demo doesn't work, as the image files were created under Linux and don't seem to load under Windows. But the source for the ScriptManager is in the Core directory.
Oh and it only supports Lua 4 and toLua.
http://habitat3d.sf.net
The source is messy and the demo doesn't work, as the image files were created under Linux and don't seem to load under Windows. But the source for the ScriptManager is in the Core directory.
Oh and it only supports Lua 4 and toLua.
script engines typically load script files.
the great thing about scripting is that you can think of things like dialog, item statistics, game logic and all sort of other things as 'resources' which can be created and changed by the game designer instead of the programmer. this is similar to resources such as images and sounds. instead of having to recompile the engine every time you want to tweak something, all your designer has to do is change a script file and move it into the script directoy.
the great thing about scripting is that you can think of things like dialog, item statistics, game logic and all sort of other things as 'resources' which can be created and changed by the game designer instead of the programmer. this is similar to resources such as images and sounds. instead of having to recompile the engine every time you want to tweak something, all your designer has to do is change a script file and move it into the script directoy.
a screen cap is worth 0x100000 DWORDS
and magic numbers...
also for things like a particle effect, where you have a bunch of magic numbers for things about that effect, and you wanna tweak it without having to do a total recompile. lets you do it more easily. also for something like a bot, you could have a file open dialog and allow the player to select from many different pre-made bot scripts, or even write their own bot script and use it without having to recompile the game or anything. really, the possibilities are endless...
-ted
-ted
My irrlicht-based projects have gone underground for now, but if you want, check out my webcomic instead! http://brokenboomerang.net
I dont see a source download on that page, or the 'project page'stodge wrote:As I said before, look at the source here:
http://habitat3d.sf.net
The source is messy and the demo doesn't work, as the image files were created under Linux and don't seem to load under Windows. But the source for the ScriptManager is in the Core directory.
Oh and it only supports Lua 4 and toLua.
a screen cap is worth 0x100000 DWORDS