Skip to content

Commit f99c87a

Browse files
committed
rename structure
1 parent fe3621a commit f99c87a

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

src/actors/bullets/index.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class Bullets extends Phaser.Group {
1010
this.x = BULLETS.x
1111
this.y = BULLETS.y
1212

13-
this.stack = []
13+
this.queue = []
1414
this.updateTime = 0
1515

1616
this.fire = this.fire.bind(this)
@@ -25,16 +25,16 @@ class Bullets extends Phaser.Group {
2525
}
2626

2727
fire(column) {
28-
if (this.stack.includes(column)) {
28+
if (this.queue.includes(column)) {
2929
return
3030
}
3131

32-
this.stack.push(column)
32+
this.queue.push(column)
3333
}
3434

3535
remove(column) {
36-
const index = this.stack.indexOf(column)
37-
this.stack.splice(index, 1)
36+
const index = this.queue.indexOf(column)
37+
this.queue.splice(index, 1)
3838
}
3939

4040
render() {
@@ -44,7 +44,7 @@ class Bullets extends Phaser.Group {
4444
return
4545
}
4646

47-
this.stack.forEach(column => {
47+
this.queue.forEach(column => {
4848
this.children[column].render()
4949
})
5050

0 commit comments

Comments
 (0)