mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-08 14:57:58 +07:00
Added an extra barbarian check to nukes (#11454)
This commit is contained in:
@ -39,6 +39,7 @@ object Nuke {
|
|||||||
if (defenderCiv == null) return
|
if (defenderCiv == null) return
|
||||||
// Allow nuking yourself! (Civ5 source: CvUnit::isNukeVictim)
|
// Allow nuking yourself! (Civ5 source: CvUnit::isNukeVictim)
|
||||||
if (defenderCiv == attackerCiv || defenderCiv.isDefeated()) return
|
if (defenderCiv == attackerCiv || defenderCiv.isDefeated()) return
|
||||||
|
if (defenderCiv.isBarbarian()) return
|
||||||
// Gleaned from Civ5 source - this disallows nuking unknown civs even in invisible tiles
|
// Gleaned from Civ5 source - this disallows nuking unknown civs even in invisible tiles
|
||||||
// https://github.com/Gedemon/Civ5-DLL/blob/master/CvGameCoreDLL_Expansion1/CvUnit.cpp#L5056
|
// https://github.com/Gedemon/Civ5-DLL/blob/master/CvGameCoreDLL_Expansion1/CvUnit.cpp#L5056
|
||||||
// https://github.com/Gedemon/Civ5-DLL/blob/master/CvGameCoreDLL_Expansion1/CvTeam.cpp#L986
|
// https://github.com/Gedemon/Civ5-DLL/blob/master/CvGameCoreDLL_Expansion1/CvTeam.cpp#L986
|
||||||
|
Reference in New Issue
Block a user