aboutsummaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
Diffstat (limited to 'features')
-rw-r--r--features/changeLogGUI/index.js2
-rw-r--r--features/cosmetics/cosmetic/dragon/dragonWings.js43
-rw-r--r--features/cosmetics/index.js11
-rw-r--r--features/dungeonSolvers/index.js2
4 files changed, 44 insertions, 14 deletions
diff --git a/features/changeLogGUI/index.js b/features/changeLogGUI/index.js
index 4d392bd..55a9e83 100644
--- a/features/changeLogGUI/index.js
+++ b/features/changeLogGUI/index.js
@@ -16,7 +16,7 @@ const File = Java.type("java.io.File")
const URL = Java.type("java.net.URL");
const PrintStream = Java.type("java.io.PrintStream");
const Byte = Java.type("java.lang.Byte");
-
+//global.soopyv2featuremanagerthing.features.changeLogGUI.class.ChangelogPage.downloadUpdate()
class ChangeLogGui extends Feature {
constructor() {
super()
diff --git a/features/cosmetics/cosmetic/dragon/dragonWings.js b/features/cosmetics/cosmetic/dragon/dragonWings.js
index a309e58..3f98ce3 100644
--- a/features/cosmetics/cosmetic/dragon/dragonWings.js
+++ b/features/cosmetics/cosmetic/dragon/dragonWings.js
@@ -10,7 +10,8 @@ if (!GlStateManager) {
var GlStateManager = Java.type("net.minecraft.client.renderer.GlStateManager");
}
const Essential = Java.type("gg.essential.Essential")
-const EssentialCosmeticSlot = Java.type("gg.essential.cosmetics.CosmeticSlot")
+const EssentialCosmeticSlot = Java.type("gg.essential.mod.cosmetics.CosmeticSlot")
+const EssentialBone = Java.type("gg.essential.model.Bone")
const FACING = Java.type("net.minecraft.block.BlockDirectional").field_176387_N
let dragon = new ModelDragon(0) //too lazy to make my own model so i just yoink it from modelDragon lmfao
@@ -367,23 +368,34 @@ class DragonWings extends Cosmetic {
}
removeEssentialCosmetics() {
- if (!this.player.getPlayer() || !this.player.getPlayer().getEssentialCosmetics || !this.player.getPlayer().getEssentialCosmetics()) return
-
- let wingCosmetic = this.player.getPlayer().getEssentialCosmetics().get(EssentialCosmeticSlot.WINGS)
+ if (!this.player.getPlayer() || !this.player.getPlayer().getCosmeticsState || !this.player.getPlayer().getCosmeticsState() || !this.player.getPlayer().getCosmeticsState().getCosmetics || !this.player.getPlayer().getCosmeticsState().getCosmetics()) return
+ //player.()
+ let wingCosmetic = this.player.getPlayer().getCosmeticsState().getCosmetics().get(EssentialCosmeticSlot.WINGS)
if (wingCosmetic !== null) {
- if (this.player.getPlayer().getEssentialCosmeticModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(wingCosmetic))) {
- this.player.getPlayer().getEssentialCosmeticModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(wingCosmetic)).getModel().getModel().boneList.forEach(b => {
- b.isHidden = true
+ let cosmetic = this.player.getPlayer().getCosmeticsState().getModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(wingCosmetic))
+ if (cosmetic) {
+ let model = cosmetic.getModel().getModel()
+
+ let bones = model.getBones(model.getRootBone())
+
+ bones.forEach(b => {
+ setField(b, "showModel", false)
+
this.parent.hiddenEssentialCosmetics.push(b)
})
}
} else {
- let fullBodyCosmetic = this.player.getPlayer().getEssentialCosmetics().get(EssentialCosmeticSlot.FULL_BODY)
+ let fullBodyCosmetic = this.player.getPlayer().getCosmeticsState().getCosmetics().get(EssentialCosmeticSlot.FULL_BODY)
if (fullBodyCosmetic === "DRAGON_ONESIE_2") {
- if (this.player.getPlayer().getEssentialCosmeticModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(fullBodyCosmetic))) {
- this.player.getPlayer().getEssentialCosmeticModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(fullBodyCosmetic)).getModel().getModel().boneList.forEach(b => {
+ let cosmetic = this.player.getPlayer().getCosmeticsState().getModels().get(Essential.instance.getConnectionManager().getCosmeticsManager().getCosmetic(fullBodyCosmetic))
+ if (cosmetic) {
+ let model = cosmetic.getModel().getModel()
+
+ let bones = model.getBones(model.getRootBone())
+
+ bones.forEach(b => {
if (b.boxName === "wing_left_1" || b.boxName === "wing_right_1") {
- b.isHidden = true
+ setField(b, "showModel", false)
this.parent.hiddenEssentialCosmetics.push(b)
}
@@ -453,6 +465,15 @@ function getField(e, field) {
return field2.get(e)
}
+function setField(e, field, value) {
+
+ let field2 = e.class.getDeclaredField(field);
+
+ field2.setAccessible(true)
+
+ return field2.set(e, value)
+}
+
let a = 0
register("command", (val) => {
diff --git a/features/cosmetics/index.js b/features/cosmetics/index.js
index dcac5e9..7c09bce 100644
--- a/features/cosmetics/index.js
+++ b/features/cosmetics/index.js
@@ -226,7 +226,7 @@ class Cosmetics extends Feature {
restoreEssentialCosmetics() {
this.hiddenEssentialCosmetics.forEach(cosmetic => {
- cosmetic.isHidden = false
+ setField(cosmetic, "showModel", true)
})
this.hiddenEssentialCosmetics = []
}
@@ -259,4 +259,13 @@ let instance = new Cosmetics()
module.exports = {
class: instance
+}
+
+function setField(e, field, value) {
+
+ let field2 = e.class.getDeclaredField(field);
+
+ field2.setAccessible(true)
+
+ return field2.set(e, value)
} \ No newline at end of file
diff --git a/features/dungeonSolvers/index.js b/features/dungeonSolvers/index.js
index a724891..60d4b16 100644
--- a/features/dungeonSolvers/index.js
+++ b/features/dungeonSolvers/index.js
@@ -399,7 +399,7 @@ class DungeonSolvers extends Feature {
}
timerThing(position) {
- this.timersData.push([position, Date.now() + 5000])
+ this.timersData.push([position, Date.now() + 5000]) //TODO: 1.5s less on m6
}
areaUpdated() {