Added small movments when waiting on new target preventing blocking a source.
This commit is contained in:
@@ -17,7 +17,6 @@ void DouwcoHivemind::Spawn::loop()
|
||||
int required_suppliers = 1;
|
||||
int required_maintainers = spawn.room().find(Screeps::FIND_MY_STRUCTURES).size() <= 2 ? 0 : 1;;
|
||||
int required_builders = spawn.room().find(Screeps::FIND_MY_CONSTRUCTION_SITES).size() == 0 ? 0 : 1;
|
||||
|
||||
for (auto &creep : Screeps::Game.creeps())
|
||||
{
|
||||
CreepRole role = creep.second.memory()["role"];
|
||||
@@ -32,7 +31,7 @@ void DouwcoHivemind::Spawn::loop()
|
||||
required_builders--;
|
||||
}
|
||||
|
||||
if (energyAvailable < energyCapacityAvailable && required_suppliers < 2)
|
||||
if (energyAvailable < energyCapacityAvailable && 3 < Screeps::Game.creeps().size())
|
||||
return;
|
||||
std::string name;
|
||||
JSON opts;
|
||||
|
||||
Reference in New Issue
Block a user