screeps/bodypartbuilder.js

4 lines
168 B
JavaScript
Raw Normal View History

2016-09-15 00:30:24 -05:00
bodyParts.forEach(function (bodyPart) {
var part = typeof bodyPart === 'string' ? bodyPart : bodyPart.type;
cost += BODYPART_COST[part];
});