* Queues up the background objects * @param {Shot[]} shots
(shots)
| 84 | * @param {Shot[]} shots |
| 85 | */ |
| 86 | loadBackgroundObjects (shots) { |
| 87 | shots |
| 88 | .filter(shot => (shot.dialogNodes || []).length > 0) |
| 89 | .forEach(({ dialogNodes }) => |
| 90 | dialogNodes |
| 91 | .map(dialogNode => getBackgroundObject(dialogNode)) |
| 92 | .filter(bgObject => bgObject) |
| 93 | .map(({ type: { slug } }) => slug) |
| 94 | .filter(slug => slug) |
| 95 | .forEach(slug => this.queueThangType(slug)) |
| 96 | ) |
| 97 | } |
| 98 | |
| 99 | /** |
| 100 | * Iterate through the shotSetups and start loading the required thangTypes. |
no test coverage detected