* added sounds to cityScreen
* changes? ..don't know how to name this commit
* removed try block
* improved era1 sound and added slider for city enter sounds
* added Information Era sound
* added Future Era sound
* better option name + translation
* added Atomic Era sound
* normalized sounds
* prevent spam + better era 0 and 1 sounds
* cleanup
* sound improvements to medieval and atomic
* volume now tied to sound effects
* improved information sound
* improved future sound
* sounds now stop if you exit the city screen
* improved Renaissance sound
* now in separate function
* now using the music controller
* better file names
* WLTK day sound + sounds are now configurable in Eras.json
* removed redundant setting and fixed comment
* added PlaySingle
* musicController no longer used
* Gdx.audio.newMusic is now used
* function name
* function are now in their own class
* CitySoundPlayer now has 1 instance in UncivGame and is hooked
* credits
* sounds loop
* loopable sounds
* updated credits
* fixed sound not stopping when changing city without leaving cityScreen
* changed WLTKNew sound
* added toggle for the sounds
* changed WLTK sound, removed music and made all tracks have the same volume
* addressed some of the issues
* addressed more issues
* increased sounds volume + volume slider
* made WLTK sound slightly quieter
* removed entry from Vanilla eras
* revert back to CitySoundPlayer.kt
* no more hooks
* removed unused stuff
* changees
* completly reverted MusicController
* and the MusicTrackChooserFlags
* fixed ESC not stopping sounds
* updated credits to mention the sounds are modified
* dispose()
* removed try block
* Civilopedia Files Split
* Central showReligionInCivilopedia function
* ConstructImprovementConsumingUnit with Conditional for Prophet
* Show Units capable of building an Improvement
* "Needs removal of terrain features to be built"
* Pillaging loots gold on certain improvements
* Add warning if improvement pillageGold > 0 and has UniqueType.Unpillagable
* Pillage yields as a UniqueType
* Forgot to undo demonstration
* Remove unused line
* Eliminate some redundancy
* Reword unique text
* Slight cleanup and add notification for pillage victim
* Reviews
* Made pillaging notifications more consistent with other hostile action notifications
* Missed a line
* Great General UniqueTyped and improved moddability - draft
* Great General UniqueTyped and improved moddability - reviews
* Great General UniqueTyped and improved moddability - no reason not to cache another
* Integration with JackRainy's solution
* Integration with JackRainy's solution - part 2
* Revert of maxGreatGeneralBonusRadius logic
* Minor refactoring
* Code review: minor refactoring
* Keep the warning for the modders about the obsolete unique
* Code review: Better wording for the unique
Co-authored-by: SomeTroglodyte <63000004+SomeTroglodyte@users.noreply.github.com>
* Great improvements can again be constructed on forest
This PR fixes a bug where great improvements couldn't be build on
forests/marshes/jungles/etc. It does so by creating a unique which
specifically allows for removing features, and checking for that.
Additionally, we only remove these features when we have the tech to
remove them. For example, you can no longer plonk an Academy down over a
forest without having researched mining.
* Missed the file for vanilla
* Reviews
* Fixed logic
* Renamed tile.hasUnique, deprecated `Indestructable`, unique for citadels
Also refactored the consumption of (great) people out of UnitActions.
* Reworked when improvements can be build somewhere for more clarity
* Made resources improvable by multiple improvements; Offshore Platform
* Fix compatability
* WIP
* Fixed the tests, but better
* I suppose I might as well update this now that we're a version later
* Implemented most easy things from comments on moddable victory PR
Also added religious victory condition
* Fixed tests
* Fixed compile problems & missing string
* Fixed typo
* 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
* 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
* Fixed G&K policy eras
Patronage should be Medieval and Freedom should be Industrial in G&K
* Added 'priorities' object to policy branch entries
* Fixed Vanilla policy eras
Also set testing priorities in advance
* Partial code formatting
* Reworked how the AI chooses a policy to newly adopt
* Removed debugging codes
* Update Civilization-related-JSON-files.md
Added Branch priorities
* Assigned actual priorities to each branch
Also fixed a debugging value in Ruleset.kt (-1 -> 0)
* Generalized trade route percent bonuses
* Unified two uniques using populationFilter; deprecated a deprecated uniq
* Made some renamings to improve clarity & fixed tests
* Fixed tests again
* Fixed typo
* Unique units abilities that should be inherited by upgrades
* Unique units abilities that should be inherited by upgrades - xlt
* Unique units abilities that should be inherited by upgrades - wiki
* Destroy Arsenal when city is captured
* Update vanilla Songhai
* Add Amphibious promotion to all Songhai units
In Gods and Kings, all Songhai Land units have the Amphibious promotion. This brings our Gods and Kings up to speed with the original.
* Destroy Arsenal when city is captured
* Fix Petra culture wiht city filter
Change Petra's culture bonus to city-specific bonus instead of empire-wide bonus
* Change Embarked Defending Strength per era. Update Tutorial a little
* Use JSON implementation of EmbarkDefense
Co-authored-by: itanasi <spellman23@gmail.com>
Instead of expanding the existing 'requires building' unique to units and adding limiters, it's both easier and more generalizable to add conditionals for cities with and without certain buildings to replace the uniques entirely
* Add Amphibious penalty to Land attacking into Water and vice versa
* Replace Landing with Amphibious in all translation files
* Fix trailing whitespace
* Revert translation files
* Change working of Amphibious
Set penalty to Landing and Boarding
* Type-ify Unique and add Depreciated
Add Promotion to Melee Naval
Add exception that Landing penalty is NOT against cities
* Fix Vanilla
* Rename to Landing Party
Icon doesn't work
* Properly regenerated game.atlas/game.png
Co-authored-by: itanasi <spellman23@gmail.com>
* Unified "X is only available under Y conditions" into a single unique
There were a few problems with existing uniques - they weren't really composable, the offered things they didn't keep, etc
For example, "Incompatible with [policy/tech/promotion]", UniqueTarget.Policy, UniqueTarget.Tech, UniqueTarget.Promotion. In fact, promotions only checked promotion incompatibility, promotions - promotion incompat, etc
Additionally, with a few more changes, this could cover several other uniques - "Hidden until [amount] social policy branches have been completed", "Requires at least [amount] population", perhaps others
I have to say I think conditionals are the best thing ever and they make amazing composability possible :)
* Autoupdate correctly recognizes parameters
Updated ruleset jsons
* Deprecation texts should be allowed to forward to other deprecated uniques so we only need to change the leaves when introducing new uniques, not go through the whole tree
* Arbitrary conditionals can become timed conditionals!
triggerCivwideUniques is activated in 3 situations:
- Tech complete
- Policy adopted
- Building complete
So for each of the unique containers for these I added a catch saying 'if this unique is a temporary unique then don't save it yourself
This has been lying around in todos for a while and generalizes one of the nasty hardcoded messes that I hate about Civ V. Why would you introduce ONE timed effect in the whole game?! You can use them all the time like Humankind or never use them like Civ IV, but why have just one whyyy
One more thing in this PR, that needed to be solved by the by, is allowing parameters to have a '2' on the end so we can autoreplace multiple parameters of the same type.
Using a regex is slightly more inefficient, but since this is A. only used once per UniqueType.kt, and B. allows us to have as many 'amount's as we want which is important if we have a lot of conditionals, I feel this is justified.
* Fixed comments from PR
* Added unique to convert terrain to other terrain if adjacent to something
Terrain converting to other terrain when adjacent to rivers was using hardcoded stuff, so I un-hardcoded it
I thought I could use this to replace the 'coast' hardcoding, and if it wasn't for the maxCoastExtension then I could.
Modders CAN therefore add their own coast (Lava tiles and Ash tiles I dunno) but it will only be for directly close terrains.
This enables Deciv Redux to spawn huge maps.
* Also for Vanilla, which apparently had a different number of tabs than G&K for no apparent reason.
* Apparently terrain name wasn't a uniquetype yet
(cherry picked from commit 593fc257b5)