Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2005:
[Freeciv-Dev] Re: using OR in requirements
Home

[Freeciv-Dev] Re: using OR in requirements

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Vasco Alexandre da Silva Costa <vasco.costa@xxxxxxxxx>
Cc: Per Inge Mathisen <per@xxxxxxxxxxx>, freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: using OR in requirements
From: Jason Dorje Short <jdorje@xxxxxxxxxxxx>
Date: Sun, 04 Dec 2005 21:43:55 -0500

Vasco Alexandre da Silva Costa wrote:
On 12/2/05, Per Inge Mathisen <per@xxxxxxxxxxx> wrote:

could we perhaps add two kinds of reqs, one for ANDs and one for ORs? Such
as one_of_req (or) and all_of_reqs (and), as in:


Yes, we could. However, the current code is a bit of a mess. Helptext
generation,
duplication of negative reqs and nreqs, etc. I believe these issues should be
fixed first before we extend it again, lest it turn into an unfixable mess.
As for the suggestions to use Lua, this functionality seems, to me, to be
performance sensitive enough to warrant a native C code implementation.

We cannot easily use Lua because the AI and helptext both require that the effects logic be invertible; e.g., it needs to know what it has to do to acquire an effect. This would mean lots of lua functions for each effect - one for each query type, basically.

-jason



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