Skip to content

Commit 1893762

Browse files
Remove useless array
1 parent b0cd099 commit 1893762

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

src/Entity/Boss/Summoner.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,6 @@ const SUMMONER_SIZE = 150;
5858
* Class which represents the boss "Summoner"
5959
*/
6060
export default class Summoner extends AbstractBoss {
61-
62-
/** Summoner spawners */
63-
private spawners: Barrel[] = [];
64-
6561
public constructor(game: GameServer) {
6662
super(game);
6763

@@ -71,8 +67,9 @@ export default class Summoner extends AbstractBoss {
7167
this.physicsData.values.size = SUMMONER_SIZE * Math.SQRT1_2;
7268
this.physicsData.values.sides = 4;
7369

74-
for (let i = 0; i < 4; ++i) {
75-
this.spawners.push(new Barrel(this, {
70+
const count = this.physicsData.values.sides;
71+
for (let i = 0; i < count; ++i) {
72+
this.barrels.push(new Barrel(this, {
7673
...SummonerSpawnerDefinition,
7774
angle: PI2 * ((i / 4))
7875
}));

0 commit comments

Comments
 (0)