Menu

#2580 Where is the name?

Fixed_0.11.6
closed-fixed
nobody
UI (42)
3
2015-10-17
2013-08-15
KeplerBR
No


The name of my colony appears and disappears soon after, when I change the camera.
If I move my unit to the next colony, the name appears and does not disappear again.

1 Attachments

Discussion

  • Mike Pope

    Mike Pope - 2013-08-16
    • labels: --> GUI
     
  • Mike Pope

    Mike Pope - 2013-08-16

    Confirmed (debug game, move scout two tiles south of a colony, deselect, reset moves on the scout, and as soon as the green border begins to flash the classic colony label disappears). Something similar happens with the modern colony labels --- the lower part with the current buildable is chopped off.

    This is pretty minor IMHO, and will have to wait for someone who understands the display code.

     
  • KeplerBR

    KeplerBR - 2013-08-16

    Not now, but in the future (in approximately 3 or 4 months), I plan to collaborate with the project. You could tell where, specifically, is responsible for displaying the codes?

     
  • Mike Pope

    Mike Pope - 2013-08-16

    At a guess, somewhere in MapViewer.java. Beware that if you plan to work on the FreeCol code you will need to be able to work this sort of thing out for yourself, as we have very few developers and they are busy with other stuff.

     
  • KeplerBR

    KeplerBR - 2013-08-17

    Well, I already have a little experience in open source. Collaborated for more than 1 year in the open source project OpenKore (in Perl).
    What I will have more difficulty is the fact that in Java, because I'm not used to high typography.

    Anyway, thank you, this is for future plans =)

     
  • Lone_Wolf

    Lone_Wolf - 2014-03-09

    I have seen this effect often when moving units.
    It does seem to occur more often with scouts, especially after De Soto .
    That suggests this may have to do with fog of war zone changes due to moving.

     
  • Mike Pope

    Mike Pope - 2014-06-08
    • labels: GUI --> UI
     
  • wintertime

    wintertime - 2015-09-27

    There is an optimization to, in some cases like when refreshing the unit cursor, only redraw parts of the map (a few tiles around it), because map display consumes a large amount of CPU-time.
    Colony labels are naturally associated and drawn together with the tile containing the colony, but part of them gets drawn on the tiles south of the colony.
    Only when the active unit is 2 tiles south of a colony is the tile between both redrawn without the colony tile being redrawn, too. You can see this on my screenshots from a colony with a very long name.

    There are a few solutions I thought about:
    - Making the redrawn area larger would only move the problem and make it worse.
    - Drawing all labels with the tile south of the colony could result in the same problem with a unit north of the colony.
    - I could hack in some special case code, but I was working on cleaning up the code for map drawing and I'd not want to obfuscate it again.
    - Moving all labels higher would hide the colony tile, but would be the easiest, cleanest solution.

     
  • wintertime

    wintertime - 2015-09-28

    I further investigated this issue and found its slightly worse than known:
    - The blinking of the cursor is not correctly deactivated, even in terrain view mode it was needlessly running the background thread and refreshing the tile. -> I fixed that in git.be3df27a.
    - It also happens with the terrain cursor and its worse cause it can be moved more/faster, sometimes affecting colony names in same row but in a far away column on the side from occasional bigger refreshes.
    - A single refreshed tile causes an area that is as high as 2 tiles to be refreshed, when 1.5 tiles height would be enough. I'm waiting to change this though, as this bug would not happen with the tile 2 south, but instead for the 2 tiles 1 south+1 southwest and 1 south+1southeast.
    - The bug also affects the dark halo of undeads, which I activated temporarily for all units in testing. Its the only other thing affecting enough of the area of other tiles. As the halo is mostly not shown its less important though.

    I think, the most likely fix would be drawing extra colony labels for the row above of which would be drawn normally.
    No idea about the halo, because its so large that the glitch even shows for refreshed tiles north of it...

     
    • Mike Pope

      Mike Pope - 2015-09-28

      I'm waiting to change this...

      Probably wise ATM, however I am very pleased to see some progress on this annoying bug. The haloes are indeed a very minor issue --- I would be inclined to try to make them smaller, at least on the upper side.

       
  • wintertime

    wintertime - 2015-09-28

    I found some small parts of the territorial borders drawn on the map were also affected.
    That and the settlement names is fixed in git.8a482888.

     
  • wintertime

    wintertime - 2015-09-28

    I searched the codebase and could not find anything to test if revenge mode is running.
    I'd need some isRevengeMode() call or similar to prevent map drawing from slowing down for the bugfix for the halo. It would also slightly speed up map display without doing the bug fix, as its currently doing isUndead on all units.
    Could such a method be added Mike?

     
    • Mike Pope

      Mike Pope - 2015-09-29

      Could such a method be added Mike?

      Very easily. Git.6503070.

       
      • wintertime

        wintertime - 2015-09-29

        Thank you, I'll use it for the bugfix. Its just that my difficulty was in finding a O(1) solution for the common case, like remembering when the mode is started. ^^

         
  • wintertime

    wintertime - 2015-09-29

    I fixed the dark halo in git.9f6e4a9f. I profiled the game with it and the testing for revenge mode is fast enough.
    A tiny bit of forts and fortresses was drawn over the tile south of them, which also triggered this bug. I fixed this in git.3a095390.
    That means everything affected by this bug is fixed now.
    For the future, please remember there may be code updates needed when replacing images with new artwork larger than a tile (any keys starting with "image.tileitem.") !

     
  • wintertime

    wintertime - 2015-09-29
    • status: open --> pending-fixed
    • Group: Current --> Fixed_trunk
     
  • Mike Pope

    Mike Pope - 2015-10-17
    • Status: pending-fixed --> closed-fixed
    • Group: Fixed_trunk --> Fixed_0.11.6
     

Log in to post a comment.