diff options
-rw-r--r-- | features/cosmetics/cosmetic/dragon/dragonWings.js (renamed from features/cosmetics/dragonWings.js) | 13 | ||||
-rw-r--r-- | features/cosmetics/index.js | 8 | ||||
-rw-r--r-- | features/cosmetics/textures/dragon/classic.png (renamed from features/cosmetics/textures/Enderdragon_png.png) | bin | 11845 -> 11845 bytes | |||
-rw-r--r-- | features/cosmetics/textures/dragon/purple.png | bin | 0 -> 19740 bytes |
4 files changed, 16 insertions, 5 deletions
diff --git a/features/cosmetics/dragonWings.js b/features/cosmetics/cosmetic/dragon/dragonWings.js index d62178b..8638b93 100644 --- a/features/cosmetics/dragonWings.js +++ b/features/cosmetics/cosmetic/dragon/dragonWings.js @@ -1,4 +1,4 @@ -import Cosmetic from "./cosmetic"; +import Cosmetic from "../../cosmetic.js"; const ModelDragon = Java.type("net.minecraft.client.model.ModelDragon") @@ -8,7 +8,10 @@ const EssentialCosmeticSlot = Java.type("gg.essential.cosmetics.CosmeticSlot") 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 -let textures = new Image(javax.imageio.ImageIO.read(new java.io.File("./config/ChatTriggers/modules/SoopyV2/features/cosmetics/textures/Enderdragon_png.png"))) +let textures = { + classic: new Image(javax.imageio.ImageIO.read(new java.io.File("./config/ChatTriggers/modules/SoopyV2/features/cosmetics/textures/dragon/classic.png"))), + purple: new Image(javax.imageio.ImageIO.read(new java.io.File("./config/ChatTriggers/modules/SoopyV2/features/cosmetics/textures/dragon/purple.png"))) +} let wing = getField(dragon, "field_78225_k") let wingTip = getField(dragon, "field_78222_l") const GL11 = Java.type("org.lwjgl.opengl.GL11"); @@ -116,7 +119,11 @@ class DragonWings extends Cosmetic { (this.player.getPlayer().field_70136_U + (this.player.getPlayer().field_70161_v-this.player.getPlayer().field_70136_U) * ticks) - (Player.getPlayer().field_70136_U + (Player.getPlayer().field_70161_v-Player.getPlayer().field_70136_U) * ticks)) } - Tessellator.bindTexture(textures) //bind texture + if(textures[this.settings.texture || "classic"]){ + Tessellator.bindTexture(textures[this.settings.texture || "classic"]) //bind texture + }else{ + Tessellator.bindTexture(textures.classic) //bind texture + } if(this.player.getPlayer().field_70154_o){ rotation = this.player.getPlayer().field_70759_as+(this.player.getPlayer().field_70759_as-this.player.getPlayer().field_70758_at)*ticks diff --git a/features/cosmetics/index.js b/features/cosmetics/index.js index 20477ce..d519351 100644 --- a/features/cosmetics/index.js +++ b/features/cosmetics/index.js @@ -1,7 +1,7 @@ /// <reference types="../../../CTAutocomplete" /> /// <reference lib="es2015" /> import Feature from "../../featureClass/class"; -import DragonWings from "./dragonWings" +import DragonWings from "./cosmetic/dragon/dragonWings" import Toggle from "../settings/settingThings/toggle" const Essential = Java.type("gg.essential.Essential") const EssentialCosmeticSlot = Java.type("gg.essential.cosmetics.CosmeticSlot") @@ -129,7 +129,11 @@ class Cosmetics extends Feature { } shouldPlayerHaveCosmetic(player, cosmetic){ - return !!this.cosmeticsData[player.getUUID().toString().replace(/-/g,"")]?.[cosmetic] + if(!!this.cosmeticsData[player.getUUID().toString().replace(/-/g,"")]?.[cosmetic]){ + if(!this.getPlayerCosmeticSettings(player, cosmetic).enabled) return false + return true + } + return false } getPlayerCosmeticSettings(player, cosmetic){ return this.cosmeticsData[player.getUUID().toString().replace(/-/g,"")]?.[cosmetic] diff --git a/features/cosmetics/textures/Enderdragon_png.png b/features/cosmetics/textures/dragon/classic.png Binary files differindex aad6401..aad6401 100644 --- a/features/cosmetics/textures/Enderdragon_png.png +++ b/features/cosmetics/textures/dragon/classic.png diff --git a/features/cosmetics/textures/dragon/purple.png b/features/cosmetics/textures/dragon/purple.png Binary files differnew file mode 100644 index 0000000..5f35a58 --- /dev/null +++ b/features/cosmetics/textures/dragon/purple.png |