aboutsummaryrefslogtreecommitdiff
path: root/features/globalSettings/firstLoadPages.js
diff options
context:
space:
mode:
authorSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2021-11-07 19:24:47 +0800
committerSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2021-11-07 19:24:47 +0800
commite44de4dc2876d771d871255e72c6884b958c05eb (patch)
tree26bbc40b5a94072f1bd73c4bd472687e1cd62ef5 /features/globalSettings/firstLoadPages.js
parentfb19a8b072e8529b9d90bd3fb322da31ca4911df (diff)
downloadSoopyV2-e44de4dc2876d771d871255e72c6884b958c05eb.tar.gz
SoopyV2-e44de4dc2876d771d871255e72c6884b958c05eb.tar.bz2
SoopyV2-e44de4dc2876d771d871255e72c6884b958c05eb.zip
add apikey menu to first load
Diffstat (limited to 'features/globalSettings/firstLoadPages.js')
-rw-r--r--features/globalSettings/firstLoadPages.js32
1 files changed, 31 insertions, 1 deletions
diff --git a/features/globalSettings/firstLoadPages.js b/features/globalSettings/firstLoadPages.js
index c7a90f0..e395afe 100644
--- a/features/globalSettings/firstLoadPages.js
+++ b/features/globalSettings/firstLoadPages.js
@@ -13,6 +13,7 @@ class WelcomePage extends FirstLoadPage{
this.addChild(new SoopyTextElement().setText("§7First lets get privacy settings out of the way.").setLocation(0.1, 0.15,0.8,0.075).setMaxTextScale(10));
this.settingsArea = new SoopyGuiElement().setLocation(0.1, 0.25,0.8,0.75);
+ this.settingsArea.setScrollable(true)
this.addChild(this.settingsArea);
}
@@ -31,6 +32,35 @@ class WelcomePage extends FirstLoadPage{
})
}
}
+class ApiKeyPage extends FirstLoadPage{
+ constructor(){
+ super()
+
+ this.addChild(new SoopyTextElement().setText("§0Next lets setup your api key!").setLocation(0.1, 0.05,0.8,0.1).setMaxTextScale(10));
+
+ this.addChild(new SoopyTextElement().setText("§7You can skip this but some features may not work").setLocation(0.1, 0.15,0.8,0.075).setMaxTextScale(10));
+
+ this.settingsArea = new SoopyGuiElement().setLocation(0.1, 0.25,0.8,0.75);
+ this.settingsArea.setScrollable(true)
+
+ this.addChild(this.settingsArea);
+ }
+
+ load(){
+ let y = 0
+
+ let settings = [this.guiPage.mainThing.apiKeySetting, this.guiPage.mainThing.verifyApiKey, this.guiPage.mainThing.findApiKey, this.guiPage.mainThing.newApiKey]
+ settings.forEach(setting => {
+ setting = setting.getGuiObject()
+
+ setting.location.location.y.set(y, 0)
+
+ this.settingsArea.addChild(setting);
+
+ y += 0.045+setting.location.size.y.get()
+ })
+ }
+}
class HowToOpenMenuPage extends FirstLoadPage{
constructor(){
@@ -59,4 +89,4 @@ class HowToOpenMenuPage extends FirstLoadPage{
}
}
-export default [new WelcomePage(), new HowToOpenMenuPage()] \ No newline at end of file
+export default [new WelcomePage(), new ApiKeyPage(), new HowToOpenMenuPage()] \ No newline at end of file