use of meteordevelopment.meteorclient.utils.render.color.SettingColor in project meteor-client by MeteorDevelopment.
the class SBlockDataScreen method initWidgets.
@Override
public void initWidgets() {
Settings settings = new Settings();
SettingGroup sgGeneral = settings.getDefaultGroup();
SettingGroup sgTracer = settings.createGroup("Tracer");
sgGeneral.add(new EnumSetting.Builder<ShapeMode>().name("shape-mode").description("How the shape is rendered.").defaultValue(ShapeMode.Lines).onModuleActivated(shapeModeSetting -> shapeModeSetting.set(blockData.shapeMode)).onChanged(shapeMode -> {
blockData.shapeMode = shapeMode;
changed(blockData, block, setting);
}).build());
sgGeneral.add(new ColorSetting.Builder().name("line-color").description("Color of lines.").defaultValue(new SettingColor(0, 255, 200)).onModuleActivated(settingColorSetting -> settingColorSetting.set(blockData.lineColor)).onChanged(settingColor -> {
blockData.lineColor.set(settingColor);
changed(blockData, block, setting);
}).build());
sgGeneral.add(new ColorSetting.Builder().name("side-color").description("Color of sides.").defaultValue(new SettingColor(0, 255, 200, 25)).onModuleActivated(settingColorSetting -> settingColorSetting.set(blockData.sideColor)).onChanged(settingColor -> {
blockData.sideColor.set(settingColor);
changed(blockData, block, setting);
}).build());
sgTracer.add(new BoolSetting.Builder().name("tracer").description("If tracer line is allowed to this block.").defaultValue(true).onModuleActivated(booleanSetting -> booleanSetting.set(blockData.tracer)).onChanged(aBoolean -> {
blockData.tracer = aBoolean;
changed(blockData, block, setting);
}).build());
sgTracer.add(new ColorSetting.Builder().name("tracer-color").description("Color of tracer line.").defaultValue(new SettingColor(0, 255, 200, 125)).onModuleActivated(settingColorSetting -> settingColorSetting.set(blockData.tracerColor)).onChanged(settingColor -> {
blockData.tracerColor = settingColor;
changed(blockData, block, setting);
}).build());
settings.onActivated();
add(theme.settings(settings)).expandX();
}
use of meteordevelopment.meteorclient.utils.render.color.SettingColor in project meteor-rejects by AntiCope.
the class Lavacast method onRender.
@EventHandler
private void onRender(Render3DEvent event) {
if (placeFluidPos == null)
return;
double x1 = placeFluidPos.getX();
double y1 = placeFluidPos.getY();
double z1 = placeFluidPos.getZ();
double x2 = x1 + 1;
double y2 = y1 + 1;
double z2 = z1 + 1;
SettingColor color = new SettingColor(128, 128, 128);
if (stage == Stage.LavaDown)
color = new SettingColor(255, 180, 10);
if (stage == Stage.LavaUp)
color = new SettingColor(255, 180, 128);
if (stage == Stage.WaterDown)
color = new SettingColor(10, 10, 255);
if (stage == Stage.WaterUp)
color = new SettingColor(128, 128, 255);
SettingColor color1 = color;
color1.a = 75;
event.renderer.box(x1, y1, z1, x2, y2, z2, color1, color, ShapeMode.Both, 0);
}
Aggregations