Complete.Org: Mailing Lists: Archives: freeciv-dev: June 2004:
[Freeciv-Dev] Re: (PR#9135) Roadstyle 2
Home

[Freeciv-Dev] Re: (PR#9135) Roadstyle 2

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: john@xxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#9135) Roadstyle 2
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 29 Jun 2004 09:51:01 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=9135 >

John Bauman wrote:

> Why was the original roadstyle added to the capabilities?  What if the
> tileset only has this new style of road (for whatever reason)?  I thought
> that the tileset could require this capability of the client, so an
> unsupporting client wouldn't try to load it and then fail somewhat
> confusingly?  Although, if you think it's a good idea, you can remove it.

I think you don't understand the use of capabilities.

You can set a manditory capability by "terrain_grid".  Then the tileset 
won't load unless both freeciv and the tileset have this capability. 
There have been many non-compatabile changes made to the tilesets in the 
last few months, but rather than add a new capability each time I just 
added one for the first one and left it at that.

Or you can set an optional capability with "duplicates_ok".  But then 
you have to do a has_capability() check.

"roadstyle" and "roadstyle2" seem to be optional capabilities with no 
has_capability check.  I'm not sure why that is, but it's certainly a 
mistake.

A manditory capability might make sense for roadstyle2, since the code 
is not forward-compatible (new tilesets aren't compatible with old 
code).  But I don't think it's strictly needed since +terrain_grid 
should catch most problems.

jason




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