diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/role.harvester.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/role.harvester.js b/src/role.harvester.js index 5eaf2ef..e372ba4 100644 --- a/src/role.harvester.js +++ b/src/role.harvester.js @@ -4,12 +4,12 @@ module.exports = { // just use the first sourrce for now const source = creep.room.find(FIND_SOURCES)[0]; if (creep.harvest(source) == ERR_NOT_IN_RANGE) { - creep.moveTo(source); + creep.moveTo(source, { range: 1 }); } } else { const spawn = Game.spawns['Initial']; if (creep.transfer(spawn, RESOURCE_ENERGY) == ERR_NOT_IN_RANGE) { - creep.moveTo(spawn); + creep.moveTo(spawn, { range: 1 }); } } } |
