[Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
--- Reinier Post <rp@xxxxxxxxxx> wrote:
> On Sat, Sep 29, 2001 at 02:55:03PM -0700, Arien Malec wrote:
> > Better to issue a create first:
> >
> > create tech.railroad
> > set tech.railroad.name "Railroad"
>
> I cannot see what 'tech.railroad' would mean in the first line.
> In my proposal it is the tech whose .name field matches /^railroad/i,
> but the name is only assigned in the second line.
I believe that there are advantages to make the token "railroad" in
"tech.railroad" an identifier, and not a name:
1) It parses easily, whereas names need to be tech."Atomic Theory", identifiers
can only be tech.atomic_theory
2) See the following set of commands:
; in the ruleset:
create unit.archers
set unit.archers.name = "Archers"
; on the command-line, my semantics
set unit.archers.name = "Bowmen"
set unit.archers.hitpoints = ...
; on the command-line, your sematics
set unit.archers.name = "Bowmen"
set unit.bowmen.hitpoints = ....
; Does unit.archers still exist now?
3) (minor point) It lines up with how the current rulesets work:
[advance_atomic_theory]
name = _("Atomic Theory")
req1 = ...
req2 = ...
flags = ...
becomes
create tech.atomic_theory
set tech.atomic_theory.name = ...
set tech.atomic_theory.req1 = ...
Or, in the multiple create/set syntax:
create tech.atomic_theory (
name = ...;
req1 = ...;
etc...
)
Arien
__________________________________________________
Do You Yahoo!?
Listen to your Yahoo! Mail messages from any phone.
http://phone.yahoo.com
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification),
Arien Malec <=
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Daniel L Speyer, 2001/10/01
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Reinier Post, 2001/10/01
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Reinier Post, 2001/10/01
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Arien Malec, 2001/10/01
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Daniel Sjölie, 2001/10/02
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Reinier Post, 2001/10/02
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Daniel Sjölie, 2001/10/02
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Reinier Post, 2001/10/27
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Daniel Sjölie, 2001/10/27
- [Freeciv-Dev] Re: commandline syntax and semantics (was: Server/ruleset unification), Reinier Post, 2001/10/28
|
|