Commit Graph

9268 Commits

Author SHA1 Message Date
SomeTroglodyte
b838d8ec5a
Overhaul NUKE code to behave closer to original (#9797)
* Overhaul NUKE code to behave closer to original

* Separate garrison protection of Bomb Shelter to its own Unique

* Reduce code duplication: getNukeBlastRadius

* Disallow nuking unknown civs

* Don't show Nuke attack table when the Nuke has just been selected

* World map display of nuke blast radius and friendly fire
2023-07-30 17:39:28 +03:00
SomeTroglodyte
443bf3afdb
Local mod folder names preserved. (#9844)
* Reduce conversion of local mod folder names to treat only ending spaces/dashes

* Wiki entry for GlobalUniques

* Missing originRuleset coverage

* Nicer RulesetValidator messages when name or originRuleset are missing
2023-07-30 17:38:33 +03:00
SomeTroglodyte
b992144ecd
Fix a few now flagged but working Unique targets (#9845)
* Allow a few working UniqueType-UniqueTarget combos in RulesetValidator

* RulesetValidator checks GlobalUniques

* Alternate Settlers and Workers recognized via Unique - same rules in RulesetValidator and GameStarter, wiki clarification
2023-07-30 17:38:26 +03:00
SeventhM
ae7ac6a063
Fix resources subtracting in an incorrect manner when they have the same source (#9858) 2023-07-30 17:38:00 +03:00
SomeTroglodyte
bb7c75840e
Simple Originating-Mod display in Civilopedia (#9850)
* Simple Originating-Mod display in Civilopedia

* Simple Originating-Mod display in Civilopedia - patch
2023-07-30 17:37:50 +03:00
Oskar Niesen
df7fd27b94
Spectator can now see all invisible units including submarines without fog of war. (#9852) 2023-07-30 17:37:36 +03:00
SeventhM
283edd0875
Fix free buildings from other buildings not showing up correctly (#9857)
* Rearrange order of actions when adding buildings

* Turns out you need to updateCivResources after adding in uniques. Whoops

* Mirror change to remove buildings as well
2023-07-30 17:37:24 +03:00
itanasi
488ec9f82f
Fix logic in Fog Busting (#9855) 2023-07-30 17:36:38 +03:00
itanasi
73e06a114f
Update SDK Platforms text. Update photos (#9848)
* Update SDK Platforms text. Update photos

* Try to fix link for Markdown Screenshots

* Revert to docs link

* Try Unciv in file path
2023-07-29 23:12:16 +03:00
alexban011
5f8c675512
Fix linting warnings (#9701)
* fix: VariableNaming warnings

* fix: MatchingDeclarationName warnings

* fix: SwallowedException warnings

* fix: UseRequire warnings

* Revert "fix: MatchingDeclarationName warnings"

This reverts commit 9475af5052.
2023-07-26 07:30:14 +03:00
Yair Morgenstern
3c76e2bc64 4.7.10 2023-07-24 11:28:47 +03:00
Yair Morgenstern
b2d87c4a3e Replace fixed text in translations as well 2023-07-24 10:52:16 +03:00
Yair Morgenstern
48ad5780d9
Version rollout (#9843)
* Bump version and create initial changelog entry

* Update Simplified_Chinese.properties (#9835)

* more Persian UN Translation (#9832)

* Update Persian_(Pinglish-UN).properties

Added and fixed some of the translations till line 1039.

* Update Persian_(Pinglish-UN).properties

- Fixed a few till 1039.
- Added and fixed some from 1039 till 1254.

* Update Persian_(Pinglish-UN).properties

Added and fixed some till 5000

* Update Persian_(Pinglish-UN).properties

* Update Persian_(Pinglish-UN).properties

* Update Dutch.properties (#9816)

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Updated Brazilian_Portuguese.properties (#9813)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: AutumnPizazz <114050365+AutumnPizazz@users.noreply.github.com>
Co-authored-by: Ilia <81512402+ilia-abbasi@users.noreply.github.com>
Co-authored-by: Lena Bullens <95299589+LenaBullens@users.noreply.github.com>
Co-authored-by: Vitor Gabriel <59321138+Ranbut@users.noreply.github.com>
2023-07-24 10:51:13 +03:00
Lena Bullens
c3897fde07
Correct declaringWar key / English translation (#9838)
* Update Nations.json

* Update Nations.json
2023-07-24 10:42:44 +03:00
Oskar Niesen
6dcad3add5
Fixed automated workers not replacing forts for AI civ. (#9837)
* Fixed automated workers not replacing forts for AI civ.

* Fixed double parenthesis.

* Removed repeat removing fort in progress code.

* Improved evaluateFortPlacement
2023-07-24 10:42:18 +03:00
Tali Ondo
0ca4d3ef44
Fixed word typo in README.md (#9842)
"non-existant" -> "non-existent"
2023-07-24 10:41:46 +03:00
Yair Morgenstern
2d499703d7 Resolved #9840 - targetSdk set to 33
Due to the upcoming Google Play deadline (see https://support.google.com/googleplay/android-developer/answer/11926878)
We're upgrading the target SDK and build tools for Unciv.

What this means for you, is that you need to download BOTH the new Android SDK AND the new build tools to compile to Android
If you're only doing Desktop development, this will not affect you

In Android Studio:
- Double-click shift (for search)
- "SDK manager"
- Go to SDK platforms tab, select Android 13 (Tiramisu) - this will lead to an SDK download
- Go to the SDK Tools tab
- Click 'show package details' at bottom-right
- Click 33.0.2 - this will lead to a Build Tools download
2023-07-24 10:41:08 +03:00
SeventhM
eb17398d78
Modernize Connection Tests (#9831) 2023-07-23 08:18:39 +03:00
Yair Morgenstern
97b80973d1 More BaseUnit unique-finding including type uniques 2023-07-21 15:18:39 +03:00
Yair Morgenstern
bc9b5615eb BaseUnit unique-finding always takes Type uniques into account 2023-07-21 15:09:14 +03:00
Yair Morgenstern
33ae13479d 4.7.9-patch1 2023-07-20 09:24:41 +03:00
SomeTroglodyte
383cb38c7d
NotificationAction compatibility patch (#9824)
* NotificationAction compatibility patch

* NotificationAction compatibility patch
2023-07-20 09:24:25 +03:00
SeventhM
4421a2a54e
Fix issues when adding/removing buildings (#9822) 2023-07-20 09:16:02 +03:00
Yair Morgenstern
a705effb7d 4.7.9 2023-07-18 18:30:24 +03:00
Yair Morgenstern
d7b277b6b5 Memory performance improvement - don't create strings when you can instead hash the list! New ists are cheaper in-memory than new strings (only need to allocate "number of strings in list" pointers, and not "number of chars in all strings" chars) 2023-07-18 18:28:04 +03:00
Yair Morgenstern
ed74b03ff3
Version rollout (#9812)
* Bump version and create initial changelog entry

* Update Catalan.properties (#9807)

* Update Hungarian.properties (#9798)

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Hungarian.properties

* Update Czech.properties (#9795)

* Update Czech.properties

* Update Czech.properties

* Missing brackets fix

* Update Spanish.properties (#9794)

* Update Simplified_Chinese (#9789)

* Update German translation (#9788)

* Update French.properties (#9786)

* Update Dutch.properties (#9785)

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Updated Brazilian_Portuguese.properties (#9784)

* Updated Brazilian_Portuguese.properties

* Update Brazilian_Portuguese.properties

* Update Polish.properties (#9783)

* Update Polish.properties

* Update Polish.properties

* Update Italian.properties (#9782)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: Joan Josep <juanjo.ng.83@gmail.com>
Co-authored-by: balazsszalab <balazsszalab@freemail.hu>
Co-authored-by: jahodovykolac <79529669+jahodovykolac@users.noreply.github.com>
Co-authored-by: Caballero Arepa <78449553+Caballero-Arepa@users.noreply.github.com>
Co-authored-by: chr_56 <30681738+chr56@users.noreply.github.com>
Co-authored-by: mape6 <mape6@posteo.de>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: Lena Bullens <95299589+LenaBullens@users.noreply.github.com>
Co-authored-by: Vitor Gabriel <59321138+Ranbut@users.noreply.github.com>
Co-authored-by: Lesiakower <125187776+Lesiakower@users.noreply.github.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
2023-07-18 18:16:06 +03:00
SeventhM
b37aaeb3c6
Fix issues from gaining free beliefs (#9764)
* Fix issues from gaining free beliefs

* chooseBeliefs code I forgot

* Revert changes to next turn actions and allow for free beliefs while founding/expanding

* Missed a spot
2023-07-18 18:08:59 +03:00
SeventhM
1ca9766811
Fix issues when transferring capitals (#9801)
* Revert previous patches

* Fix the unit test, I guess
2023-07-18 18:08:30 +03:00
SomeTroglodyte
37465b5032
Prevent deserialization problem with Espionage (#9809)
* Prevent deserialization problem with Espionage

* Move comment and explain context a little better
2023-07-18 18:08:18 +03:00
SomeTroglodyte
0e64b8230f
Little Promotion UX improvements (#9808)
* Fix regression incorrectly allowing promotions from Unit Overview

* Autoclose PromotionPicker when all promotions chosen in one go

* Fix Unit Overview not showing new promotions when returning from PromotionPicker
2023-07-18 07:25:00 +03:00
SeventhM
1e66c2e131
Avoid built buildings (#9806)
* Removing most interactions with builtBuildings

* Might as well edit this too

* Fix issues and edit isBuilt

* Simplify isAllBuilt
2023-07-16 23:01:17 +03:00
SomeTroglodyte
a29cdc91e8
Unique target compliance test v2 (#9802)
* Split off some UniqueType helper classes, make regions work in Android Studio and linting

* Fix wrong UniqueType.Stats target

* Fix two Pantheon uniques

* BeliefType a little nicer to read

* More linting

* Implement UniqueTarget validation

* Validation of UniqueTypes allowed as conditionals
2023-07-15 22:06:12 +03:00
Yair Morgenstern
00e008b656 4.7.8-patch1
Resolves #9792 resolves #9791
2023-07-11 16:47:24 +03:00
Yair Morgenstern
4698bd1cdf 4.7.8 2023-07-10 17:07:35 +03:00
Yair Morgenstern
bcd5ad6c69
Version rollout (#9781)
* Bump version and create initial changelog entry

* Update German translation (#9780)

* Update Catalan.properties (#9775)

* [Translation] Update Simplified Chinese (#9771)

* update Simplified_Chinese

* Update Simplified_Chinese

* Update Dutch.properties (#9769)

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Italian.properties (#9762)

* Update Polish.properties (#9759)

* Updated Brazilian_Portuguese.properties (#9758)

* Update French.properties (#9757)

* Update Dutch.properties (#9767)

* Update Dutch.properties

Completing Dutch translation part I

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

---------

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

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: mape6 <mape6@posteo.de>
Co-authored-by: Joan Josep <juanjo.ng.83@gmail.com>
Co-authored-by: chr_56 <30681738+chr56@users.noreply.github.com>
Co-authored-by: Lena Bullens <95299589+LenaBullens@users.noreply.github.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
Co-authored-by: Lesiakower <125187776+Lesiakower@users.noreply.github.com>
Co-authored-by: Vitor Gabriel <59321138+Ranbut@users.noreply.github.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: EmperorPinguin <99119424+EmperorPinguin@users.noreply.github.com>
2023-07-10 17:01:47 +03:00
Yair Morgenstern
4c5db52a5c Change default fallback to HexaRealm instead - it's been ready for a while :) 2023-07-10 16:28:54 +03:00
Yair Morgenstern
ee092a5851
City-level resources (#9774)
* City-level resources are...
- Not displayed in civ top bar
- Not considered civ-level resources (for trade, non-city conditionals, etc)
- Are explicitly treated in city conditionals
- ARE considered for constructing buildings requiring resource
- ARE NOT considered for construction units requiring resource

* getCityResources separates resources by origin so we need to sum them - kudos @SeventhM

* CR fixes

* Added new Civilization.getResourceAmount function

* More usages of civInfo.getResourceAmount()

* Don't add city resource table if it's empty
2023-07-10 16:24:50 +03:00
SomeTroglodyte
a737747284
Little Diplomatic Victory makeover (#9756)
* Linting and give two votes to UN owner

* Allow human player to abstain, show UN 2 votes

* More info on voting results

* AI won't vote for hated enemies

* Improve PopupAlert handling

* Translation templates

* One missing template
2023-07-10 15:25:59 +03:00
random271
8f761642f6
Added notification for destruction of tile improvements [via unit ability] (#9754)
* Added notification for desctruction of tile improvements [via unit ability]

* Modified template properties

* Update template.properties
2023-07-09 23:24:38 +03:00
Yair Morgenstern
3c56319640 Display resource uniques in civilopedia 2023-07-09 11:51:25 +03:00
Yair Morgenstern
31f6a406c2 Resolved #9745 - memory improvement, cache uniquemap for tiles with identical terrain 2023-07-09 10:12:16 +03:00
haimlm
d9b1d22949
Fix docker image name (#9765) 2023-07-07 10:32:45 +03:00
Yair Morgenstern
a1387bca29 4.7.7 2023-07-06 00:49:38 +03:00
Yair Morgenstern
d229d45298
Version rollout (#9755)
* Bump version and create initial changelog entry

* Update Simplified_Chinese.properties (#9744)

* Update Italian.properties (#9737)

* Update Italian.properties

* Update Italian.properties

* Update French.properties (#9733)

* Updated Brazilian_Portuguese.properties (#9732)

* Update Dutch.properties (#9730)

* Update Dutch.properties

* Update Dutch.properties

* Update Dutch.properties

* Update Catalan.properties (#9728)

* Update German translation (#9723)

* Update Polish.properties (#9718)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: maxdu <d.darmax@gmail.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: Vitor Gabriel <59321138+Ranbut@users.noreply.github.com>
Co-authored-by: Lena Bullens <95299589+LenaBullens@users.noreply.github.com>
Co-authored-by: Joan Josep <juanjo.ng.83@gmail.com>
Co-authored-by: mape6 <mape6@posteo.de>
Co-authored-by: Lesiakower <125187776+Lesiakower@users.noreply.github.com>
2023-07-06 00:42:39 +03:00
Yair Morgenstern
8042402c1c Fixed tile filter for civ-related conditions for "upon ending a turn in a [tileFilter] tile" trigger 2023-07-06 00:39:04 +03:00
SeventhM
5ea1d5722b
Fix buildings/units not triggering and golden age stat updates (#9731)
* Fix buildings not triggering, golden age stat updates, and units not triggering

* Forgot import, whoops

* uodate resources and city connection when removing a building

* Move building triggers to function, added unit notification to translations

* Quick edits without android studio sucks

* Add unitActionModifier check back to hasTriggerConditional

---------

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
2023-07-06 00:36:43 +03:00
SeventhM
d2dac66f40
Avoid crashes with incorrect condtionals (#9753) 2023-07-05 22:57:06 +03:00
Yair Morgenstern
fdb07b06c1 Resolved #9740 - incorrect ruleset combos for 'buy building with stat' no longer crash 2023-07-05 21:59:01 +03:00
Yair Morgenstern
103234a6b8 Keep track of what mod each ruleset object comes from, for debug and civilopedia purposes 2023-07-05 21:55:57 +03:00
SomeTroglodyte
6a6a8a0c94
Minimal support for Alpha Frontier-like Workers (#9690)
* Linting

* Cache hasUnique(UniqueType.CreateWaterImprovements)

* Move automateWorkBoats to WorkerAutomation - for readability and better chances to create synergies

* Add a chance for automated Alpha Frontier Workers to create Water improvements

* Reorg random271's Lemming code a little

* Tune Worker automation for buildable Water improvements
2023-07-05 21:11:17 +03:00