Commit Graph

9941 Commits

Author SHA1 Message Date
Yair Morgenstern
0625cb7087 Resolved #10698 - Fixed city-state type coloring 2023-12-10 22:19:54 +02:00
Yair Morgenstern
2ae5a018de Added initial pathfinding tests 2023-12-08 14:48:48 +02:00
Yair Morgenstern
cce678800f Fixed pillage tests 2023-12-08 14:10:56 +02:00
Yair Morgenstern
c483c4329a Console: Added 'unit setmovement' command 2023-12-08 13:45:57 +02:00
Yair Morgenstern
ee8f8a3c89 Fixed compilation error 2023-12-08 13:31:34 +02:00
Yair Morgenstern
aa1b5af19d standardized exploration actions 2023-12-08 13:30:10 +02:00
Yair Morgenstern
fad06b3aec standardized pillage, sleep actions 2023-12-08 13:24:21 +02:00
Yair Morgenstern
840f3c2093 standardized automate action 2023-12-08 12:23:00 +02:00
Yair Morgenstern
2ffec93ae8 invokeUnitAction will take the first *actionable* action, instead of the first one that exists, which may not be actionable 2023-12-08 12:17:07 +02:00
Yair Morgenstern
40283078d4 "Can instantly construct a [improvementFilter] improvement" works with improvementFilter 2023-12-07 23:09:05 +02:00
Yair Morgenstern
2fbe227285 Fixed work boat automation 2023-12-07 23:01:55 +02:00
Yair Morgenstern
1723cc36f1 chore: city settle action readability 2023-12-07 22:49:23 +02:00
Yair Morgenstern
d4f53bf813 Standardized 'add in capital' action 2023-12-07 22:41:27 +02:00
Yair Morgenstern
612545eec5 Standardized 'spread religion' / 'remove heresy' actions 2023-12-07 19:56:34 +02:00
Yair Morgenstern
c4310fb0f9 Standardized 'spread religion' / 'remove heresy' actions 2023-12-07 19:54:46 +02:00
Yair Morgenstern
8f049f45f1 Standardized 'create improvement' uniques - need to remember to deprecate the water improvements! 2023-12-07 19:47:45 +02:00
Yair Morgenstern
d1649d7c41 4.9.6 2023-12-07 10:17:45 +02:00
Yair Morgenstern
7211c04595
Version rollout (#10678)
* Bump version and create initial changelog entry

* Update Spanish.properties (#10675)

* Update Italian.properties (#10673)

* Update French.properties (#10669)

* Update Polish.properties (#10668)

* Update Dutch.properties (#10666)

* Update Dutch.properties

* Update Dutch.properties

* Update Italian.properties

* Update Russian.properties

* Update German.properties

* Update Swedish.properties

* Update Ukrainian.properties

* Update Brazilian_Portuguese.properties

* Update Catalan.properties

* Update Czech.properties

* Update Filipino.properties

* Update Catalan.properties (#10662)

* Update Brazilian_Portuguese.properties (#10661)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: Caballero Arepa <78449553+Caballero-Arepa@users.noreply.github.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: Lesiakower <125187776+Lesiakower@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: Vitor Gabriel <59321138+Ranbut@users.noreply.github.com>
2023-12-07 10:13:59 +02:00
Why-not-now
530a537d46
Standardised and fixed deprecration warning (#10672)
* Standardised and fixed deprecration warning

* fixed typo

* standardiswd

* lower cased "as of"
2023-12-07 10:09:42 +02:00
SeventhM
d15c3da0e0
Fix not getting unique unit from tile based free unit trigger (#10665) 2023-12-07 10:09:11 +02:00
Ouaz
085bd8cf26
Fix Carthage civilopedia article (#10637)
* Fix Carthage article

A text line was weirdly displayed on top of the article

* Correct fix for Carthage article

Thanks to SomeTroglodyte (again)
2023-12-07 09:15:36 +02:00
Will Allen
8363078371
Connect roads automation (#10631)
* Start on road connect feature.

* Rough UI and tile highlighting

- Highlight visible tiles for selected unit red
-- Maybe change this to all explored tiles
- Move action firing inside WorldMapHolder
- Set begin and end tiles

* Serialize Vector2 instead of Tile

* Add road icon

* Much better UI handling

- Tile highlights go away after choosing a tile
- Added restrictions to allowed tile destination choices.
    - Explored
    - Land
    - Passable
- Added two-tap button

* Refactor part of `onTileClicked` for readability

* Band-aid fix null pointer error

* Add RoadConnection icon

* Tentatively working connect road feature

* AStar search implementation

* AStar connect road automation

* Fix worker getting stuck in city tiles

* Heuristic should be between tiles

* Add heuristic to road connect, remove maxSize limit

* Fix predicates

* Cancel automation when worker is force moved off path

* Change valid/highlighted tiles to be friendly or neutral

* Put log back the way it was

* Fix behavior when kicked off path

* Worker no longer wastes movement points

* Workers will progress multiple tiles at a time towards the next build destination.

* Respect civs with certain tiles as roads

* Refractor ForceAutomateRoadConnection -> AutomateRoadConnection

* Connect road UI button only shows for units with UniqueType.BuildImprovements

* Connect road UI button only show when road tech is unlocked

* Add wagon sound

* Fix destination icon, add KeyboardBinding to 'c'

* UI highlight connect road path tiles orange

* Downsample wagon.mp3

* Apply migration patch, idiomatic sequence processing

* Add notifications on success and failure

* Extract movement cost function to be reusable

* Refactor road pathfinding into MapPathing.kt

* Make pathing calls more general for future extendability

* Add UI road connection tile path preview

* Keep road path highlighting when routing to a city tile

* Adjust road pathing cost function

* Path includes pillaged roads

* Repair pillaged roads along path

* Valid road path tiles now include all passable tiles (open borders)
2023-12-07 09:15:12 +02:00
Ouaz
4a570bcd4f
Add "UI tips" civilopedia article (#10625)
* Add an "UI tips" civilopedia article

* Improve UI Tips article

Credits to @SomeTroglodyte and Yairm

* More improvements to UI Tips article

Credits to SomeTroglodyte
2023-12-07 09:14:51 +02:00
dHannasch
be2cbbf133
Pass-through exclude and filterUniques, respectively (#10649)
* Update BuildingDescriptions.kt

* Update BaseUnitDescriptions.kt

* Update DescriptionHelpers.kt

* Update BuildingDescriptions.kt

* Update DescriptionHelpers.kt
2023-12-07 09:14:33 +02:00
dHannasch
47e6b788af
Add TechManager.isObsolete(unit) (#10659)
* Update TechManager.kt

* Update CityStateFunctions.kt
2023-12-04 20:26:39 +02:00
dHannasch
8a03f9df12
Rename BaseUnit.techsAtWhichNoLongerAvailable() (#10663)
* Update BaseUnit.kt

* Update BaseUnit.kt

* Update RulesetValidator.kt

* Update BaseUnit.kt
2023-12-04 20:26:15 +02:00
Yair Morgenstern
ca20a09a99
Update README.md 2023-12-04 20:23:36 +02:00
dHannasch
48ff198401
Fix failing tests (#10660)
* Update Italian.properties

* Update Russian.properties

* Update German.properties

* Update Polish.properties

* Update Lithuanian.properties

* Update Simplified_Chinese.properties

* Update Korean.properties

* Update Vietnamese.properties

* Update Czech.properties

* Update Hungarian.properties

* Update Dutch.properties

* Update Swedish.properties

* Update Ukrainian.properties

* Update Filipino.properties

* Update French.properties

* Update Indonesian.properties

* Update Catalan.properties

* Update Spanish.properties

* Update Traditional_Chinese.properties

* Update Brazilian_Portuguese.properties
2023-12-04 18:19:33 +02:00
Yair Morgenstern
662c4c219b 4.9.5 2023-12-03 22:28:45 +02:00
Yair Morgenstern
7e869a3616
Version rollout (#10658)
* Bump version and create initial changelog entry

* Update Simplified Chinese (#10652)

* Update Latin.properties (#10642)

* Update Latin.properties

* Update Latin.properties

* Update Brazilian_Portuguese.properties (#10641)

* Update Spanish.properties (#10639)

* Update Spanish.properties

* Update Spanish.properties

* Update Spanish.properties

* Update Polish.properties (#10636)

* Update Polish.properties

* Update Polish.properties

* Update French.properties (#10635)

* Update Italian.properties (#10634)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: chr_56 <30681738+chr56@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: Caballero Arepa <78449553+Caballero-Arepa@users.noreply.github.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
2023-12-03 22:26:28 +02:00
dHannasch
155498dc43
Wrap BaseUnit.obsoleteTech into function (#10648)
* Update BaseUnit.kt

* Update BaseUnit.kt

* Update TechManager.kt

* Update BaseUnit.kt

* Update RulesetValidator.kt

* Update BasicTests.kt
2023-12-03 22:26:16 +02:00
SeventhM
f8315de414
Add trigger from building improvements and trigger conditional for building improvements (#10644)
* Add trigger from building improvements and trigger conditional for building improvements

* Classic case of the forgotten import

* Fix improvement triggerables saying they aren't allowed and move the trigger to its own function

* include the tile in the civ trigger

* Update core/src/com/unciv/models/ruleset/unique/UniqueType.kt

---------

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
2023-12-03 22:16:31 +02:00
dHannasch
c142d1508c
Add iHasUniques.techColumn() (#10595)
* Update IHasUniques.kt

* Update IHasUniques.kt

* Update IConstruction.kt

* Update IHasUniques.kt

* Update CivInfoTransientCache.kt

* Update UnitUpgradeManager.kt

* Update WonderOverviewTab.kt

* Update IHasUniques.kt

* Update IHasUniques.kt

* Update Ruleset.kt

* Update IHasUniques.kt

* Update IHasUniques.kt

* Update IHasUniques.kt

* Update IHasUniques.kt
2023-12-03 22:14:28 +02:00
Oskar Niesen
b9dd32597d
Fixed trading with city-state through notifications (#10645)
* NotificationActions DiplomacyAction no longer allows trading with city-states

* Added a comment
2023-12-03 22:13:30 +02:00
Caballero Arepa
88333a147e
Mention the Railroad production bonus in the Civilopedia (#10638)
* Mention Railroad production bonus in the Civilopedia

* Railroad production bonus mention in the Civilopedia - Vainilla

* Fix little style error

* Fix another mistake

omg

* Brackets

* Brackets
2023-12-03 22:13:04 +02:00
SomeTroglodyte
96dcd584cf
Dev Console: Lint, crash fix, add Stat (#10656)
* Console: linting

* Console: Commands can control message Color

* Console: `civ add gold -1`

* Console: Typo
2023-12-03 22:12:44 +02:00
SomeTroglodyte
5061b29197
Notification for "Policy branch unlocked" clickable (#10655)
* Ruleset-validate some Unique amounts to be positive

* Add TechAction for tech gained from Ruins

* Allow PolicyPickerScreen to highlight a Policy

* Add the 'PolicyAction' NotificationAction

* Use the new PolicyAction
2023-12-03 22:12:26 +02:00
dHannasch
1f47fff05d
Add iHasUniques.requiredTechs (#10587)
* Update IHasUniques.kt

* Update IHasUniques.kt

* Update IConstruction.kt

* Update IHasUniques.kt
2023-12-02 22:56:00 +02:00
dHannasch
7fae32c595
Add iHasUniques.availableInEra() (#10594)
* Update IHasUniques.kt

* Update IHasUniques.kt

* Update IConstruction.kt

* Update IHasUniques.kt

* Update CivInfoTransientCache.kt

* Update UnitUpgradeManager.kt

* Update WonderOverviewTab.kt

* Update IHasUniques.kt

* Update IHasUniques.kt

* Update CityStateFunctions.kt

* Update CityStateFunctions.kt

* Update IHasUniques.kt

* Update CityStateFunctions.kt

* Update CityStateFunctions.kt

* Update CityStateFunctions.kt

* Update CityStateFunctions.kt
2023-12-02 22:54:52 +02:00
dHannasch
55a068d0a0
Add TechManager.isResearched(construction) (#10646)
* Update TechManager.kt

* Update CityStateFunctions.kt

* Update QuestManager.kt

* Update UnitUpgradeManager.kt

* Update Victory.kt

* Update TechManager.kt

* Update TechManager.kt
2023-12-02 22:53:11 +02:00
Yair Morgenstern
75a4f06d03 Converted create/enhance religion actions to new format 2023-12-02 22:45:18 +02:00
Yair Morgenstern
c48584868d Converted Great Person actions to new format 2023-12-02 22:33:54 +02:00
Yair Morgenstern
4c113a9aba
RFC: Direction for converting unit actions to map (#10632)
* Direction for converting unit actions, so that invokeUnitAction() doesn't try to generate *all* possible unit actions just to choose one

* Mapped many unit actions
2023-12-01 11:32:04 +02:00
Yair Morgenstern
37586370ea Resolved #10640 - start turn with unit selected 2023-12-01 10:25:59 +02:00
Yair Morgenstern
f36b05f6c0 Revert "Resolved #10630 - "[relativeAmount]% [stat] from every follower, up to [relativeAmount]%" works off of majority religion, not our religion"
This reverts commit 199b3ada93.
2023-12-01 10:23:17 +02:00
Yair Morgenstern
afae9a1e96 4.9.4 2023-11-30 19:51:36 +02:00
Yair Morgenstern
4b8bef5def
Version rollout (#10633)
* Bump version and create initial changelog entry

* Update Spanish.properties (#10627)

* Update Brazilian_Portuguese.properties (#10616)

* Update French.properties (#10615)

* Update French.properties

* Update French.properties

- Improve translation of leader lines

* Update Italian.properties (#10612)

---------

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: Caballero Arepa <78449553+Caballero-Arepa@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: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
2023-11-30 19:44:30 +02:00
SomeTroglodyte
30f3a8f712
Fix crash for trade notifications as Spectator or during waiting for player (#10614)
* Fix crash when tapping a Diplomacy notification for trades as Spectator or during waiting for player

* Fix no tech showing as researched when tapping a Tech researched notification as Spectator
2023-11-30 19:35:18 +02:00
Will Allen
70bbfe14d6
Mitigate #10619 (#10629)
- Clear all unit movement caches upon a road being pillaged
- Log when this happens
- Minor whitespace fixes
2023-11-30 19:13:39 +02:00
SeventhM
01636c27f0
Add "Unable to pillage tiles" unique (#10623) 2023-11-30 19:13:24 +02:00