mirror of
https://github.com/refactorinqq/SLC-1.8.9.git
synced 2024-11-10 06:31:32 +01:00
(improve) 3d skins settings
This commit is contained in:
parent
0a30dec288
commit
8f28b8fe45
@ -55,12 +55,12 @@ public abstract class PlayerRendererMixin extends RendererLivingEntity<AbstractC
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(Minecraft.getMinecraft().thePlayer.getPositionVector().squareDistanceTo(abstractClientPlayer.getPositionVector()) < Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()*Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()) {
|
if(Minecraft.getMinecraft().thePlayer.getPositionVector().squareDistanceTo(abstractClientPlayer.getPositionVector()) < Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()*Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()) {
|
||||||
playerModel.bipedHeadwear.isHidden = playerModel.bipedHeadwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Hat").getValBoolean();
|
playerModel.bipedHeadwear.isHidden = playerModel.bipedHeadwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Head").getValBoolean();
|
||||||
playerModel.bipedBodyWear.isHidden = playerModel.bipedBodyWear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Jacket").getValBoolean();
|
playerModel.bipedBodyWear.isHidden = playerModel.bipedBodyWear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Body").getValBoolean();
|
||||||
playerModel.bipedLeftArmwear.isHidden = playerModel.bipedLeftArmwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Left Sleeve").getValBoolean();
|
playerModel.bipedLeftArmwear.isHidden = playerModel.bipedLeftArmwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Left Arm").getValBoolean();
|
||||||
playerModel.bipedRightArmwear.isHidden = playerModel.bipedRightArmwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Right Sleeve").getValBoolean();
|
playerModel.bipedRightArmwear.isHidden = playerModel.bipedRightArmwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Right Arm").getValBoolean();
|
||||||
playerModel.bipedLeftLegwear.isHidden = playerModel.bipedLeftLegwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Left Pants").getValBoolean();
|
playerModel.bipedLeftLegwear.isHidden = playerModel.bipedLeftLegwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Left Leg").getValBoolean();
|
||||||
playerModel.bipedRightLegwear.isHidden = playerModel.bipedRightLegwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Right Pants").getValBoolean();
|
playerModel.bipedRightLegwear.isHidden = playerModel.bipedRightLegwear.isHidden || Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Right Leg").getValBoolean();
|
||||||
} else {
|
} else {
|
||||||
// not correct, but the correct way doesn't work cause 1.8 or whatever
|
// not correct, but the correct way doesn't work cause 1.8 or whatever
|
||||||
if(!abstractClientPlayer.isSpectator()) {
|
if(!abstractClientPlayer.isSpectator()) {
|
||||||
|
@ -12,23 +12,19 @@ public class SkinsMod extends Mod {
|
|||||||
public void setup() {
|
public void setup() {
|
||||||
super.setup();
|
super.setup();
|
||||||
setNewMod(true);
|
setNewMod(true);
|
||||||
this.addBooleanSetting("3D Hat", this, true);
|
|
||||||
this.addBooleanSetting("3D Jacket", this, true);
|
this.addBooleanSetting("Fast Render", this, true);
|
||||||
this.addBooleanSetting("3D Left Sleeve", this, true);
|
this.addSliderSetting("Level Of Detail Distance", this, 14, 5, 40, true);
|
||||||
this.addBooleanSetting("3D Right Sleeve", this, true);
|
|
||||||
this.addBooleanSetting("3D Left Pants", this, true);
|
this.addBooleanSetting("Head", this, true);
|
||||||
this.addBooleanSetting("3D Right Pants", this, true);
|
this.addBooleanSetting("Body", this, true);
|
||||||
|
this.addBooleanSetting("Left Arm", this, true);
|
||||||
|
this.addBooleanSetting("Right Arm", this, true);
|
||||||
|
this.addBooleanSetting("Left Leg", this, true);
|
||||||
|
this.addBooleanSetting("Right Leg", this, true);
|
||||||
|
|
||||||
this.addSliderSetting("Voxel Size", this, 1.15F, 1F, 1.4F, false);
|
this.addSliderSetting("Voxel Size", this, 1.15F, 1F, 1.4F, false);
|
||||||
this.addSliderSetting("Head Voxel Size", this, 1.18F, 1F, 1.25F, false);
|
this.addSliderSetting("Head Voxel Size", this, 1.18F, 1F, 1.25F, false);
|
||||||
this.addSliderSetting("Body Voxel Width Size", this, 1.05F, 1F, 1.4F, false);
|
this.addSliderSetting("Body Voxel Width Size", this, 1.05F, 1F, 1.4F, false);
|
||||||
|
|
||||||
this.addBooleanSetting("3D Skulls", this, true);
|
|
||||||
this.addBooleanSetting("3D Skull Items", this, true);
|
|
||||||
this.addSliderSetting("Skull Voxel Size", this, 1.1F, 1F, 1.2F, false);
|
|
||||||
|
|
||||||
this.addSliderSetting("Level Of Detail Distance", this, 14, 5, 40, true);
|
|
||||||
|
|
||||||
this.addBooleanSetting("Fast Render", this, true);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -29,11 +29,11 @@ public class BodyLayerFeatureRenderer
|
|||||||
RenderPlayer playerRenderer) {
|
RenderPlayer playerRenderer) {
|
||||||
this.playerRenderer = playerRenderer;
|
this.playerRenderer = playerRenderer;
|
||||||
thinArms = ((PlayerEntityModelAccessor)playerRenderer).client$hasThinArms();
|
thinArms = ((PlayerEntityModelAccessor)playerRenderer).client$hasThinArms();
|
||||||
bodyLayers.add(new Layer(0, false, EnumPlayerModelParts.LEFT_PANTS_LEG, Shape.LEGS, () -> playerRenderer.getMainModel().bipedLeftLeg, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Left Pants").getValBoolean()));
|
bodyLayers.add(new Layer(0, false, EnumPlayerModelParts.LEFT_PANTS_LEG, Shape.LEGS, () -> playerRenderer.getMainModel().bipedLeftLeg, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Left Leg").getValBoolean()));
|
||||||
bodyLayers.add(new Layer(1, false, EnumPlayerModelParts.RIGHT_PANTS_LEG, Shape.LEGS, () -> playerRenderer.getMainModel().bipedRightLeg, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Right Pants").getValBoolean()));
|
bodyLayers.add(new Layer(1, false, EnumPlayerModelParts.RIGHT_PANTS_LEG, Shape.LEGS, () -> playerRenderer.getMainModel().bipedRightLeg, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Right Leg").getValBoolean()));
|
||||||
bodyLayers.add(new Layer(2, false, EnumPlayerModelParts.LEFT_SLEEVE, thinArms ? Shape.ARMS_SLIM : Shape.ARMS, () -> playerRenderer.getMainModel().bipedLeftArm, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Left Sleeve").getValBoolean()));
|
bodyLayers.add(new Layer(2, false, EnumPlayerModelParts.LEFT_SLEEVE, thinArms ? Shape.ARMS_SLIM : Shape.ARMS, () -> playerRenderer.getMainModel().bipedLeftArm, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Left Arm").getValBoolean()));
|
||||||
bodyLayers.add(new Layer(3, true, EnumPlayerModelParts.RIGHT_SLEEVE, thinArms ? Shape.ARMS_SLIM : Shape.ARMS, () -> playerRenderer.getMainModel().bipedRightArm, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Right Sleeve").getValBoolean()));
|
bodyLayers.add(new Layer(3, true, EnumPlayerModelParts.RIGHT_SLEEVE, thinArms ? Shape.ARMS_SLIM : Shape.ARMS, () -> playerRenderer.getMainModel().bipedRightArm, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Right Arm").getValBoolean()));
|
||||||
bodyLayers.add(new Layer(4, false, EnumPlayerModelParts.JACKET, Shape.BODY, () -> playerRenderer.getMainModel().bipedBody, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Jacket").getValBoolean()));
|
bodyLayers.add(new Layer(4, false, EnumPlayerModelParts.JACKET, Shape.BODY, () -> playerRenderer.getMainModel().bipedBody, () -> Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Body").getValBoolean()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -32,7 +32,7 @@ public class HeadLayerFeatureRenderer implements LayerRenderer<AbstractClientPla
|
|||||||
@Override
|
@Override
|
||||||
public void doRenderLayer(AbstractClientPlayer player, float paramFloat1, float paramFloat2, float paramFloat3,
|
public void doRenderLayer(AbstractClientPlayer player, float paramFloat1, float paramFloat2, float paramFloat3,
|
||||||
float deltaTick, float paramFloat5, float paramFloat6, float paramFloat7) {
|
float deltaTick, float paramFloat5, float paramFloat6, float paramFloat7) {
|
||||||
if (!player.hasSkin() || player.isInvisible() || !Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "3D Hat").getValBoolean()) {
|
if (!player.hasSkin() || player.isInvisible() || !Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Head").getValBoolean()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(mc.thePlayer.getPositionVector().squareDistanceTo(player.getPositionVector()) > Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()*Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt())return;
|
if(mc.thePlayer.getPositionVector().squareDistanceTo(player.getPositionVector()) > Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt()*Client.getInstance().getSettingsManager().getSettingByClass(SkinsMod.class, "Level Of Detail Distance").getValInt())return;
|
||||||
|
Loading…
Reference in New Issue
Block a user