Skip to main content
gamedev.net
🔒 Locked

Game scripting language

Started by stenlik 2 replies 950+ views
Original Post
stenlik
stenlik
Hi, has anyone some suggestions on Windows Mobile game scripting language runnable from C/C++ environment? Ideally with having possibility to run pre-compiled P-code? I have tried the GameMonkey, but it is giant - the static library has 1.5 MB after compilaton, so I would have something smaller. It has to be better then e.g. tinyBASIC (as I would like to not use something like '10 GOSUB 300'), ideally with the C like syntax, but it is not a must. The ideal complexity seems to be something like Oberon-0 language - it has awfull pascal syntax, but I can live with that... I would like omit to implement something on my own as this I think is waste of time... Any ideas welcomed. BR STeN
ddn3
ddn3
Give Lua a try, it has a simple syntax and is a dynamic typeless language, so you can be more productive in it than straight up C/C++.

http://www.lua.org/

It can be precompiled into pcode or even asm with alittle more work, and it's one of the fastest scripting languages around ( according to the big language shootout page )

Good Luck!

-ddn
stenlik
stenlik
Hi,

thanks for the tip - I have tried to compile it for WM 5.0, but this is not without problems:

1/ <errno.h> is missing on WinCE, thus I have defined 'static int errno' Not sure if this is O.K.

2/ Following defines were missing, but I'm not sure I can just define them...
#define _IOFBF 0x0000
#define _IOLBF 0x0040
#define _IONBF 0x0004
#define BUFSIZ 512
#define LUA_TMPNAMBUFSIZE 32

3/ Secondly there are many warnings saying e.g "'strerror' undefined; assuming extern returning int", which refer to methods, which are not part of the WIN CE SDK...

I think problems 1-3 are related to fact that some standard C library are missing on device.

4/ If I skip those errors and put into the .def file export method names I have error that 'oldnames.lib' is missing, which I think is consequence of previous errors...

5/ It is also worth to mention that the static library was around 1MB, while I expected somthing about 200kB.

I'm not an expert on Windows Mobile, but as the Lua use is not without problems I will even not try it on Symbian, which is 2nd platform I have to support.

IF anyone has some TIP on tiny OS independant game scripting language for mobile phones I will appreciate his comments.

BR
STeN



stenlik
stenlik
Hi,

finally I have found on LUA mailing list the Pocket PC implementation here http://lua-users.org/lists/lua-l/2007-11/msg00531.html. I have just quickly check it and I can say that it costs much more of effort to make it working then I expected.

According to the guy here (http://lua-users.org/lists/lua-l/2006-10/msg00686.html) porting is possible, but checking the Pocket PC port I'm not sure I will follow it...

BR
STeN

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.