enigma-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Enigma-devel] Enigma editor, again


From: Petr Machata
Subject: Re: [Enigma-devel] Enigma editor, again
Date: Wed, 20 Jul 2005 10:32:03 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20050119 MultiZilla/1.7.0.1j

Daniel Heck wrote:
>>As for the XML debate... what good will XML bring, anyway? How will
>>reading it be simpler than just letting the (LUA) script run and setup
>>editor state programatically? (Presumably with functions like
>>add_filter, add_shape, etc.)
> 
> 
> Lua scripts are only parsable by the Lua interpreter, so every level
> editor in existence has problems loading levels that aren't restricted
> to the most basic syntactic constructs.  Just as importantly, even *if*
> you include the Lua interpreter, you cannot restore the Lua file after
> loading it, mostly because it's not possible to recover the source code
> of functions after they have been loaded.

The LUA format would be designed for machine usage. You couldn't
complain that it doesn't recreate the file faithfully on save, because
it would be designed for machine to read from and for machine to write
to. There won't be anything like loops and functions. Just calls to
Editor.whatever functions.

> 
> The lua2xml script currently chokes on all levels that use Lua functions
> as signal targets, for exactly that reason.  It *might* be possible to
> convert some of these levels by manually parsing them, copying all
> variable assignments and function definitions verbatim to the <lua>
> section, emitting a warning that the level may not work correctly and
> hoping for the best :-)  I'm only glad you cannot use anonymous
> functions as signal targets in Enigma ;-)
> 
> Daniel
Petr




reply via email to

[Prev in Thread] Current Thread [Next in Thread]