* Change Embarked Defending Strength per era. Update Tutorial a little
* Use JSON implementation of EmbarkDefense
Co-authored-by: itanasi <spellman23@gmail.com>
* Fix UncivSlider isDisabled and snapToValues with the +/- buttons
* Apply UncivSlider to convertGoldToScience
* Apply percent tooltip formatting to sound volume sliders
* Linting and guard against a border case
* Correct logic for blocking Naval Melee from capturing Civilians on Land
* Even better solution now that we can move on to unguarded Civilian tiles. But still won't let us capture Civilians if we can't get there
Co-authored-by: itanasi <spellman23@gmail.com>
* Autoupdates to uniques will multiple solutions now replace to the correct one
Problem - some deprecated uniques can lead to multiple possibilities of replacements, depending on the parameter type
This lead to replacements in the jsons that were either unparseable entirely or were causing errors, both of which needed to be corrected by hand
We now separate such deprecations into their constituent potential replacement uniques, and try and take only the unique that doesn't cause any errors
Works like a charmander :)
* Conditional name change
* Resolved#6179 - when changing units production due to deprecation, notification no longer counts the same city multiple times if it appears multiple times in its queue
* terrainFeatures is only set through the setTerrainFeatures function
* Use cached terrainFeatures for performance
* Fixed map editor error due to not setting tileinfo ruleset
Added private set to terrainfeatureobjects
* Make multiple defense bonuses stack
* Switch to check base terrin and Natural Wonders using getAllTerrains()
Co-authored-by: itanasi <spellman23@gmail.com>
* Triggered uniques currently come from researching techs, adopting policies, and building buildings.
This adds a third way of triggering uniques, by attaching them to units with a "by consuming this unit" conditional, which will be added as a possible unit action.
So for example, "[amount] Free Technologies <by consuming this unit>", "Reveals the entire map <by consuming this unit>" etc.
* Added a new uniquetype for triggerable uniques, to make them separate from regular global uniques, so that triggerable uniques can become unit uniques when necessary
* And added translations so the tests will pass
* Step 1 of saving terrain features as a transient - move all terrainFeature changes to new 'addTerrainFeature' and 'removeTerrainFeature' functions
This also included slight rewriting of functions for clarity, but NO functional changes.
Even though there's some logic that I would definitely change, this PR isn't the place for that.
* Fixed tests
* Initial attempt
* Allow Ranged to move into unguarded Civilian Unit
* Comment for clarity
* Fix unit test so that it doesn't segfault and checks you can't move into military units
* Unify that all units can move on to (and through) unguarded civilians that you are at war with
Add TileInfo.getUnguardedCivilian() to quickly respond if there is an unguarded Civilian on the tile
Something is bugged in movement code
* Fix MapUnit.moveThroughTile() so that it doesn't segfault by fixing getUnguardedCivilian()
* captureCivilianUnit() call is now redundant in postBattleMoveToAttackedTile() since canMoveTo() will now return true and capture will happen during the moveToTile() call
* Add check so Civilian Units don't capture other Civilians
* Change logic to isMilitary()
Co-authored-by: temurakami <spellman23@gmail.com>
* Fox naval unit Landind penalty is for attacking on to land
* Only Land unit should have Boarding penalty
* Unbreak logic
Co-authored-by: itanasi <spellman23@gmail.com>
Fixed icon and text for resource stats improvements in Improvement Civilopedia pages
Fixed 'null' for improvement picker for some resource-only improvements