mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-22 10:54:19 -04:00
minor refactor
This commit is contained in:
parent
76d969074a
commit
437f89bffc
@ -97,16 +97,14 @@ object ChatStore {
|
||||
}
|
||||
|
||||
if (chatPopup == null && incomingChatMsg.civName != "System") {
|
||||
if (UncivGame.Current.worldScreen == null) {
|
||||
// user is out of world screen
|
||||
chat.read = false
|
||||
} else if (gameId.equals(UncivGame.Current.worldScreen?.gameInfo?.gameId?.toUUIDOrNull())) {
|
||||
if (gameId.equals(UncivGame.Current.worldScreen?.gameInfo?.gameId?.toUUIDOrNull())) {
|
||||
// ensures that you are not getting notified for your own messages
|
||||
if (UncivGame.Current.worldScreen?.gameInfo?.currentPlayer != incomingChatMsg.civName) {
|
||||
chat.read = false
|
||||
UncivGame.Current.worldScreen?.chatButton?.startFlashing()
|
||||
}
|
||||
} else {
|
||||
// user is out of world screen or
|
||||
// some other game not currently on screen has a message
|
||||
chat.read = false
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user