Commit Graph

2930 Commits

Author SHA1 Message Date
55d0f7f1dd Can now move around the world screen with the arrow keys as well as WASD 2020-10-15 21:09:05 +03:00
c75f0162d5 Added city images by The Bucketeer for all eras up to Modern 2020-10-15 20:01:25 +03:00
8c51833a5a New parameterized uniques (#3250)
* -New unit unique "Bonus as Defender []%". "+25% Combat Bonus when defending" now deprecated, but kept for now for mods. Json promotion changed to fit new syntax.
Defender Bonus modifier "Defender Bonus" added to template.properties for translation.

-"All newly-trained [] units in this city receive the [] promotion" now uses unit category checking.

-New building unique "New [] units start with [] Experience in this city"
This can used by Poland's stable unique replacement in BNW, as it gives extra xp for mounted units.
"New [] units start with [] Experience" is the new nation wide version of this.

"New military units start with [] Experience" is now deprecated, but kept for now for mods. Json policy changed to fit new syntax.

-Unit category checking can now check for "non-air", "military", "military units" and uniques.
Added "military" to template.properties for translation.

-New unit unique "No defensive terrain penalty". Admittedly this is for a mod I'm making.

* translations must have spaces after!

* -Attacker Bonus unique changed to "+[]% Strength when attacking"
Changed Units.json and and Wolf Pack from UnitPromotions.json to this syntax

-Defender Bonus unique changed to "+[]% Strength when defending"
Armor Plating promotions were changed to this syntax
2020-10-14 10:22:49 +03:00
b5a32e64ae City-states personalities (#3259)
* City State Personality

* Introduced 4 personalities for city states: Friendly, Neutral, Hostile and Irrational.
* Influence recovery and degrade depends on city state personality.

* Quests assignement dependant on Personality and Trait

* Personality localization strings
2020-10-14 09:51:31 +03:00
8f535391b3 Influence bar not displayed for city-states that don't know the viewing civ 2020-10-11 22:11:31 +03:00
9a887e4840 Resolved #3254 - food-to-production not added twice when calculating turns to production 2020-10-11 22:10:32 +03:00
80ce4496c9 City states button influence bar (#3248)
* City States influence fix

* Influence when at war = -60f
* Enemies if influence < 0f, neutrality is only from 0f to 30f
* Changed RelationshipLevel accordingly

* City States buttons influence bar

* Influence bar in DiplomacyScreen
2020-10-10 22:59:17 +03:00
f7ff1bd267 Translation generation can handle multiple parameters of the same type 2020-10-09 14:39:41 +03:00
be5f42f94b AI does not construct science-related constructions when all techs have been researched 2020-10-09 14:22:57 +03:00
e292c210c8 Added "Must be next to []" unique for tile improvements 2020-10-08 17:35:25 +03:00
0543c6473f Welp now it builds fine 2020-10-08 17:34:35 +03:00
8df9a4fd7e Merge branch 'master' of https://github.com/yairm210/Unciv 2020-10-08 17:12:01 +03:00
e14db65996 Resolved #3239 - simplified unit actions, which were unnecessarily complicated 2020-10-08 17:11:37 +03:00
fea342a31b Clear Barbarian Camp quest (#3246) 2020-10-08 16:29:56 +03:00
eaa89d69f4 Pixel unit colors based on civilization colors (#3231)
* Enabled Pixel Unit colors based on civilization colors

* Strict pattern for image layers

* Updated docstring

* Reworked layers' retrieval
2020-10-08 15:42:16 +03:00
0b9bcabea4 Added resource-providing building unique 2020-10-08 15:36:00 +03:00
55d904e1cd Confirmation popup when clearing the map in the map editor 2020-10-08 15:34:31 +03:00
36ed648621 Files in the mod folder no longer crash the game on startup 2020-10-08 15:33:55 +03:00
da328c0408 Unified Unit Category Checking For Uniques (#3238)
* Starting unified unit category checking. This will increase flexibility with uniques as well as cut down on uniques that have only a slightly different way of checking unit categories.

Things currently checked by the category checking method are:
Type of unit
Name of unit
Whether unit is wounded
If the unit is land, water, or air

"Bonus vs City y%" still works currently.

Uniques that have been changed/added to use this category checking method so far are:

"Bonus vs x y%"
"[] units deal +[]% damage" (parameterization of "Wounded military units deal +25% damage")
"[] units gain the [] promotion"

If PR approved, using this method for more uniques would be a good idea.

Commented as depecrated are these uniques
"+[]% Strength vs []" (this has not been used in json files)
"Wounded military units deal +25% damage" (policies json file was updated to use parameterized version)

The following was added to template.properties for translating modifiers:

Air
Wounded

* translation ending with a space

* -Changed matchesCategory method for CityCombatant to what was suggested
-Changed matchesCategory method for MapUnitCombatant to what was suggested
-Use type.name instead of type.toString().toLowerCase()
-Lowercasing is no longer allowed for type names and unit names.

I kept the lower cased versions of wounded, land, water, and air for compatibility as several of the uniques are phrased like "Bonus vs land units 25%" and such and have entries in template.properties (ie. land units = ).

* -Lowercasing is no longer allowed. For wounded, land, water or air, you have to either use the capitalized version (ie. "Wounded") or lower case with units (ie. "wounded units"). This lets preexisting uniques that use "wounded units" etc still work while also letting people use the singular capitalized word (ie. "Wounded") for other uniques.

* fixed missing check for wounded units
2020-10-08 13:09:05 +03:00
4fa7c8d4c6 3.11.2 2020-10-08 12:47:08 +03:00
7aedb6d4df Find Player quest (#3237)
* Find Player quest

* Sequences
2020-10-08 12:25:58 +03:00
4e50ea9618 Merge remote-tracking branch 'origin/revert-3240-TechUniques' 2020-10-08 12:23:53 +03:00
18c837a7ed More informative alert for tech modders 2020-10-08 12:21:43 +03:00
236c7a1c15 Revert "When checking for nation uniques, it also checks the tech uniques (#3240)"
This reverts commit 31226c97e8.
2020-10-07 23:05:46 +03:00
31226c97e8 When checking for nation uniques, it also checks the tech uniques (#3240)
* When checking for nation uniques, it also checks the tech uniques

* asSequence() before map
2020-10-07 23:05:06 +03:00
223e52fe32 "matches" is a more intuitive name than "fits" for filtering 2020-10-07 14:17:50 +03:00
a485ad5fa5 Merge branch '3.11.1-patch1' 2020-10-07 14:13:30 +03:00
8c1913c2c4 Total conversion mods should handle missing specialists (altough they really should deal with it) 2020-10-07 14:03:27 +03:00
1a4cc125c3 And for units as well of course 2020-10-07 13:44:42 +03:00
e9835eab12 Resolved #3229 - added "Not displayed as an available construction unless [] is built" unique 2020-10-07 13:41:56 +03:00
1dd82f6f58 Find Natural Wonder Quest implemented (#3211)
* Find Natural Wonder Quest implemented

* List to sequence to list
2020-10-06 13:59:54 +03:00
fa59d4888a Era-specific city tiles for Ancient, Classical and Medieval 2020-10-06 12:22:55 +03:00
bb5eff5250 Battle damage calculations changed to ints, for simplicity 2020-10-06 11:16:33 +03:00
9ffa0bee54 Consolidated Generic Tile Bonus Uniques (including Friendly Land, Foreign Land) (#3232)
* Redid things with help from HadeanLake:

-"+[]% combat bonus in []" Unit Unique
-"+[]% combat bonus for units fighting in []" Nation Unique
-Both of these can check for terrain or Friendly Land or Foreign Land
-Function to add stacking modifiers
-Himeji Castle and Foreign Legion had uniques changed to fit this syntax
-Old way still works for now, but deprecated

* fixed comments about deprecation and the new syntax
2020-10-06 10:52:30 +03:00
f9ebc8aa0f Acquire Great Person Quest implemented (#3210)
* Acquire Great Person Quest implemented

* List to sequence to list
2020-10-06 10:48:59 +03:00
8e53be616d Ui fixes (#3218)
* moving close button to end of the list and setting color to red

* aligning text/icon in main screen top bar
2020-10-06 10:28:13 +03:00
93bf69f3d5 Fixes for minor bugs from the previous version 2020-10-05 23:20:49 +03:00
256eedc7c0 Lines go behind the techs in the tech screen, and are colored so you can trace the path of the current research queue 2020-10-05 12:12:15 +03:00
5553be0d67 Minimap no longer adds city indicator on every update, leading to lower framerate over time 2020-10-05 11:45:55 +03:00
523ed10e68 Specialist names are taken from the json files 2020-10-04 16:25:07 +03:00
58d651bfe2 MODDABLE SPECIALISTS ARE GO! 2020-10-04 16:16:42 +03:00
a24dc7cc69 Completely removed usages of the old getMaxSpecialists 2020-10-04 15:47:57 +03:00
fd6956507d Merge tag '3.11.0-patch1' 2020-10-04 15:20:48 +03:00
be2dd5c068 3.11.0-patch1
Solved some errors that occured as a result of the recent changes assuming the specialists exist, which is not true in revamp mods
2020-10-04 15:18:26 +03:00
2d6c322856 Connect Resource Quest implemented (#3209)
* Removed superfluous filters in getResourceForQuest
2020-10-04 15:01:57 +03:00
67efd6c957 Problem: Some promotions in CIV 5 have multiple effects, but Unciv promotions only allow for one effect (#3219)
Solution: This PR adds "uniques" field to allow for multiple effects, while keeping "effect" field so that rulesets prior to this PR can still work.
2020-10-04 10:55:42 +03:00
3e98e0c00f 3.11.0 2020-10-03 20:48:34 +03:00
bddded04f5 Patch of the promotion exploit (#3214) 2020-10-03 20:24:19 +03:00
300c7179e7 Various Quest relted (#3206)
* Renamed some quests to better ones (Kill Camp -> Clear Barbarian Camp and Kill City State -> Conquer City State)
* Quests names are hardcoded in a enum class
* Quests.json translations automated
2020-10-01 21:08:26 +03:00
a4d1232403 Final conversion of existing specialists to the new format 2020-10-01 17:06:34 +03:00