From 7cd6a68639fab875c225075e059bbbd97d3491b4 Mon Sep 17 00:00:00 2001 From: Gualdimar Date: Sun, 19 Mar 2023 22:41:06 +0200 Subject: [PATCH] Fixed exploit in the foreign city religion info table (#8967) --- .../com/unciv/ui/screens/cityscreen/CityReligionInfoTable.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/src/com/unciv/ui/screens/cityscreen/CityReligionInfoTable.kt b/core/src/com/unciv/ui/screens/cityscreen/CityReligionInfoTable.kt index fd48392f24..04e9261d98 100644 --- a/core/src/com/unciv/ui/screens/cityscreen/CityReligionInfoTable.kt +++ b/core/src/com/unciv/ui/screens/cityscreen/CityReligionInfoTable.kt @@ -3,6 +3,7 @@ package com.unciv.ui.screens.cityscreen import com.badlogic.gdx.graphics.Color import com.badlogic.gdx.scenes.scene2d.ui.Table import com.unciv.Constants +import com.unciv.GUI import com.unciv.UncivGame import com.unciv.logic.city.managers.CityReligionManager import com.unciv.models.Religion @@ -84,7 +85,7 @@ class CityReligionInfoTable( if (religion == null) return icon icon.onClick { val newScreen = if (religion == iconName) { - EmpireOverviewScreen(civInfo, EmpireOverviewCategories.Religion, religion) + EmpireOverviewScreen(GUI.getViewingPlayer(), EmpireOverviewCategories.Religion, religion) } else { CivilopediaScreen(gameInfo.ruleset, CivilopediaCategories.Belief, religion) }