This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 'use strict'; | |
| Object.defineProperty(exports, "__esModule", { | |
| value: true | |
| }); | |
| exports.default = configureStore; | |
| var _redux = require('redux'); | |
| function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const chooseSpawn = (roleCount) => { | |
| const priorityQueue = [ | |
| 'harvester', | |
| 'miner', | |
| 'transporter', | |
| ] | |
| let nextSpawn | |
| _.reduce(priorityQueue, (expectedRoleCount, role) => { | |
| if (!expectedRoleCount[role]) expectedRoleCount[role] = 0 | |
| expectedRoleCount[role] += 1 |
OlderNewer