* Healing parity
Adjusted healing values for parity with CV
* New Demographics system for victory screen rankings
Added a new game setup checkbox option to use a ranking system on the victory screen which is more in line with the Civ V Demographics window. Created the UI element and game parameter but the demographics screen still needs to be implemented.
Also removed unnecessary comments from adjustments to healing values in a previous update.
* Demographics table init
Beginning to build structure of Demographics rankings table.
* Update VictoryScreen.kt
Attempt at getting more of the Demographics table implemented
* Update VictoryScreen.kt
Continued building the structure of the Demographics table
* Demographics first implementation
Finished first pass of Demographics screen.
* Minor text formatting
Improved some text formatting in code and comments.
* Update MapUnit.kt
Minor comment cleanup.
* SomeTroglodyte's Feedback, pt. 1
Implemented feedback given by SomeTroglodyte in PR #6645.
* Organized into functions
Split up Rankings table creation and Demographics table creation into new functions
* Update template.properties
Fixed missing space.
* Implementing more PR #6645 feedback
Added needed translation templates, used enum class instead of array for headers, moved checkbox to Options -> Display instead of new game
* Implemented rest of PR #6645 feedback
Simplified logic for finding player's rank, value, best/worst civ value, and filtered out defeated civs from the display and calculations
* Dead Civs get 0 in all categories
Added simple check if a civ is dead when computing score. If they are dead then they get 0 and go to the bottom of the scoreboard.
* Update VictoryScreen.kt
Further cleaned up code for better reuse and simpler logic with fewer loops.
* Update CivilizationInfo.kt
Simplified implementation of return 0 for stats when civ is defeated.
* Update CivilizationInfo.kt
Removed commented-out line of code.
* Fixed duplicate rank bug
Adjusted method of determining best and worst civs so that duplicates don't occur.
* Update VictoryScreen.kt
One-lined the handling of logic in buildDemographicsTable()
* Update VictoryScreen.kt
Moved static header row to new function.
* Simplified tileFilter predicate
* Use only own harbors
* Allow city connections via open borders only
* Basic unit tests
* Advanced unit tests
* The maps and the legend for the tests
* CR changes: barbarians will not let the trades happen
* CR changes: get rid of question signs, "let" "Elvis" pass away
* Formatting
* Fix minimap actor leak
The minimap update method tried to update borders only on tiles that changed owners, which is fine if that was what it did. But only the "remove old borders" part was in the "changed owners" branch, not "add new borders", so what actually happened was that each update all borders where the tile owner didn't change got added again, which is basically all borders.
This caused a huge slowdown the more actions you do on the world map in a single turn (i.e. move a lot of units). When a new turn starts, the minimap gets completely thrown away and rebuilt, so then it's fine again.
This changes the minimap to properly add/remove borders when something actually changes.
* Refactor: Split classes up into separate files
Also, split up the Minimap.init method into smaller methods to make it a bit more readable
* Finish up comment
* Fixed `provides [amount] [resource]` not accepting conditionals
This was due to it still using `getLocalMatchingUniques` without
providing a `StateForConditionals`, and then manually filtering them if
they didn't provide conditionals. This of course doesn't work anymore,
as `getLocalMatchingUniques` then assumes that all conditionals aren't
satisfied.
Also refactored a loop over `uniqueObjects` with `isOfType()` to just
use `getMatchingUniques()`.
* Only initialize StateForConditionals once
* Actually this is more moddable
* Implemented most easy things from comments on moddable victory PR
Also added religious victory condition
* Fixed tests
* Fixed compile problems & missing string
* Fixed typo
* Fixed issue #6649 by checking for internet connection before starting the game if "online multiplayer" is selected
Many thanks to SomeTroglodyte for most of the code and for explanations
* check for internet before starting a mp game to avoid freeze
Fixed issue #6649 by checking for internet connection before starting the game if "online multiplayer" is selected.
Many thanks to SomeTroglodyte for most of the code and for explanations. A slight modification has been done to the code to catch an error caused by InetAddress
* Revert "Merge remote-tracking branch 'origin/master-noInternet' into master-noInternet"
This reverts commit bd6474b50d, reversing
changes made to f52ad60b51.
* Readability overloads for `getComplexRuleset`
* Enable loading maps containing missing ruleset objects with fix and message
* Fix bungled `noMapsAvailable` and follow minor criticism
This would only occur if the plane was damaged and looking for a spot to
heal, and had no tile to go to with >0 healing. It would then try to
head towards the nearest city, regardless of whether it could enter
that. As it's an air unit, 'head towards' means 'fly there directly this
turn', which obviously caused crashes if the unit couldn't enter that
tile.
* Correct contribution to the Settler production
* Correct indicator of the food usage during Settler production
* More precise calculation of the food to production conversion
* Revert of starvation avoidance during Settler production
* Minor tweaks
* More info for Resources in Civilopedia
* Remove duplicates for Resource requirements in Civilopedia
* Resource overview link resource label to Civilopedia
* Resource overview stay if clicking can't notify (resources not existing on map)
* Resource overview display of resources produced by buildings
* Changed milestone build globally text to make it more understandable
* Actually this is probably just as clear, gramatically more correct and
more imperative like the other milestones
* Fixed tests
* Reworded again
* Comments to 'link' implementation (matchFilter) to UniqueParameterType
* Comments to 'link' UniqueParameterType to implementation (matchFilter)
* Fix two mistakes in UniqueParameterType
* Make "and" filter logic for MapUnit and BaseUnit modular, fix mistake
* Make UnitMovementMemory immutable and without lateinit
* Keep UniqueType comment promise that instances can override parameter types
* Reorg UniqueDocsWriter so UniqueParameterType-specific text is moved to the enum
Also some minor improvements - e.g. abbreviations sorted & consistent punctuation, less memory allocations, a/b/c type params get an example,...
* New abilities for UniqueDocsWriter concerning UniqueTarget and inheritsFrom (initially deactivated)
* Actually implement the wish for distinction between absolute and relative amounts
* Change UniqueParameterType.UnitName.docExample to Xander's choice
* Added a moddable (but not yet functional) file for victories
* Spaceship parts are units now
* Fixed tests
* Added milestone objects
* Made 'our status' table in VictoryScreen dependend on file
* Updated VictoryManager to use the new Milestone system
* Fixed bug where in vanilla too many spaceship parts could beb uild
* Whoops
* Updated global victory table to use the jsons
* Updated the new game screen to show the new victory types
Also started with the deprecation of VictorType
* Did some translation stuff, also finally fixed the tests
* Removed VictoryType and reworked AI to use Milestones instead
* Add some checks for the victory file; tested that custom victories work
Also moves some code to a better spot and fixes compilation errors
* Fixed some things I thought about while falling asleep
Most notably: built -> build; fixed spaceship part construction
priority; removed more code for the old system
* Fixed translation issues on the victory screen