Creep body setup strategies

From Screeps Wiki
Revision as of 13:02, 2 March 2021 by Gadjung (talk | contribs) (Basic strategy for designing Creep Body)
Jump to navigation Jump to search

Creep Design Strategies

There are multiple ways how to create Your desired creep with desired bodyparts, 2 most common would be:

  • predefined
  • template repetition

Predefined Body

It can be implemented in multiple ways, though it boils down to always return earlier-designed array of bodyparts.

To avoid blocking Spawn with creep that has body with too high energy cost it's worth to explore creating several predefined sets of body arrays depending on room.energyCapacity or room.energyCapacityAvailable.

Template Repetition Body

Template body design bases on a predefined subset of bodyparts, that have calculated energy cost, and repeating them either body matches required bodypart count, or energy limit.

i.e we want a mineral worker creep that has as many WORK parts as possible and half of WORK parts amount of MOVE

thus we arrive at [WORK,WORK,MOVE] template.

Next calculate the energy cost of this template.

With this two information we can create an array, into which, inside a while/for loop, we will push above template IF cost of all added bodyparts is below or equal room.energyCapacity or room.energyCapacityAvailable..

One needs to be careful not to exceed the MAX_CREEP_SIZE limit.

Both methods can be combined, with predefined starting template and additional bodyparts added from another template.

MOVE parts

Using the right number of MOVE parts is important. If you use too many, your creep will be more expensive than necessary. If you use too few, the creep will move very slowly.

If you have roads, you don't need as many MOVE parts. Roads speed creep movement by a factor of 2, meaning only half as many MOVE parts are required. Roads are especially important in swamps, which are 5 times slower than plain land and 10 times slower than roads. However, the roads must be maintained, so a few players decide not to keep up roads.

CARRY parts

CARRY parts do not generate fatigue if they are empty. Boosted CARRY parts do not generate extra fatigue, so boosted transport creeps require much fewer MOVE parts for the amount they can carry.


The order of the creep's body parts makes a difference: The ones listed first take damage first. For this reason, TOUGH parts should almost always appear at the beginning of the creep's parts list. HEAL parts should usually be near the end, so that if the creep is nearly destroyed, it may have a chance to heal itself.