mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-30 17:34:57 +07:00
Fixed crash when policy prerequisite is a branch (#8273)
Co-authored-by: tunerzinc@gmail.com <vfylfhby>
This commit is contained in:
parent
38d13570a7
commit
41b5cfa9b1
@ -446,13 +446,17 @@ class PolicyPickerScreen(val worldScreen: WorldScreen, civInfo: CivilizationInfo
|
|||||||
continue
|
continue
|
||||||
|
|
||||||
val prereqButton = policyNameToButton[prereqName]
|
val prereqButton = policyNameToButton[prereqName]
|
||||||
drawLine(group,
|
if (prereqButton != null) {
|
||||||
// Top center
|
drawLine(
|
||||||
policyButton.x+policyButton.width/2,
|
group,
|
||||||
policyButton.y+policyButton.height,
|
// Top center
|
||||||
// Bottom center
|
policyButton.x + policyButton.width / 2,
|
||||||
prereqButton!!.x + prereqButton.width/2,
|
policyButton.y + policyButton.height,
|
||||||
prereqButton.y)
|
// Bottom center
|
||||||
|
prereqButton.x + prereqButton.width / 2,
|
||||||
|
prereqButton.y
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user