Commit Graph

44 Commits

Author SHA1 Message Date
70f81d1657 chore: huge code reorg for ui classes
Separated into screens, popups, and UI components, with screen-specific components located together with their screens
2023-02-19 07:47:29 +02:00
0548b3b472 chore: renamed GameInfo.ruleSet -> ruleset 2023-02-03 13:06:32 +02:00
d565bf8f64 Fixed tests 2023-01-23 11:04:32 +02:00
783a469da5 chore: separated unit actions into several files 2023-01-23 00:42:45 +02:00
d662df9e2f chore: Rename CivilizationInfo -> Civilization 2023-01-22 00:28:15 +02:00
81a5e15413 chore: Rename CityInfo -> City 2023-01-22 00:24:02 +02:00
82010e8564 chore: Rename TileInfo -> Tile 2023-01-22 00:19:25 +02:00
801116551b Chore: Moved tile stat functions to separate class 2023-01-19 21:56:44 +02:00
504a15b9a5 map file reorg 2023-01-19 18:42:24 +02:00
5ebfcc3a90 chore: Split CityInfo functions into CityTurnMAnager and CityFounder 2023-01-18 21:34:41 +02:00
e56d53dcd9 chore: Moved diplomacy functions to DiplomacyFunctions 2023-01-18 18:11:18 +02:00
e272a1408d chore: Removed turn management functions from CivInfo 2023-01-18 15:51:25 +02:00
e8f54cc2f5 chore: File reorg 2023-01-18 15:25:25 +02:00
bdc239fd34 chore: moved statsForNextTurn and happiness transients into civ stats 2023-01-18 14:49:25 +02:00
1ae75f22be Better indication of cached-updating functions for civinfo 2023-01-18 13:35:01 +02:00
0ada7c476e Fixed broken test, faster local tests 2023-01-17 21:49:12 +02:00
879a5b230f Resolved #8387 - Fixed Reliquary belief
Got rid of multiple uniques with the same text
2023-01-16 13:05:11 +02:00
f244c36b57 Update all improvement and road writes to use TileInfo setters (#8136) 2022-12-15 07:18:47 +02:00
545b4afc5a Generalized "Stats per policies" unique 2022-11-26 21:39:26 +02:00
2e5e221158 CityStateType overhaul!!!! 2022-11-21 20:30:52 +02:00
7d9db1e119 CityStateType deprecation p1 2022-11-21 20:03:05 +02:00
8530de7de1 Can now use [stats] unique to add happiness globally 2022-11-21 11:33:29 +02:00
0cf5c33475 Can now use [stats] unique for e.g. techs, policies, etc, to add gold/faith/culture/science to the global pool 2022-11-21 11:21:42 +02:00
61b98120a8 Fixed tests failing due to removing "crutches" 2022-11-20 00:24:59 +02:00
f0ad7581bc Resolved crash when mods make 2 techs require each other 2022-10-13 22:55:12 +03:00
35eb71c937 Removes the option for disabling religion (#7606)
* Removes the option for disabling religion

* Deprecated religionEnabled variable, set default to `true` and removed in cases where it shouldn't have effect
2022-08-05 11:46:06 -04:00
160b51d578 Added more unit tests (#7448) 2022-07-14 10:27:06 +03:00
ae5a0221ed Refactorings & three more unit tests for uniques (#7412) 2022-07-10 23:19:45 +02:00
3422e161ad Removed deprecated uniques 2022-07-08 15:48:33 +03:00
57ed61af41 Save compatibility handling (#7255)
* Add serialization version to GameInfo

* Add handling of incompatible saves due to a dfiferent save version

* Fix compilation?

* Fix ios compilation

* Refactor: Make it clearer that GameInfo serialization version is only supposed to be incremented when it's guaranteed to cause issues & rename to compatibility version

* Update initial version

* Update initial version

* Fix merge mistake
2022-07-01 09:34:41 +03:00
c922f134e6 Moddable game speeds (#6856)
* Move GameSpeed definition to JSON files

* Add game speeds civilopedia page
2022-06-18 23:27:46 +02:00
afce951724 Pillaging certain improvements may loot gold or other stat resources (#6993)
* 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
2022-06-01 19:13:04 +02:00
a2c646ef8e Fix Autocracy Complete including unit test (#6908) 2022-05-22 19:51:05 +03:00
3754108391 Added more unit tests for uniques; added missing unique implementations (#6886)
* Added more unit tests for uniques; added missing implementations

* This of course shouldn't go here as there is another function for it

* Stylistic changes

* This generates better unique examples

* Reviews

* Reordered for efficiency

* Reverted improvement percentage bonuses applying to tiles
2022-05-22 13:12:10 +03:00
3e95e3f152 Fix effect of new Beliefs not immediately visible in top bar (#6888)
* Fix effect of new Beliefs not immediately visible in top bar

* Fix effect of new Beliefs not immediately visible - reviews
2022-05-21 21:37:06 +03:00
1f3890e2a0 welp these tests kind of existed before 2022-05-19 19:02:57 +03:00
1126a7c996 Added test that improvements can be built on their tiles 2022-05-19 14:27:01 +03:00
7b3a4c741f Added more unit tests for uniques (#6841) 2022-05-17 15:42:27 +02:00
cf6543bc29 Fix Sweden not being able to gift great people to city states (#6690) 2022-05-05 09:09:15 +03:00
4ad9d58850 Some of the last remaining simple uniques, from now on it's more complicated ones 2022-02-22 16:38:52 +02:00
22466a9d45 Make tileInfo.terrainFeatures immutable (#6180)
* 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
2022-02-19 19:28:05 +02:00
f6cb2bd0d7 Made unhappiness effects moddable by adding a global uniques json; added revolts when < -20 happiness (#5932)
* Added a json file for unhappiness effects

* Change existing code to handle these effects

* Made a weird and unexpendable way to add unhappiness effects to the civilopedia

* Add the default unhappinesseffects to mods without the json

* Added revolts when at very low happiness

* Renamed a few often-used functions

* Added a file for uniques that are always active

* Fixed tests

* Nullifies [Food] -> Nullifies Growth
2022-01-24 17:19:51 +00:00
6a8f88f202 Added a few more unit tests for global uniques (#6018) 2022-01-23 06:18:15 -08:00
3e6a190ab4 Unit tests for uniques (#5945)
* Added a unit test file for uniques

* Added a few tests
2022-01-10 22:01:14 +02:00