@FunctionRegister(
name = "GlowESP",
type = Category.Render
)
public class GlowESP extends Function {
@Subscribe
public void onUpdate(EventUpdate eventUpdate) {
for (Entity player : mc.world.getPlayers()) {
if (player != null) {
player.setGlowing(true);
setEntityGlowingColor(player, ColorUtils.getColor(0));
}
}
}
@Override
public boolean onEnable() {
for (Entity player : mc.world.getPlayers()) {
if (player != null) {
player.setGlowing(true);
setEntityGlowingColor(player, ColorUtils.getColor(0));
}
}
return false;
}
@Override
public void onDisable() {
for (Entity player : mc.world.getPlayers()) {
if (player != null) {
player.setGlowing(false);
}
}
}
private void setEntityGlowingColor(Entity entity, int color) {
entity.setGlowing(true);
}
}