Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate territory effect images #4679

Merged
merged 2 commits into from
Feb 15, 2019
Merged

Conversation

ron-murhammer
Copy link
Member

Overview

Functional Changes

  • Allow territory effect map decorations to use _large.png and if that isn't found then .png. This allows 2 different size images for territory effects: 1 for map and 1 for bottom bar. This makes it similar to how resource and flag images work.

Manual Testing Performed

  • Tested Another World with .png and _large.png
  • Tested Dragon War and TWW to ensure their resource and territory effect images work as before

@codecov-io
Copy link

Codecov Report

Merging #4679 into master will increase coverage by <.01%.
The diff coverage is 0%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #4679      +/-   ##
============================================
+ Coverage     23.21%   23.22%   +<.01%     
+ Complexity     6212     6211       -1     
============================================
  Files           873      873              
  Lines         70489    70484       -5     
  Branches      11240    11241       +1     
============================================
  Hits          16367    16367              
+ Misses        52085    52079       -6     
- Partials       2037     2038       +1
Impacted Files Coverage Δ Complexity Δ
...re/src/main/java/tools/image/DecorationPlacer.java 0% <ø> (ø) 0 <0> (ø) ⬇️
...ava/games/strategy/triplea/ui/mapdata/MapData.java 2.69% <0%> (-0.02%) 3 <0> (ø)
...s/strategy/triplea/image/AbstractImageFactory.java 0% <0%> (ø) 0 <0> (ø) ⬇️
...rategy/triplea/attachments/UnitTypeComparator.java 46.15% <0%> (-7.7%) 12% <0%> (-1%)
.../strategy/triplea/odds/calculator/DummyPlayer.java 34.83% <0%> (-1.13%) 9% <0%> (-1%)
...java/games/strategy/triplea/delegate/DiceRoll.java 64.93% <0%> (+0.31%) 139% <0%> (ø) ⬇️
.../src/main/java/games/strategy/net/nio/Decoder.java 73.91% <0%> (+1.08%) 25% <0%> (+1%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6f33315...c6d21b0. Read the comment docs.

@DanVanAtta
Copy link
Member

Looks like we'll be back to this problem:

20180424_territoryeffects

Or force map makers to maintain 2 images. It's a very significant reduction to do the image shrink if there is only a '_large' image and not have it be cropped badly, which was the original problem reported in: #3396.

@DanVanAtta
Copy link
Member

DanVanAtta commented Feb 15, 2019

@ron-murhammer do you intend to follow up with an image shrink functionality? As-is, it looks like we are back to the problem of #3396, with the added caveat that we punted this problem back to the map-maker to solve. Given we can get a clean image by doing a shrink, and we have code to do it, it seems like we should allow a second image for the case that a shrink scales badly (which I hope is relatively rare).

@DanVanAtta DanVanAtta merged commit 773272c into master Feb 15, 2019
@DanVanAtta DanVanAtta deleted the Separate_Territory_Effect_Images branch February 15, 2019 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants