Commit Graph

7253 Commits

Author SHA1 Message Date
Xander Lenstra
66feebae8d
Disabled CS buttons when at war; CS keep influence when at war with ally (#6813)
* Disabled CS buttons when at war; CS keep influence when at war with ally
This PR does two things:
- When you are at war with a city state, you can no longer give them 
money, demand stuff, etc.
- When at war with the ally of a city state, your influence is frozen, 
and after the end of the conflict set back to its original value.
To implement this last thing, I had to split the getter of `influence` 
off of the underlying field, as otherwise when copying over the old 
value in `.clone()`, we would copy over -60 when at war, instead of the 
original value. Most of the changes in that PR are a result of that.
Also resets the `simulateUntilTurns` variable after completing 
simulations

* Updated comment
2022-05-15 17:56:26 +03:00
SomeTroglodyte
07562f23ff
Accelerate custom map selection a tiny bit (#6815) 2022-05-15 15:15:58 +02:00
SomeTroglodyte
6021dcadb8
Allow editor to generate rectangular Deciv redux maps (#6816) 2022-05-15 15:49:51 +03:00
SomeTroglodyte
049df797f3
Minor Map Editor improvements (#6795)
* Map Editor - fix changing resources bugged by tileResource lazy

* Map Editor - apply resource deposit abundance from map's parameters

* Map Editor - resource abundance - readability
2022-05-15 09:56:18 +02:00
SomeTroglodyte
03579a884d
Fix TabbedPager stealing arrow keys from TextFields (#6809) 2022-05-15 01:11:15 +02:00
SomeTroglodyte
05f656b6c1
Crash Report omits GameInfo stuff when crashing from MainMenu, MapEditor or Options (#6808) 2022-05-15 00:32:39 +02:00
Timo T
f8e0f572e4
Use kotlin coroutines instead of raw threads (+ refactorings) (#6801)
* Refactor: Move classes into their own files

* Handle 404 FileNotFound in UncivServer

* Refactor: Rename method

* Make GameSaver.saveGame throw the exception by default if it is not handled

* Add possibility to work with FileHandles in GameSaver

* Make OnlineMultiplayerGameSaver load the multiplayerServer setting each time it does something

This theoretically makes it unnecessary for the OnlineMultiplayerGameSaver to be re-instantiated each time it is used

* Refactor: Remove duplicated code

* Refactor: Extract NextTurnButton from WorldScreen

* Refactor: Remove WorldScreen-specific code from OptionsPopup

* Use kotlin coroutines everywhere instead of plain threads

This probably also cuts down on our raw thread usage, improving performance, since we now use a cached thread pool (in addition to coroutines being able to reuse threads anyway)

* Improve deep load from notification

* Refactor: Give music download coroutine the proper name
2022-05-15 00:52:45 +03:00
Md. Touhidur Rahman
47728afafa
Suggest Temurin Instead of Zulu (#6799) 2022-05-14 23:40:23 +03:00
OptimizedForDensity
4e72906488
Capital movement tweaks (#6800)
* Capital movement changes

* Cleanup

* Fix liberation condition

* Cleanup

* Fix wrong condition

* Fixed oversights

* One more

Co-authored-by: OptimizedForDensity <>
2022-05-14 23:39:49 +03:00
Md. Touhidur Rahman
e73b73ed87
Enable gradle caching for faster CI runs (#6793)
* Enable gradle caching for faster CI runs

Notes:
1. distribution is mandatory in v3
2. zulu is used because it was recommended in wiki

* use temurin
2022-05-14 23:29:11 +03:00
Timo T
457b20d2de
Bump kotlin language version to latest 1.6.21 (#6744)
Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
2022-05-14 23:24:55 +03:00
SomeTroglodyte
816e542e1c
Notifications not scrollable far enough after in-turn notifications got added (#6796) 2022-05-14 23:19:02 +03:00
Xander Lenstra
2cb63c8a42
Fixed a bug where roads could no longer be removed (#6806) 2022-05-14 23:18:31 +03:00
Yair Morgenstern
1ca1342816 Upgraded to libGDX 1.11.0 - resolves #6609, resolves #5679
Also cleaned up the build.gradle file
2022-05-13 15:16:54 +03:00
Yair Morgenstern
e94d109166 4.0.16 2022-05-13 13:00:20 +03:00
xk730
ba96a85691
Update Simplified_Chinese.properties (#6775)
Correct language defects and ambiguities and fill in gaps
2022-05-13 12:53:22 +03:00
Yair Morgenstern
66abc2f779
Version rollout (#6789)
* Bump version and create initial changelog entry

* Update Russian.properties (#6787)

* Update Russian.properties

* Fix translation

* Update Spanish.properties (#6782)

511 - Yes, the double space is intentional

* Add Fastlane_short_description translations (#6781)

Also added Civ V - Vanilla and Civ V - Gods and Kings translation.

* Update German translation (#6778)

* Update French.properties (#6769)

* Update Indonesian.properties (#6768)

* Update Simplified_Chinese.properties (#6766)

* Update Simplified_Chinese.properties

* Make 2 translation together (#1)

* Fetch the latest update
* Update Simplified_Chinese.properties

Correct language defects and ambiguities and fill in gaps

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
Co-authored-by: Xander Lenstra <71121390+xlenstra@users.noreply.github.com>
Co-authored-by: xk730 <40309144+xk730@users.noreply.github.com>

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
Co-authored-by: Xander Lenstra <71121390+xlenstra@users.noreply.github.com>
Co-authored-by: xk730 <40309144+xk730@users.noreply.github.com>

* Update Italian.properties (#6765)

* Update Korean.properties (#6754)

* Update Korean.properties

* Update Korean.properties

* Update Korean.properties

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

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: deqtodo <94169613+deqtodo@users.noreply.github.com>
Co-authored-by: Caballero Arepa <78449553+ArchDuque-Pancake@users.noreply.github.com>
Co-authored-by: nilleh <72703236+niltok64@users.noreply.github.com>
Co-authored-by: MartinP <77325495+Mape6@users.noreply.github.com>
Co-authored-by: Ouaz <Ouaz@users.noreply.github.com>
Co-authored-by: kensvin <63847755+Kensvin28@users.noreply.github.com>
Co-authored-by: heipizhu4 <100454479+heipizhu4@users.noreply.github.com>
Co-authored-by: Xander Lenstra <71121390+xlenstra@users.noreply.github.com>
Co-authored-by: xk730 <40309144+xk730@users.noreply.github.com>
Co-authored-by: Giuseppe D'Addio <41149920+Smashfanful@users.noreply.github.com>
Co-authored-by: Auvergne <97716654+ARPD-release@users.noreply.github.com>
2022-05-13 12:52:53 +03:00
SomeTroglodyte
345ca0ec25
Pedia from mainmenu (#6788)
* Make Civilopedia independent of worldScreen or gameInfo

* Make Civilopedia callable from Main Menu

* Era category for Civilopedia

* Era category for Civilopedia - atlas
2022-05-13 12:36:06 +03:00
Jack Rainy
ab82328211
Missing typed uniques for the units - part 2 (#6749)
* Replacements for existing UniqueTypes

* More typed uniques are added

* Migration to the typed uniques

* Minor optimization

* More general approach on UniqueType usage

* Better wording for the UniqueType
2022-05-13 12:34:10 +03:00
Yair Morgenstern
f0461121e4
Resolved #6767 - AI will not declare war if it definitely can't take a city (#6771)
* Resolved #6767 - AI will not declare war if it definitely can't take a city

* Not sure what would happen if you try to calculate damage for civilian attacker and don't care to find out
2022-05-13 12:33:21 +03:00
Leonard Günther
09b4e82589
Rate limit handling for Dropbox (#6416)
* Added rate limit handling to dropbox

+ some refactor to make the whole file one object

* Added error messages on rate limit reached

+ refactored some popup code to reduce repetition

* Fixed merge error

* Made variables private

* Fixed file upload not working

because of missing override flag for dropbox

* Stop multiplayer refresher if rate limit reached

* Fixed typo

* Various code changes/fixes

- ErrorResponse var name has to be `error` because that's how DropBox's json property is named
- Change FileStorageRateLimitReached exception to store the seconds remaining as its own property instead of in the message
- Use toIntOrNull to avoid setting defaults in two places

* Fixed missed exception message

Co-authored-by: Azzurite <azzurite@gmail.com>
2022-05-13 09:16:52 +03:00
OptimizedForDensity
4ab7d56c14
Use ranged strength when defending against ranged attacks (#6783)
* Ranged units should use ranged strength when defending against ranged attacks.

* Renamed variable plus some minor style cleanup

Co-authored-by: OptimizedForDensity <>
2022-05-13 00:11:04 +03:00
Xander Lenstra
940f361a5f
Fixed a bug where improvements could no longer be built by workers (#6780) 2022-05-12 18:28:59 +02:00
OptimizedForDensity
574b94e417
Hide cities where wonders are built until city is explored (#6773)
* Hide city on wonder screen until city tile is explored

* Forgot to delete commented out line

Co-authored-by: OptimizedForDensity <>
2022-05-12 07:22:55 +03:00
Xander Lenstra
c9dc0bae06
Fixed a bug where roads seemingly removed improvements (#6770) 2022-05-12 00:40:10 +03:00
Yair Morgenstern
fb521f3f9d
Update config.yml 2022-05-11 19:12:10 +03:00
Yair Morgenstern
0894f9cb66
Update feature_request.md 2022-05-11 19:11:04 +03:00
Yair Morgenstern
5877d3e62a
Create config.yml 2022-05-11 19:08:07 +03:00
Yair Morgenstern
73f4d9042d 4.0.15-patch1 2022-05-11 17:59:06 +03:00
Yair Morgenstern
3e63be5376 4.0.15-patch1
Extra images fixed and HexaRealm added :)
2022-05-11 17:58:30 +03:00
The Bucketeer
e9ffe7667c
Proposal to add the current HexaRealm tileset as the built-in tileset. (for serious this time.) (#6756)
* Create posh

* HexaRealm tile sprites upload (part 1)

* HexaRealm tile sprites upload (part2)

* HexaRealm tile sprites upload (part 3)

* Upload HexaRealm.json

Should have no problem in terms of most of the layering!

* Delete posh

* Delete bana.png
2022-05-11 17:34:46 +03:00
Yair Morgenstern
65656531ee Fastlane descriptions 2022-05-11 17:23:40 +03:00
Yair Morgenstern
cd002699f3 4.0.15 2022-05-11 17:22:31 +03:00
Yair Morgenstern
97b8bd106a
Version rollout (#6762)
* Bump version and create initial changelog entry

* Update Simplified_Chinese.properties (#6753)

Correct some translation errors

* Update Romanian.properties (#6748)

* 1

* 2 - most city names don't have a translation

* 3 - more cities

* Update Turkish.properties (#6746)

* Update French.properties (#6738)

* Update Italian.properties (#6734)

* Update Indonesian.properties (#6733)

* Update German translation (#6732)

* Update Filipino.properties (#6729)

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: xk730 <40309144+xk730@users.noreply.github.com>
Co-authored-by: alexban011 <alexban011@gmail.com>
Co-authored-by: omerfaruk-cakmak <32402595+omerfaruk-cakmak@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>
Co-authored-by: kensvin <63847755+Kensvin28@users.noreply.github.com>
Co-authored-by: MartinP <77325495+Mape6@users.noreply.github.com>
Co-authored-by: Shann Aurelle Ripalda <shannaurelleg@gmail.com>
2022-05-11 17:05:17 +03:00
alexban011
dc8dadfcab
Fixed proxy issues when starting a new multiplayer game (#6757)
* vpn/proxy issues when creating new mp game

replaced redundant ping with opening a connection to dropbox to fix the proxy issue

* updated error message to include dropbox

* check multiplayerServer url if the user is playing on it

* use `https://content.dropboxapi.com` instead of `https://www.dropbox.com`

* fixed proxy issues on android

if connected to proxy but no internet access it will freeze for a couple seconds (until it finishes the for loop) but it works

* forgot to add the imports

* removed android sdk network check to fix proxy issues

* check for internet now separate from check for multiplayerServer
removed frunctions from PlatformSpecificHelpers__

* added improvements made by touhidurrr

* removed unused imports and replaced setter with property access syntax

Co-authored-by: Md. Touhidur Rahman <46617994+touhidurrr@users.noreply.github.com>
2022-05-11 16:58:20 +03:00
Yair Morgenstern
e348a20d2e Extracted policies, religions, nations and promotions to separate png files in order to fit HexaRealm tileset into the main file - see #6756 2022-05-11 16:57:39 +03:00
SomeTroglodyte
eb5e8ae226
Switchable gzipping of saved games (#6735)
* Switchable gzipping of saved games

* Switchable gzipping of saved games - consensus says default off
2022-05-11 16:23:11 +03:00
Timo T
1bbf5514cf
Add UncivServer.jar to github release (#6745) 2022-05-11 16:22:21 +03:00
SomeTroglodyte
addfddb2ec
Update wiki Building-locally.md for AS Chipmunk (#6761) 2022-05-11 16:19:56 +03:00
Md. Touhidur Rahman
45739a172d
improve autofix on multiplayerServer from url input (#6759) 2022-05-11 15:18:00 +03:00
OptimizedForDensity
5a78c59405
Hide Unmet Civ and Capital Names in the Victory Status Screen (#6742)
* Hide the names of unmet yet alive civs in the victory screen.

Mainly affects the DestroyAllPlayers victory but the CaptureAllCapitals (as capital name) and WorldReligion victory code is updated accordingly.

* Redundant condition since dead civs can't hold cities.

* Formatting + undid CaptureAllCapitals name obscuring since there could be some cases where the known capital name suddenly becomes unknown.

* Parameterized if statement

* Hide other capital names until the tile is explored.

* New constant for an unknown city name.

Co-authored-by: OptimizedForDensity <>
2022-05-11 11:46:37 +03:00
Md. Touhidur Rahman
531906f5ba
Autofix Multiplayer Server URL on input (#6743)
* Autofix Multiplayer Server URL on input, resolves #6583

* some improvements
2022-05-11 09:36:08 +02:00
Xander Lenstra
8fcfbf752b
Improved clarity and moddability of building improvements (#6712)
* Renamed tile.hasUnique, deprecated `Indestructable`, unique for citadels
Also refactored the consumption of (great) people out of UnitActions.

* Reworked when improvements can be build somewhere for more clarity

* Made resources improvable by multiple improvements; Offshore Platform

* Fix compatability

* WIP

* Fixed the tests, but better

* I suppose I might as well update this now that we're a version later
2022-05-11 00:35:21 +02:00
SomeTroglodyte
7b4833741d
Fix missing translatables, again (#6705) 2022-05-11 00:21:38 +03:00
Timo T
7841f57fc8
Fix spectator not being able to view tile improvements or city buttons (#6741) 2022-05-10 12:33:10 +02:00
SomeTroglodyte
ecd328afc3
Four Uniques typed - Blitz, Haka Dance, Hakkapeliitta, Amphibious (#6740)
* Four Uniques typed - Blitz, Haka Dance, Hakkapeliitta, Amphibious
2022-05-10 01:04:05 +03:00
SomeTroglodyte
0ba71e2c6b
Allow untyped Uniques in MapUnit UniqueMap (#6739) 2022-05-09 23:49:35 +03:00
Yair Morgenstern
ba96bea556 4.0.14 2022-05-08 21:42:19 +03:00
Yair Morgenstern
4fe775c0f5
Version rollout (#6726)
* Bump version and create initial changelog entry

* Update Filipino.properties (#6714)

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Filipino.properties

* Update Romanian.properties (#6713)

* Fixed issue #6649 by checking for internet connection before starting the game if "online multiplayer" is selected
Many thanks to @SomeTroglodyte for most of the code and for explanations

* Revert "Fixed issue #6649 by checking for internet connection before starting the game if "online multiplayer" is selected"

This reverts commit bae7d7c07f.

* some translations

* merging with 4.0.13

* fixed a little error

* fixed github check error

* Update German translation (#6710)

* Update German translation

* Update German translation

* Update German translation

* Update Italian.properties (#6708)

* Update French.properties (#6697)

* Update French.properties

* Update French.properties to 4.0.13

Co-authored-by: yairm210 <yairm210@users.noreply.github.com>
Co-authored-by: Shann Aurelle Ripalda <shannaurelleg@gmail.com>
Co-authored-by: alexban011 <alexban011@gmail.com>
Co-authored-by: MartinP <77325495+Mape6@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>
2022-05-08 21:29:33 +03:00
SomeTroglodyte
4290373cf1
Move UncivServer to own module (and jar) (#6468)
* Move UncivServer to own module (and jar)

* UncivServer isalive logged

* Separate UncivServer - some wiki hints

* Separate UncivServer - how to build UncivServer.jar

Co-authored-by: Yair Morgenstern <yairm210@hotmail.com>
2022-05-08 21:22:43 +03:00