mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-22 10:54:19 -04:00
Added Settler and Worker enemy actions
This commit is contained in:
parent
c6ebb733a1
commit
bfe43b67c1
@ -80,6 +80,17 @@ class GameInfo {
|
|||||||
private fun automateMoves(civInfo: CivilizationInfo) {
|
private fun automateMoves(civInfo: CivilizationInfo) {
|
||||||
for(unit in civInfo.getCivUnits()){
|
for(unit in civInfo.getCivUnits()){
|
||||||
|
|
||||||
|
if(unit.name=="Settler") {
|
||||||
|
UnitActions().getUnitActions(unit, UnCivGame.Current.worldScreen!!).first { it.name == "Found city" }.action()
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
if(unit.name=="Worker") {
|
||||||
|
unit.doAutomatedAction()
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
fun healUnit(){
|
fun healUnit(){
|
||||||
// If we're low on health then heal
|
// If we're low on health then heal
|
||||||
// todo: go to a more defensible place if there is one
|
// todo: go to a more defensible place if there is one
|
||||||
|
Loading…
x
Reference in New Issue
Block a user