Commit Graph

6793 Commits

Author SHA1 Message Date
Yair Morgenstern
6babefd3ae Removed documentation of deprecated uniques, with the autoreplace it's no longer important information 2022-02-24 10:55:16 +02:00
Yair Morgenstern
4b921b6006 Mouseover descriptions for simple unique parameters 2022-02-24 10:52:23 +02:00
Yair Morgenstern
40918db1b0 Unique documentation is collapsable 2022-02-24 10:22:47 +02:00
Yair Morgenstern
a3fd04bb59 Added color toggles similar to FastApi, stolen from https://github.com/tiangolo/fastapi/blob/master/docs/az/mkdocs.yml 2022-02-23 21:47:09 +02:00
Yair Morgenstern
ae2b91dd67 Moved wiki links to new site links 2022-02-23 21:40:20 +02:00
Yair Morgenstern
6170322a9f Fixed tables in new wiki 2022-02-23 21:14:29 +02:00
Yair Morgenstern
e99ba8cee7 Reorganized wiki 2022-02-23 21:06:32 +02:00
Yair Morgenstern
4f3fa7b92c Added material theme 2022-02-23 20:51:18 +02:00
Yair Morgenstern
e1e7cfa4fd Merge branch 'mkdocs_test' 2022-02-23 20:39:17 +02:00
Yair Morgenstern
531c685d4d
Create mkdocs.yml 2022-02-23 20:34:26 +02:00
Yair Morgenstern
d255bf3fa7 mkdocs build 2022-02-23 20:20:48 +02:00
Yair Morgenstern
b7211a582c Minor fix for global alert 2022-02-23 20:18:07 +02:00
Yair Morgenstern
4d710bcda7 mkdocs test 2022-02-23 19:28:06 +02:00
Yair Morgenstern
6d7e8616ec 3.19.11-patch1 2022-02-23 18:44:40 +02:00
Yair Morgenstern
1fcc59adb3 More readable unique docs - this is the easiest way I've found to have the uniques themselves stand out 2022-02-23 16:26:07 +02:00
Yair Morgenstern
1fa1c6885a placeholder equality tests replaced with hasUnique() and getMAtchingUniques() instead 2022-02-23 12:16:09 +02:00
Yair Morgenstern
09089cb60d Added uniques and deprecations for "Requires" and "Unlocked by" uniques - #6165 2022-02-22 16:55:37 +02:00
Yair Morgenstern
4ad9d58850 Some of the last remaining simple uniques, from now on it's more complicated ones 2022-02-22 16:38:52 +02:00
Yair Morgenstern
1f9c6f39b5
Uniques list is now officially the autogenerated doc 2022-02-22 12:25:07 +02:00
Yair Morgenstern
162ed35255 3.19.11 2022-02-22 11:41:06 +02:00
Yair Morgenstern
d01203fcdc
Translations update (#6214)
* Update Italian.properties (#6209)

* Update Japanese.properties (#6207)

* translate ConditionalsPlacement

* Update German translation (#6206)

* Translation: Update of Spanish (#6204)

* Translation: Update of Spanish

* Update Spanish.properties

* Update French.properties (#6200)

* Update Indonesian.properties (#6198)

Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
Co-authored-by: nukurette <nukurette@gmail.com>
Co-authored-by: MartinP <77325495+Mape6@users.noreply.github.com>
Co-authored-by: ArchDuque-Pancake <78449553+ArchDuque-Pancake@users.noreply.github.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: kensvin <63847755+Kensvin28@users.noreply.github.com>
2022-02-22 11:38:28 +02:00
Yair Morgenstern
13af71e427
Autoupdates to uniques will multiple solutions now replace to the correct one (#6208)
* 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
2022-02-22 11:33:07 +02:00
SomeTroglodyte
d30ea86b27
Additional guard against no-barbarian games calling doRevoltSpawn (#6213) 2022-02-22 11:30:48 +02:00
Xander Lenstra
e0345bcb52
Reorganized the way city states grant resources & rounded a float to an int (#6210)
* Reorganized the way city states grant resources & rounded a float to an int

* Reworded a string so it sounds nicer
2022-02-22 11:30:33 +02:00
Xander Lenstra
90386bd4e7
Made spaceship parts units instead of buildings (#6203)
* Spaceship parts are units now

* Fixed tests

* Removed commented out lines

* `Spaceship Part` unique can also go on buildings in ods
2022-02-22 11:30:20 +02:00
itanasi
ae77ff0f16
Updating Embarking Tutorial with more details (#6205)
* 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

* Fox naval unit Landind penalty is for attacking on to land

* Only Land unit should have Boarding penalty

* Unbreak logic

* Adding more information to the Embarking Tutorial

* More info

Co-authored-by: itanasi <spellman23@gmail.com>
2022-02-22 11:30:10 +02:00
Yair Morgenstern
ca5f48ad61
Terrainfeature objects transient (#6199)
* 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
2022-02-22 11:28:24 +02:00
itanasi
c9945ca7ba
Make multiple tile defense bonuses stack (#6193)
* Make multiple defense bonuses stack

* Switch to check base terrin and Natural Wonders using getAllTerrains()

Co-authored-by: itanasi <spellman23@gmail.com>
2022-02-22 11:27:58 +02:00
SomeTroglodyte
a7e2d65d22
Lower limit for window size, recover from 0 in settings (#6212) 2022-02-22 11:27:35 +02:00
Xander Lenstra
1e24f04cf9
Added mod constants for the distance between two cities (#6211) 2022-02-22 11:17:22 +02:00
Yair Morgenstern
246d11bfc7 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 2022-02-21 18:19:30 +02:00
Yair Morgenstern
91816d9c37 Added "copy to clipboard" button for mod errors 2022-02-21 10:51:23 +02:00
SomeTroglodyte
5bac71709b
Wiki chapters for context-sensitive music (#6197)
* Wiki chapters for context-sensitive music

* Wiki chapters for context-sensitive music - matched to code
2022-02-21 10:18:46 +02:00
Yair Morgenstern
9595247d3b Finished unique typing for CivInfo.hasUnique() and removed string version!
Damn but there are a LOT of uniques that have accumulated over time
2022-02-20 21:17:58 +02:00
Yair Morgenstern
cd92f66c3a Resolved ANR when copying game data to clipboard 2022-02-20 19:53:19 +02:00
Yair Morgenstern
2786e0091c Massive unique deprecation 2022-02-20 18:27:40 +02:00
Yair Morgenstern
64b8d805c3 Resolved #6184 - don't display turns to relationship change for non-decreasing city-state relationships 2022-02-20 12:45:48 +02:00
Yair Morgenstern
5b50f32505 Great Admiral movement removed from NAval Tradition - per #6131 2022-02-19 23:10:15 +02:00
Yair Morgenstern
4f9c17da0b Resolved untranslated string in improvment description - #6131 2022-02-19 23:08:19 +02:00
Yair Morgenstern
0a4df1ca9f Resolved #6188 - don't show 'missing cities that need to build X' for buildings already built in the city
It gives the impression that the buildings stop providing their bonus if the condition is no longer satisfied
2022-02-19 23:05:47 +02:00
Yair Morgenstern
99e913ba24 Bah released without the changelog :/ 2022-02-19 20:34:20 +02:00
Yair Morgenstern
970e535e62 3.19.10 2022-02-19 19:57:23 +02:00
Yair Morgenstern
f7f21d0cbf
Translations update (#6196)
* Update Russian.properties (#6191)

* Update Korean.properties (#6183)

* Update Korean.properties

* Update Korean.properties

* Update French.properties (#6174)

* Update Spanish.properties (#6173)

TRANSLATION

* Update Italian.properties (#6172)

* Update Italian.properties

* Update Italian.properties

* Update Indonesian.properties (#6171)

* Update German translation (#6170)

* Update Japanese translation (#6169)

* Update Japanese.properties

* fix translation

* Translation: Update Spanish 3.19.10 (#6182)

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>

* Update Brazilian_Portuguese.properties (#6190)

Co-authored-by: deqtodo <94169613+deqtodo@users.noreply.github.com>
Co-authored-by: Samsaek the Calico <saud2410@naver.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: Hello200000 <98656089+Hello200000@users.noreply.github.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
Co-authored-by: kensvin <63847755+Kensvin28@users.noreply.github.com>
Co-authored-by: MartinP <77325495+Mape6@users.noreply.github.com>
Co-authored-by: nukurette <76560753+nukurette@users.noreply.github.com>
Co-authored-by: ArchDuque-Pancake <78449553+ArchDuque-Pancake@users.noreply.github.com>
Co-authored-by: Rodolfz147 <100000475+Rodolfz147@users.noreply.github.com>
2022-02-19 19:40:16 +02:00
Yair Morgenstern
6d48f99206
Trigger uniques by sacrificing units with conditional (#6157)
* 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
2022-02-19 19:38:39 +02:00
Xander Lenstra
a8be359ed2
Damage in battle table is now the average damage done (#6176)
* Damage in battle table is now the average damage done

* Trailing comma's

* Fixed typo
2022-02-19 19:34:46 +02:00
itanasi
402a9ba825
Show Improvements that are buildable after Removing TerrainFeature (#6149)
* Initial working version!

* More comments

* Add missing .tr() translation calls

* add brackets

* Fixed

* Optimize checking for removable last feature
More complete tileInfo.clone()

Co-authored-by: itanasi <spellman23@gmail.com>
2022-02-19 19:34:27 +02:00
Xander Lenstra
f9bab01a64
Added conditional checking for tiles (#6187)
* Added conditional checking for tiles

* Fixed compile error

* I actually like this variable more over here
2022-02-19 19:33:44 +02:00
Yair Morgenstern
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
SomeTroglodyte
6e92ea4d29
Fix for #6178 music resumes after minimizing on android (#6195) 2022-02-19 18:40:52 +02:00
itanasi
2d60fe4565
Prevent Civilians from capturing Civilians (#6185)
* 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>
2022-02-19 18:37:38 +02:00