Hi, > Gesendet: Dienstag, 31. Januar 2017 um 09:27 Uhr > Von: "Michael T. Pope" <mp...@computer.org> > An: freecol-developers@lists.sourceforge.net > Betreff: Re: [Freecol-developers] River styles > > On Sun, 29 Jan 2017 15:52:52 +0100 > win...@genial.ms wrote: > > I was trying to improve how rivers are handled by the > > map editor, which currently is annoying to use. > > It seems that TileImprovement.updateRiverConnections > > got 3 conflicting uses requiring different handling. > > 1. right click on a land tile without river to add > > a river in map editor, where it should probably > > autoconnect to neighboring tiles > > Through add/removeRiver. This is indeed the primary use.
removeRiver actually was never called and when I tried using it, it did not work somehow, so I ended up moving/reusing the same two-liner accessing some container, to remove it there which the game already used. > > 2. setting a river style through the RiverStyleDialog > > in map editor, where it should just --set-- the > > selected style > > Agreed. We probably need a simpler setRiver. The current code > has the benefit of at least trying to maintain continuity. This is > helpful but not vital IMHO. So if autoconnection is proving troublesome I > do not object if you drop it, or perhaps highlight discontinuities? Its actually inconsistent enough already that you could get a river tile with a connection to its neighbor without when using the editor. I wonder if that might have been allowed to allow for twice the granulatrity for editing rivers, but might also just be yet another bug in the update method. > > 3. TileImprovement.checkIntegrity where some 0.10.5 > > compatibility code tries to validate if there are > > wrong connections between river and road tiles > > For 3. I need to know how these old maps were bugged. > > I doubt anyone recalls that any more. The compatibility code was > probably written for 0.10.0 and moved around (back then I was less careful > to be sure that the 0.x.y annotations were added). The only hint will be > in remaining compatibility code and by rolling back versions. Do you > really need to know? AFAICT checkIntegrity is effectively checking that > the given style is correct in the new format and possibly replacing it if > not, almost as if placing a new river on the tile, as in #1. Thing is, I'd like to remove that code as I think it might also screw up completely legitimately mapped rivers. I'd also like to know if half-connections are permissible or a no go. > > For the map editor, I think I will change both river > > buttons in the panel to work like the other buttons > > in that a right click is just adding or removing > > the improvement and not annoyingly opening the dialog > > for choosing the style every click into a rivertile. > > Then I'd add a separate button for choosing a style, > > where I then open the river style dialog, without > > the delete button inside it. > > I think this is sensible. Already done, would be happy if anyone tries it out. :) > > There I would like to know, is it permissible to > > set combined river styles like 1012? Currently > > such styles get silently ignored and transformed > > into something like 1011 or 2022, which I find > > unintuitive and limiting. > > Do we have art for this? If not, that may be the reason it was not > implemented. That or Col1 compatibility. Generally I prefer to see fewer > restrictions, so this makes sense to me. The sole reason I ask about this is that the art files are there, loaded into the game and then the river style dialog displays all available styles already, making it so large a bug report got created, but the update method ignores where "1" or "2" is and just puts the number contained in the tile already on all connections. Its just a question of if its allowed to put that into a map file and finding some better algorithm to connect the visual style to the stored river size and this decision is blocking me from either filtering and keeping current behavior or modifying the update to allow it. I guess theres no gameplay difference between minor and major rivers anyway, but I'd like to use those art files for allowing nicer looking maps. I wonder if the random map generator would generate such pieces already, or not but should, or not because reasons, though I did not check this. Same for the standard maps. Btw., we even have 2 sets of art for this, the light blue rivers we use atm and another set of dark blue with kinda strange widened river connections, where I guess I kinda half-remember reading its a failed experiment but I could be wrong. Should the dark blue set be moved to "unused" or put into a mod? Greetings, wintertime ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Freecol-developers mailing list Freecol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freecol-developers