Skip to content

Commit

Permalink
refact: replace outdated constants
Browse files Browse the repository at this point in the history
  • Loading branch information
o4kapuk committed Nov 25, 2019
1 parent b2f5ab7 commit 5c16bcd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion api/source/Creep.md
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ ERR_INVALID_ARGS | <code>enable</code> argument is not a boolean value.
{% api_method pickup 'target' A %}

```javascript
const target = creep.pos.findClosestByRange(FIND_DROPPED_ENERGY);
const target = creep.pos.findClosestByRange(FIND_DROPPED_RESOURCES);
if(target) {
if(creep.pickup(target) == ERR_NOT_IN_RANGE) {
creep.moveTo(target);
Expand Down
2 changes: 1 addition & 1 deletion api/source/PowerCreep.md
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ ERR_INVALID_ARGS | <code>enable</code> argument is not a boolean value.
{% api_method pickup 'target' A %}

```javascript
const target = creep.pos.findClosestByRange(FIND_DROPPED_ENERGY);
const target = creep.pos.findClosestByRange(FIND_DROPPED_RESOURCES);
if(target) {
if(creep.pickup(target) == ERR_NOT_IN_RANGE) {
creep.moveTo(target);
Expand Down

0 comments on commit 5c16bcd

Please sign in to comment.