mirror of
https://github.com/yairm210/Unciv.git
synced 2025-02-01 02:14:51 +07:00
Fixed an issue where mods with either the 'patronage' or 'entrepreneurschip' policy would crash upon taking it (#4192)
This commit is contained in:
parent
3686366156
commit
8f26a77b2d
@ -57,11 +57,15 @@ class PolicyManager {
|
||||
|
||||
fun setTransients() {
|
||||
// Reassign policies deprecated in 3.14.17, left for backwards compatibility
|
||||
if (adoptedPolicies.contains("Patronage")) {
|
||||
if (adoptedPolicies.contains("Patronage") &&
|
||||
!civInfo.gameInfo.ruleSet.policies.contains("Patronage")
|
||||
) {
|
||||
adoptedPolicies.add("Merchant Navy")
|
||||
adoptedPolicies.remove("Patronage")
|
||||
}
|
||||
if (adoptedPolicies.contains("Entrepreneurship")) {
|
||||
if (adoptedPolicies.contains("Entrepreneurship") &&
|
||||
!civInfo.gameInfo.ruleSet.policies.contains("Entrepreneurship")
|
||||
) {
|
||||
adoptedPolicies.add("Naval Tradition")
|
||||
adoptedPolicies.remove("Entrepreneurship")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user