public void Customize() { // This plugin shows you how to use the custom label plugin. // This plugin will be overwritten everytime you update the custom label plugin! // So use it as a guideline or tutorial to modify your own plugins with custom labels. // Custom labels: CustomLabelPlugin labels = Hud.GetPlugin <CustomLabelPlugin>(); // EASY WAY: // add a custom label at x=500, y=500 with the attributes width=100, heigth=20, text="*resource-pct-pri", hint="primary resource". // other attributes like background, opacity, textFont etc are set to default labels.add(500, 500, 100, 20, "*resource-pct-pri", "primary resource"); // CUSTOM WAY: // create a new custom label at x=500, y=520 with the attributes width=100, heigth=20, text="*hp-cur-pct", hint="current health". // NOTE: the label will not be shown yet, you didnt actually add it yet // set some custom attributes: CustomLabel healthLabel = new CustomLabel(500, 520, 100, 20, "*hp-cur-pct", "current health", Hud); healthLabel.BorderBrush = Hud.Render.CreateBrush(255, 180, 147, 109, -1); healthLabel.BackgroundBrush = Hud.Render.CreateBrush(50, 180, 147, 109, -1); healthLabel.TextFont = Hud.Render.CreateFont("Arial", 9, 150, 0, 0, 255, true, true, true); // add a default condition healthLabel.addCondition(new Conditions.notInTown()); // now add the label itself labels.add(healthLabel); // if you want to create and use your own conditions and expressions, implement them like shown above in the testCustomExpression() method and in the testCustomCondition class // you can add conditions right away in the constructor. alternatively set them like above with myLabel2.addCondition(new testCustomCondition()); // This will actually show your heroName if your CooldownReduction is greater than 15 CustomLabel resourceLabel = new CustomLabel(500, 540, 200, 20, "*custom-expression", "", Hud, new testCustomCondition()); resourceLabel.customExpression = testCustomExpression; labels.add(resourceLabel); //some more examples: labels.add(1225, 420, 100, 20, "Oculus", "", new Conditions.buffActive(402461, 2)); //draw label if oculus buff is active labels.add(500, 560, 100, 20, "*monsters-in-20", "monster in 20y"); //display number of monsters in 20y distance to player }
public void Customize() { // healing well label Hud.GetPlugin <ShrinePlugin>().HealingWellDecorator.Enabled = false; // ground circles for materials Hud.GetPlugin <ItemsPlugin>().NormalKeepDecorator.Enabled = false; Hud.GetPlugin <ItemsPlugin>().MagicKeepDecorator.Enabled = false; Hud.GetPlugin <ItemsPlugin>().RareKeepDecorator.Enabled = false; Hud.GetPlugin <BuffAppliedPopup>().Enabled = false; // turn on MultiplayerExperienceRangePlugin Hud.TogglePlugin <MultiplayerExperienceRangePlugin>(true); // turn off sell darkening Hud.GetPlugin <InventoryAndStashPlugin>().NotGoodDisplayEnabled = false; // Hud.GetPlugin<NearbyMonsterHealthAggregatorPlugin>().Enabled = false; Hud.TogglePlugin <MonsterDensityAroundCursor>(false); Hud.TogglePlugin <CustomLabelPlugin_Example>(false); Hud.GetPlugin <MonsterDensityAroundCursor>().DrawCursorLine = true; CustomLabelPlugin labels = Hud.GetPlugin <CustomLabelPlugin>(); CustomLabel resourceLabel = new CustomLabel(1225, 420, 100, 20, "*resource-pct-pri", "", Hud); resourceLabel.addCondition(new Conditions.notInTown()); resourceLabel.BorderBrush = Hud.Render.CreateBrush(0, 180, 147, 109, -1); resourceLabel.BackgroundBrush = resourceLabel.BorderBrush; resourceLabel.TextFont = Hud.Render.CreateFont("tahoma", 14, 255, 255, 255, 0, true, false, true); labels.add(resourceLabel); CustomLabel cursorPosLabel = new CustomLabel(580, 0, 100, 20, "*custom-expression", "Cursor Pos", Hud, new controlKeyPressedCondition()); cursorPosLabel.customExpression = cursorPosExpression; cursorPosLabel.BorderBrush = Hud.Render.CreateBrush(0, 180, 147, 109, -1); cursorPosLabel.BackgroundBrush = resourceLabel.BorderBrush; cursorPosLabel.TextFont = Hud.Render.CreateFont("tahoma", 6, 255, 255, 255, 255, false, false, true); labels.add(cursorPosLabel); CustomLabel oculusLabel = new CustomLabel(1225, 720, 100, 20, "Oculus", "", Hud, new Conditions.buffActive(402461, 2)); oculusLabel.TextFont = Hud.Render.CreateFont("tahoma", 13, 255, 0, 255, 0, true, false, true); oculusLabel.BorderBrush = Hud.Render.CreateBrush(0, 0, 0, 0, -1); oculusLabel.BackgroundBrush = oculusLabel.BorderBrush; labels.add(oculusLabel); CustomLabel archonLabel = new CustomLabel(1225, 460, 100, 20, "Archon ready!", "", Hud); archonLabel.addCondition(new Conditions.notOnCooldown(134872)); archonLabel.addCondition(new Conditions.buffNotActive(134872, 2)); archonLabel.addCondition(new Conditions.notInTown()); archonLabel.addCondition(new Conditions.isClass(HeroClass.Wizard)); archonLabel.TextFont = Hud.Render.CreateFont("tahoma", 12, 255, 255, 0, 69, true, false, true); archonLabel.BorderBrush = Hud.Render.CreateBrush(0, 0, 0, 0, -1); archonLabel.BackgroundBrush = archonLabel.BorderBrush; labels.add(archonLabel); var feetBuffs = Hud.GetPlugin <PlayerBottomBuffListPlugin>().RuleCalculator.Rules; feetBuffs.Add(new BuffRule(403471) { IconIndex = null, MinimumIconCount = 1, ShowStacks = true, ShowTimeLeft = true }); // Gem, Taeguk feetBuffs.Add(new BuffRule(383014) { IconIndex = null, MinimumIconCount = 1, ShowStacks = false, ShowTimeLeft = true }); // Gem, Bane of the Powerful feetBuffs.Add(new BuffRule(403464) { IconIndex = 1, MinimumIconCount = 1, ShowStacks = true, ShowTimeLeft = true }); // Gem, Gogok of Swiftness feetBuffs.Add(new BuffRule(263029) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Pylon, Conduit - Normal Rift feetBuffs.Add(new BuffRule(403404) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Pylon, Conduit - Greater Rift feetBuffs.Add(new BuffRule(262935) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Pylon, Power feetBuffs.Add(new BuffRule(266258) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Pylon, Channeling feetBuffs.Add(new BuffRule(266254) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Pylon, Shield feetBuffs.Add(new BuffRule(429673) { IconIndex = null, MinimumIconCount = 1, ShowStacks = true }); // Set, Raekor - 6Pcs feetBuffs.Add(new BuffRule(429855) { IconIndex = 5, MinimumIconCount = 1, ShowTimeLeft = true, ShowStacks = true }); // Set, Tal Rasha - 6Pcs feetBuffs.Add(new BuffRule(402458) { IconIndex = 1, MinimumIconCount = 1, ShowTimeLeft = true }); // Legendary, In-Geom feetBuffs.Add(new BuffRule(430674) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Legendary, Convention of Elements feetBuffs.Add(new BuffRule(79607) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Barbarian, Wrath of the Berserker feetBuffs.Add(new BuffRule(205187) { IconIndex = 1, MinimumIconCount = 1, ShowTimeLeft = false }); // Barbarian, Berserker Rage feetBuffs.Add(new BuffRule(205133) { IconIndex = 1, MinimumIconCount = 1, ShowTimeLeft = false }); // Barbarian, Brawler feetBuffs.Add(new BuffRule(79528) { IconIndex = null, MinimumIconCount = 1, ShowTimeLeft = true }); // Barbarian, Ignore Pain feetBuffs.Add(new BuffRule(134872) { IconIndex = 2, MinimumIconCount = 1, ShowTimeLeft = true, ShowStacks = true }); // Archon Stacks feetBuffs.Add(new BuffRule(134872) { IconIndex = 5, MinimumIconCount = 0, ShowTimeLeft = true, ShowStacks = true }); // Swami Archon Stacks Hud.GetPlugin <ArchonWizPlugin>().ShowInTown = false; Hud.GetPlugin <ArchonWizPlugin>().AlwaysShowElements = true; Log.MaxMessages = 60; }