fixed workers again.
This commit is contained in:
@@ -51,7 +51,7 @@ void DouwcoHivemind::Worker::loop() {
|
||||
}
|
||||
|
||||
void DouwcoHivemind::Worker::getEnergy() {
|
||||
if (foundContainer) collectEnergyFromContainers();
|
||||
if (foundContainer || Screeps::Game.time()%100==0) collectEnergyFromContainers();
|
||||
else harvestSource();
|
||||
}
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ bool DouwcoHivemind::Room::placeContainers() {
|
||||
auto sources = room.find(Screeps::FIND_SOURCES);
|
||||
|
||||
// No containers planned or build, planning now
|
||||
if (sourceContainers.size() != sources.size()) {
|
||||
if (sourceContainers.size() < sources.size()) {
|
||||
int controller_x = room.controller().value().pos().x();
|
||||
int controller_y = room.controller().value().pos().y();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user