aboutsummaryrefslogtreecommitdiff
path: root/features/streamsGUI
diff options
context:
space:
mode:
Diffstat (limited to 'features/streamsGUI')
-rw-r--r--features/streamsGUI/index.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/features/streamsGUI/index.js b/features/streamsGUI/index.js
index d7d75cd..fec9bfa 100644
--- a/features/streamsGUI/index.js
+++ b/features/streamsGUI/index.js
@@ -73,10 +73,14 @@ class StreamPage extends GuiPage {
let stream = streams.twitch[channel]
if (i % 2 === 0) {
- this.streamsBox.addChild(new StreamElement().setStream(stream, true).setLocation(0, y, 0.45, 0.55).setStreamPage(this))
+ let element = new StreamElement().setLocation(0, y, 0.45, 0.55).setStreamPage(this)
+ this.streamsBox.addChild(element)
+ element.setStream(stream, true)
}
if (i % 2 === 1) {
- this.streamsBox.addChild(new StreamElement().setStream(stream, true).setLocation(0.55, y, 0.45, 0.55).setStreamPage(this))
+ let element = new StreamElement().setLocation(0.55, y, 0.45, 0.55).setStreamPage(this)
+ this.streamsBox.addChild(element)
+ element.setStream(stream, true)
y += 0.6
}
})