mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-26 21:35:14 -04:00
This commit is contained in:
parent
b11c01bfdc
commit
30c426959b
@ -238,7 +238,7 @@ class TechManager : IsPartOfGameInfoSerialization {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun addTechnology(techName: String) {
|
fun addTechnology(techName: String) {
|
||||||
techsResearched.add(techName)
|
val isNewTech = techsResearched.add(techName)
|
||||||
|
|
||||||
// this is to avoid concurrent modification problems
|
// this is to avoid concurrent modification problems
|
||||||
val newTech = getRuleset().technologies[techName]!!
|
val newTech = getRuleset().technologies[techName]!!
|
||||||
@ -257,7 +257,8 @@ class TechManager : IsPartOfGameInfoSerialization {
|
|||||||
}
|
}
|
||||||
|
|
||||||
civInfo.addNotification("Research of [$techName] has completed!", TechAction(techName), NotificationIcon.Science, techName)
|
civInfo.addNotification("Research of [$techName] has completed!", TechAction(techName), NotificationIcon.Science, techName)
|
||||||
civInfo.popupAlerts.add(PopupAlert(AlertType.TechResearched, techName))
|
if (isNewTech)
|
||||||
|
civInfo.popupAlerts.add(PopupAlert(AlertType.TechResearched, techName))
|
||||||
|
|
||||||
if (civInfo.playerType == PlayerType.Human) {
|
if (civInfo.playerType == PlayerType.Human) {
|
||||||
for (revealedResource in getRuleset().tileResources.values.filter { techName == it.revealedBy }) {
|
for (revealedResource in getRuleset().tileResources.values.filter { techName == it.revealedBy }) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user