[Top][All Lists]

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

Re: [Enigma-devel] Lua API

From: Ronald Lamprecht
Subject: Re: [Enigma-devel] Lua API
Date: Sun, 04 Nov 2007 13:54:44 +0100
User-agent: Thunderbird (Windows/20070728)


Ronald Lamprecht wrote:
Andreas Lochmann wrote:
[C11 - Checkerboard Floor   (coded) ]

Every floor takes an attribute "checkerboard". If set to interger value
0 the floor will only be placed on grids with x+y being even, if set
to 1 the floor will be placed only on grids with x+y being uneven.

ti["x"] = ti({"fl_rough_red", checkerboard=0}) +
         {"fl_rough_blue", checkerboard=1}

generates an arbitrary shaped checkboardfloor on areas with tile "x"
on the world map.
Is it possible to add further algorithms in future?
C.f. the algorithms used in libsoko.

I received a similar proposal in a private email. Yes - we will add a general floor attribute that takes a callback function name. Before a floor will be set this function will be called to acklowledge or reject the floor set operation. Details will be published as soon as I have checked all sideeffects.

If we call a user function prior setting one of the alternative floors it would just take the floor position (x,y coordinates) as argument and would have to result in an integer value that could be checked against the "checkerboard" attribute value.

Are there any algorithms that have need of more context info besides the floor position? Any further info would likely be difficult to pass, as the floors do not yet exist.

@Andreas - please check the libsoko algorithms concerning their demands.



reply via email to

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