Am Dienstag, 15. November 2011, 10:59:47 schrieb Michal Mazurek:
> On Mon, Nov 14, 2011 at 10:09:56AM +0100, Michal Mazurek wrote:
> > Can i have other files than the default.lua and script.lua? I want each
> > functionality (auth, newcomers) to be in a separate file.
> 
> I added dofile("longturn.lua") to script.lua. This is what i got:
> 
> 1: lua error:
>       data/longturn/script.lua:56: attempt to call global 'dofile' (a nil 
value)
> stack traceback:
>         data/longturn/script.lua:56: in main chunk
> 0: "data/longturn/script.lua": could not load ruleset script.
> 
> 
> Why can't i dofile() in freeciv?

The usage of such commands is restricted due to security implications. You can 
not load a lua file! Only default.lua and script.lua are read. Or you have to 
use the command 'lua file <...>' (I think it is named luafile in S2_3).

> 
> The version is S2_3, I'm yet to apply the svn revisions Matthias said I
> should

This will not help for the problem you describe above as the handling of these 
functions did not change.

_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to