Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2002:
[Freeciv-Dev] Re: new generalized calendars

[Freeciv-Dev] Re: new generalized calendars

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Raimar Falke <rf13@xxxxxxxxxxxxxxxxx>
Cc: Freeciv-Dev <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: new generalized calendars
From: Mike Kaufman <kaufman@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 25 Aug 2002 18:03:03 -0500

On Sun, Aug 25, 2002 at 11:43:00PM +0200, Raimar Falke wrote:
> > o we probably need a "short_date" function, but that'll need alternate
> >   formats. :(

I don't understand this. The problem here is the display in the client.
I you have a date like:  "45 years after the death of King Foo in the Third
Age" you start crowding out the screen. Having an alternate date format
might help (or you could just add a '\n' to one of the unit formats)

My plan (if you would write a secfile_insert_int_vec() for me) would be
to store the date in the savegame as: = 1941,12,7,0,0,0

for labeling savegames, which is what I suppose you want, I sould have
to say:

"civgame-%d.%d.%d.%d.%d.%d.sav.gz", cal.cdate[0], cal.cdate[1], ...

alternately, we could add a "calendar_unit?.savelabel" boolean field
that specifies if the unit is needed as part of the above. That way, the
default calendar would save games as they do now.

> > Good news:
> > 
> > to operate: best way to do this is:
> > 
> > % cd freeciv; mkdir rdir; cp game.ruleset-foo rdir/game.ruleset;
> > % ser
> > > rulesetdir ../rdir
> > 
> > Just to annoy Raimar, who used this example, game.ruleset-foo starts the
> > game with the date:
> > 
> > "45 years after the death of King Foo in the Third Age"
> > 
> > so we can be quite flexible.
> > 
> > in data/default/game.ruleset is the documentation for the calendar.
> > Please try and break it. I'm sure there are bugs.
> > 
> > Unfortunately there is a cheat. Certain freeciv rules (like the
> > spaceship parts) are hardcoded. It ain't _that_ flexible. You can read
> > all about that in the "builtins" section. Note that this is still a far
> > cry from Raimar's lets hardcode everything approach, so I don't feel too
> > bad.
> It is nice that we agree at some points:
>  - game.year should die


>  - you can't exactly map from date to turn

I'm not so sure. Give an example where this is not the case.

>  - this makes loading games hard/inaccurate

not at all. see above.

>  - some behavior can't be specified via ruleset

of course it can. It would just be dumb (and really hard) to. 

> But I also have to say that your patch is just an implementation of my
> model. 

well, I guess in the same way a prince is a frog ;) If I want to play my
game in lunar months, I edit "game.ruleset". I you want to play in lunar
months, you have to mail freeciv-dev and beg us to implement it and get
it in CVS.

>        You just define one calendar which is medium customizeable via
> rulesets. My model leaves it open if we have 3 or 4 (freeciv, AC, some
> modpacks) very specific calendars or if we can create a common model
> (like you have done) and use fewer calendars (one in the most extreme
> case).

no comment.

> So if we agree that we include a simple counting calendar (like yours)
> the discussion is now how general the this calendar should be. It
> should be clear that we can't include everything (you agreed on this
> when you added the "builtin" attribute).

of course.
I didn't write the code to look nice.

> I would like to remove the two tech dependencies. Tech is just
> arbitrary. Same way as our spaceshipparts. On the other side is your

not necessarily. tech can be an important milestone, just as a wonder
can also be. Wouldn't you say that computers, for example, have
dramatically "slowed" down history. "More" happened in the last century
than in the previous millennium (could be slight hyberbole)

Not that I'm adamantly against this, but this is the kind of general
thing that somebody might very well want. (It also didn't take more that
a couple dozen lines of code.

I suspect that the major features of civ should be integrated:
o the building of (the first of) a certain unitype.
o the building of (the first of) a certain improvement.
o discovery of a tech.
o I suspect that Per might like something like the death of a certain
  unittype (like a Sauron unit), but I think that might be going a bit

> builtin feature useless in its current form. The leap year rule
> changed in the past and the current one is only valid since
> 24. Febr. 1582. So you would need multiple leap year rules and also

This is simply wrong. Yes, the calendar is simplistic. Yes, sometime in
the 1570's or 80's most of september got skipped. you miss the point. We
measure history using the Gregorian calendar. If I ask you when Trajan
was emperor, you don't give me the answer in Julian units.

(besides, it would really suck, this for a little while there were a
couple of leap year rules that contradicted each other).

but calling the "builtin" feature (which may be misnamed) useless is a
bit harsh. Something like it will be necessary to implement the idiotic
rules that payciv dreamed up.


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