From a7dcf231cc43c9ef73d6a969203c2dafd2ce8caf Mon Sep 17 00:00:00 2001
From: Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com>
Date: Sun, 22 May 2022 12:35:39 +0800
Subject: changes
---
features/bestiary/index.js | 37 +++++++++++++++++++++++++++++
features/bestiary/metadata.json | 8 +++++++
features/eventsGUI/index.js | 51 ++++++++++++++++++++++++++++++++++++++++
features/eventsGUI/metadata.json | 8 +++++++
features/globalSettings/index.js | 4 ++++
features/performance/index.js | 50 +++++++++++++++++++--------------------
socketConnection.js | 28 +++++++++++++++++++---
utils/networkUtils.js | 1 +
8 files changed, 159 insertions(+), 28 deletions(-)
create mode 100644 features/bestiary/index.js
create mode 100644 features/bestiary/metadata.json
create mode 100644 features/eventsGUI/index.js
create mode 100644 features/eventsGUI/metadata.json
diff --git a/features/bestiary/index.js b/features/bestiary/index.js
new file mode 100644
index 0000000..3888ffb
--- /dev/null
+++ b/features/bestiary/index.js
@@ -0,0 +1,37 @@
+///
+///
+import { m } from "../../../mappings/mappings";
+import Feature from "../../featureClass/class";
+import { drawCoolWaypoint } from "../../utils/renderUtils";
+import SettingBase from "../settings/settingThings/settingBase";
+import ToggleSetting from "../settings/settingThings/toggle";
+
+
+class Waypoints extends Feature {
+ constructor() {
+ super()
+ }
+
+ onEnable() {
+ this.initVariables()
+
+ this.bestiaryData = JSON.parse(FileLib.read("soopyAddonsData", "bestiaryData.json") || "{}")
+ this.bestiaryChanged = false
+ }
+
+ initVariables() {
+
+ }
+
+ onDisable() {
+ if (this.bestiaryChanged) {
+ FileLib.write("soopyAddonsData", "bestiaryData.json", JSON.stringify(this.bestiaryData))
+ }
+
+ this.initVariables()
+ }
+}
+
+module.exports = {
+ class: new Waypoints()
+}
diff --git a/features/bestiary/metadata.json b/features/bestiary/metadata.json
new file mode 100644
index 0000000..3ff9383
--- /dev/null
+++ b/features/bestiary/metadata.json
@@ -0,0 +1,8 @@
+{
+ "name": "Bestiary",
+ "description": "Bestiary trackers",
+ "isHidden": false,
+ "isTogglable": true,
+ "defaultEnabled": true,
+ "sortA": 0
+}
\ No newline at end of file
diff --git a/features/eventsGUI/index.js b/features/eventsGUI/index.js
new file mode 100644
index 0000000..c828f85
--- /dev/null
+++ b/features/eventsGUI/index.js
@@ -0,0 +1,51 @@
+///
+///
+import BoxWithLoading from "../../../guimanager/GuiElement/BoxWithLoading";
+import Feature from "../../featureClass/class";
+import GuiPage from "../soopyGui/GuiPage";
+
+class EventsGui extends Feature {
+ constructor() {
+ super()
+ }
+
+ onEnable() {
+ this.initVariables()
+
+ // this.GuiPage = new EventsPage() //TODO: SOON(tm)
+
+ // this.registerChat("&9&m-----------------------------------------------------&r&9${*}&r&9 ${*} &6Friends (Page ${pagenum} of ${maxpages})${friendslist}&r&9&m-----------------------------------------------------&r", (...args) => { this.GuiPage.friendListMessageEvent.call(this.GuiPage, ...args) })
+ // this.registerStep(true, 5, () => { this.GuiPage.regenGuiElements.call(this.GuiPage) })
+ }
+
+ initVariables() {
+ this.GuiPage = undefined
+ }
+
+ onDisable() {
+ this.initVariables()
+ }
+}
+
+
+class EventsPage extends GuiPage {
+ constructor() {
+ super(8)
+
+ this.name = "Guild Events"
+
+ this.pages = [this.newPage()]
+
+ this.pages[0].addChild(new BoxWithLoading().setLocation(0.3, 0.3, 0.4, 0.4))
+
+ this.finaliseLoading()
+ }
+
+ onOpen() {
+
+ }
+}
+
+module.exports = {
+ class: new EventsGui()
+}
\ No newline at end of file
diff --git a/features/eventsGUI/metadata.json b/features/eventsGUI/metadata.json
new file mode 100644
index 0000000..b7b1f6f
--- /dev/null
+++ b/features/eventsGUI/metadata.json
@@ -0,0 +1,8 @@
+{
+ "name": "Friends gui",
+ "description": "Gui for friends",
+ "isHidden": true,
+ "isTogglable": false,
+ "defaultEnabled": true,
+ "sortA": 0
+}
\ No newline at end of file
diff --git a/features/globalSettings/index.js b/features/globalSettings/index.js
index b77fd0e..39a2714 100644
--- a/features/globalSettings/index.js
+++ b/features/globalSettings/index.js
@@ -73,6 +73,10 @@ class GlobalSettings extends Feature {
this.registerEvent("tick", this.fixNEU)
}
+ if (net.minecraftforge.fml.common.Loader.isModLoaded("SoopyV2")) {
+
+ }
+
this.registerCommand("soopyweight", (user = Player.getName()) => {
this.soopyWeight(user)
})
diff --git a/features/performance/index.js b/features/performance/index.js
index a80240a..22a37fc 100644
--- a/features/performance/index.js
+++ b/features/performance/index.js
@@ -9,7 +9,7 @@ class Performance extends Feature {
super()
}
- onEnable(){
+ onEnable() {
return;
new SettingBase("NOTE: If you dont use any of the features, disable this", "Having performance enabled will decrease performance if no features are used\n(this is due to it using the render entity event)", true, "hide_performance_description", this)
@@ -46,17 +46,17 @@ class Performance extends Feature {
// }
// }
- renderWorld(){
- if(!this.armourStandCapSetting.getValue()) return
+ renderWorld() {
+ if (!this.armourStandCapSetting.getValue()) return
this.entitysRendering = {}
- Object.keys(this.entitysRenderingTemp).forEach(a=>{
+ Object.keys(this.entitysRenderingTemp).forEach(a => {
this.entitysRendering[a] = true
})
this.entitysRenderingTemp = {}
}
- updateDontRender(){
- if(!this.armourStandCapSetting.getValue()) return
+ updateDontRender() {
+ if (!this.armourStandCapSetting.getValue()) return
// this.removeHiddenEnts = this.removeHiddenEnts.filter(([uuid, time])=>{
// if(Date.now()