public void PaintTopInGame(ClipState clipState) { var hedPlugin = Hud.GetPlugin <HotEnablerDisablerPlugin>(); bool GoOn = hedPlugin.CanIRun(Hud.Game.Me, this.GetType().Name); if (!GoOn) { return; } if (Hud.Render.UiHidden) { return; } if (clipState != ClipState.BeforeClip) { return; } CustomLifeWarningDecorator = new TopLabelDecorator(Hud) { BackgroundBrush = Hud.Render.CreateBrush(opacity, 255, 165, 0, 0), TextFont = Hud.Render.CreateFont("Segoe UI Light", 7, 250, 255, 255, 255, false, false, true), // it doesn't work without that line }; var percentLife = Hud.Game.Me.Defense.HealthPct; if (percentLife < (float)lifePercentage && percentLife > 25f) { if (opacity < 25) { opacity++; } CustomLifeWarningDecorator.Paint(0f, 0f, (float)maxX, (float)maxY, HorizontalAlign.Center); } else { if (opacity != 0) { opacity--; CustomLifeWarningDecorator.Paint(0f, 0f, (float)maxX, (float)maxY, HorizontalAlign.Center); } } }
protected override void Paint(float x, float y, float labelWidth, float labelHeight) { TopLabelDecorator selectedLabel = null; var selectedX = 0f; foreach (var label in LabelDecorators) { if (!Hud.Window.CursorInsideRect(x, y, labelWidth, labelHeight)) { label.Paint(x, y, labelWidth, labelHeight, HorizontalAlign.Center); } else { selectedLabel = label; selectedX = x; } x += labelWidth + SpacingAdjustmentInPixels; } if (selectedLabel != null) { selectedLabel.Paint(selectedX, y, labelWidth, labelHeight, HorizontalAlign.Center); } }
public void PaintTopInGame(ClipState clipState) { if (Hud.Game.Me.CurrentLevelNormal != 70 && Hud.Game.Me.CurrentLevelNormal > 0) { return; } if (Hud.Game.Me.HighestSoloRiftLevel < 70 && Hud.Game.Me.HighestSoloRiftLevel > 0) { return; } long PrimalAncientTotal = Hud.Tracker.CurrentAccountTotal.DropPrimalAncient; long AncientTotal = Hud.Tracker.CurrentAccountTotal.DropAncient; long LegendariesTotal = Hud.Tracker.CurrentAccountTotal.DropLegendary; string TotalPercPrimal = ((float)PrimalAncientTotal / (float)LegendariesTotal).ToString("0.00%"); string TotalPercAncient = ((float)AncientTotal / (float)LegendariesTotal).ToString("0.00%"); ancientDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 220, 227, 153, 25, true, false, 255, 0, 0, 0, true), TextFunc = () => ancientText, HintFunc = () => "Chance for the next Legendary drop to be Ancient." + Environment.NewLine + "Total Ancient drops : " + AncientTotal + " (" + TotalPercAncient + ") of Legendary drops", BackgroundBrush = Hud.Render.CreateBrush(50, 0, 0, 0, 0), }; primalDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 180, 255, 64, 64, true, false, 255, 0, 0, 0, true), TextFunc = () => primalText, HintFunc = () => "Chance for the next Legendary drop to be Primal Ancient." + Environment.NewLine + "Total Primal Ancient drops : " + PrimalAncientTotal + " (" + TotalPercPrimal + ") of Legendary drops", BackgroundBrush = Hud.Render.CreateBrush(50, 0, 0, 0, 0), }; double RNGprobaAncient = 9.7753333; double RNGprobaPrimal = 0.2246666; double probaAncient = ((float)(AncientTotal) / (float)(LegendariesTotal)) * 100; double probaPrimal = ((float)(PrimalAncientTotal) / (float)(LegendariesTotal)) * 100; double DiffProbaAncient = (RNGprobaAncient - probaAncient); double DiffProbaPrimal = (RNGprobaPrimal - probaPrimal); probaAncient += (DiffProbaAncient * 2); probaPrimal += (DiffProbaPrimal * 2); probaAncient = Math.Round(probaAncient, 4); probaPrimal = Math.Round(probaPrimal, 5); ancientText = "A: " + probaAncient + "%"; primalText = "P: " + probaPrimal + "%"; var uiRect = Hud.Render.GetUiElement("Root.NormalLayer.game_dialog_backgroundScreenPC.game_progressBar_healthBall").Rectangle; ancientDecorator.Paint(uiRect.Right - (uiRect.Width / 0.35f), uiRect.Top + (uiRect.Height / 1.168f), 75f, 25f, HorizontalAlign.Left); if (Hud.Game.Me.HighestSoloRiftLevel >= 70) { primalDecorator.Paint(uiRect.Right - (uiRect.Width / 0.42f), uiRect.Top + (uiRect.Height / 1.168f), 75f, 25f, HorizontalAlign.Left); } }
public void PaintTopInGame(ClipState clipState) { if (Hud.Game.Me.CurrentLevelNormal != 70) { return; } ancientDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 220, 227, 153, 25, true, false, 255, 0, 0, 0, true), TextFunc = () => ancientText, HintFunc = () => "Chance for the next Legendary drop to be Ancient." }; primalDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 180, 255, 64, 64, true, false, 255, 0, 0, 0, true), TextFunc = () => primalText, HintFunc = () => "Chance for the next Legendary drop to be Primal Ancient." }; double probaAncient = 0; double probaPrimal = 0; double powAncient = legendaryCount - ancientMarker; double powPrimal = legendaryCount - primalMarker; double ancientMaths = 90.00 / 100; double primalMaths = 99.78 / 100; if (powAncient == 0) { powAncient = 1; } if (powPrimal == 0) { powPrimal = 1; } probaAncient = (1 - Math.Pow(ancientMaths, powAncient)) * 100; probaPrimal = (1 - Math.Pow(primalMaths, powPrimal)) * 100; probaAncient = Math.Round(probaAncient, 2); probaPrimal = Math.Round(probaPrimal, 2); ancientText = "A: " + probaAncient + "%"; primalText = "P: " + probaPrimal + "%"; var uiRect = Hud.Render.GetUiElement("Root.NormalLayer.game_dialog_backgroundScreenPC.game_progressBar_manaBall").Rectangle; ancientDecorator.Paint(uiRect.Left - (uiRect.Width / 3f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); if (Hud.Game.Me.HighestSoloRiftLevel >= 70) { primalDecorator.Paint(uiRect.Left + (uiRect.Width / 10f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); } }
public void PaintWorld(WorldLayer layer) { if (!Hud.Game.Me.IsInTown) { IScreenCoordinate coord = Hud.Window.CreateScreenCoordinate(Hud.Window.CursorX, Hud.Window.CursorY); IWorldCoordinate cursor = coord.ToWorldCoordinate(); int count = 0; foreach (IMonster monster in Hud.Game.AliveMonsters) { if (monster.FloorCoordinate.XYDistanceTo(cursor) < Distance) { count++; } } if (DrawCursorCircle) { CursorCircleBrush.DrawWorldEllipse(Distance, -1, cursor); } if (DrawCursorLabel) { float width = Hud.Window.Size.Height * CursorLabelWRatio; float height = Hud.Window.Size.Height * CursorLabelHRatio; CursorLabelDecorator.Paint(coord.X + CursorLabelXOffset, coord.Y + CursorLabelYOffset, width, height, count.ToString(), null, ""); } if (DrawTopLabel) { float x = Hud.Window.Size.Width * TopLabelXRatio; float y = Hud.Window.Size.Height * TopLabelYRatio; float width = Hud.Window.Size.Height * TopLabelWRatio; float height = Hud.Window.Size.Height * TopLabelHRatio; TopLabelDecorator.Paint(x - width / 2, y, width, height, count.ToString(), null, ""); } if (DrawCursorLine) { var player = Hud.Game.Me.ScreenCoordinate; LineBrush.DrawLine(player.X, player.Y, coord.X, coord.Y); } if (DrawDistanceLabel) { var distance = Hud.Game.Me.FloorCoordinate.XYDistanceTo(cursor); float x = Hud.Window.Size.Width * DistanceLabelXRatio; float y = Hud.Window.Size.Height * DistanceLabelYRatio; float width = Hud.Window.Size.Height * DistanceLabelWRatio; float height = Hud.Window.Size.Height * DistanceLabelHRatio; TopLabelDecorator.Paint(x - width / 2, y, width, height, distance.ToString("F1", CultureInfo.InvariantCulture)); } } }
public void PaintTopInGame(ClipState clipState) { if (Hud.Game.Me.CurrentLevelNormal != 70 && Hud.Game.Me.CurrentLevelNormal > 0) { ancientMarker = legendaryCount; return; } if (Hud.Game.Me.HighestSoloRiftLevel < 70 && Hud.Game.Me.HighestSoloRiftLevel > 0) { primalMarker = legendaryCount; } if (RunOnlyOnce) { if (Hud.Tracker.CurrentAccountToday.DropLegendary != 0 && Hud.Tracker.CurrentAccountYesterday.DropPrimalAncient > 0) { legendaryCount = Hud.Tracker.CurrentAccountToday.DropLegendary; if (Hud.Tracker.CurrentAccountToday.DropAncient <= 1 && (legendaryCount - Hud.Tracker.CurrentAccountToday.DropAncient) > 100) { ancientMarker = 0; } else { long DropAncientToday = Hud.Tracker.CurrentAccountToday.DropAncient; if (DropAncientToday == 0) { DropAncientToday = 1; } ancientMarker = (int)(Hud.Tracker.CurrentAccountToday.DropLegendary - (Hud.Tracker.CurrentAccountToday.DropLegendary / DropAncientToday)); } if (Hud.Tracker.CurrentAccountToday.DropPrimalAncient <= 1) { primalMarker = 0; } else { long DropPrimalAncientToday = Hud.Tracker.CurrentAccountToday.DropPrimalAncient; if (DropPrimalAncientToday == 0) { DropPrimalAncientToday = 1; } primalMarker = (int)(Hud.Tracker.CurrentAccountToday.DropLegendary - (Hud.Tracker.CurrentAccountToday.DropLegendary / DropPrimalAncientToday)); } } else if (Hud.Tracker.CurrentAccountYesterday.DropLegendary != 0) { legendaryCount = Hud.Tracker.CurrentAccountYesterday.DropLegendary + Hud.Tracker.CurrentAccountToday.DropLegendary; var TodayYesterdayDropAncient = Hud.Tracker.CurrentAccountYesterday.DropAncient + Hud.Tracker.CurrentAccountToday.DropAncient; var TodayYesterdayDropPrimalAncient = Hud.Tracker.CurrentAccountYesterday.DropPrimalAncient + Hud.Tracker.CurrentAccountToday.DropPrimalAncient; if (TodayYesterdayDropAncient <= 1) { ancientMarker = 0; TodayYesterdayDropAncient = 1; } else { ancientMarker = (int)(legendaryCount - (legendaryCount / TodayYesterdayDropAncient)); } if (TodayYesterdayDropPrimalAncient <= 1) { primalMarker = 0; TodayYesterdayDropPrimalAncient = 1; } else { primalMarker = (int)(legendaryCount - (legendaryCount / TodayYesterdayDropPrimalAncient)); } } RunOnlyOnce = false; } long PrimalAncientTotal = Hud.Tracker.CurrentAccountTotal.DropPrimalAncient; long AncientTotal = Hud.Tracker.CurrentAccountTotal.DropAncient; long LegendariesTotal = Hud.Tracker.CurrentAccountTotal.DropLegendary; string TotalPercPrimal = ((float)PrimalAncientTotal / (float)LegendariesTotal).ToString("0.00%"); string TotalPercAncient = ((float)AncientTotal / (float)LegendariesTotal).ToString("0.00%"); ancientDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 220, 227, 153, 25, true, false, 255, 0, 0, 0, true), TextFunc = () => ancientText, HintFunc = () => "Chance for the next Legendary drop to be Ancient." + Environment.NewLine + "Total Ancient drops : " + AncientTotal + " (" + TotalPercAncient + ") of Legendary drops", }; primalDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 180, 255, 64, 64, true, false, 255, 0, 0, 0, true), TextFunc = () => primalText, HintFunc = () => "Chance for the next Legendary drop to be Primal Ancient." + Environment.NewLine + "Total Primal Ancient drops : " + PrimalAncientTotal + " (" + TotalPercPrimal + ") of Legendary drops", }; double probaAncient = 0; double probaPrimal = 0; double powAncient = legendaryCount - ancientMarker; double powPrimal = legendaryCount - primalMarker; double ancientMaths = 90.2246666 / 100; // previous : 90.00 double primalMaths = 99.7753334 / 100; // previous : 99.78 if (powAncient == 0) { powAncient = 1; } if (powPrimal == 0) { powPrimal = 1; } probaAncient = (1 - Math.Pow(ancientMaths, powAncient)) * 100; probaPrimal = (1 - Math.Pow(primalMaths, powPrimal)) * 100; probaAncient = Math.Round(probaAncient, 2); probaPrimal = Math.Round(probaPrimal, 2); ancientText = "A: " + probaAncient + "%"; primalText = "P: " + probaPrimal + "%"; var uiRect = Hud.Render.GetUiElement("Root.NormalLayer.game_dialog_backgroundScreenPC.game_progressBar_manaBall").Rectangle; ancientDecorator.Paint(uiRect.Left - (uiRect.Width / 3f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); if (Hud.Game.Me.HighestSoloRiftLevel >= 70) { primalDecorator.Paint(uiRect.Left + (uiRect.Width / 10f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); } bool KanaiRecipe = Hud.Render.GetUiElement("Root.NormalLayer.Kanais_Recipes_main").Visible; double InventoryLegendaryCount = 0; double InventoryAncientCount = 0; double InventoryPrimalCount = 0; foreach (var item in Hud.Inventory.ItemsInInventory) { if (item != null) { if (item.SnoItem == null || item.SnoItem.MainGroupCode == "gems_unique" || item.SnoItem.MainGroupCode == "potion") { continue; } string itemID = item.SnoItem.Sno.ToString() + item.CreatedAtInGameTick.ToString(); if (item.IsLegendary && !legendaries.Contains(itemID)) { InventoryLegendaryCount++; } if (item.AncientRank == 1 && !legendaries.Contains(itemID)) { InventoryAncientCount++; } if (item.AncientRank == 2 && !legendaries.Contains(itemID)) { InventoryPrimalCount++; } if (item.IsLegendary && !legendaries.Contains(itemID)) { legendaries.Add(itemID); } } } if (KanaiRecipe) { if (InventoryLegendaryCount > prevInventoryLegendaryCount) { legendaryCount++; } prevInventoryLegendaryCount = InventoryLegendaryCount; if (InventoryAncientCount > prevInventoryAncientCount) { ancientMarker = legendaryCount; } prevInventoryAncientCount = InventoryAncientCount; if (InventoryPrimalCount > prevInventoryPrimalCount) { primalMarker = legendaryCount; } prevInventoryPrimalCount = InventoryPrimalCount; } else { prevInventoryLegendaryCount = InventoryLegendaryCount; } prevInventoryAncientCount = InventoryAncientCount; prevInventoryPrimalCount = InventoryPrimalCount; }
public void PaintTopInGame(ClipState clipState) { if (Hud.Game.Me.CurrentLevelNormal != 70) { return; } ancientDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 220, 227, 153, 25, true, false, 255, 0, 0, 0, true), TextFunc = () => ancientText, HintFunc = () => "Chance for the next Legendary drop to be Ancient." }; primalDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("arial", 7, 180, 255, 64, 64, true, false, 255, 0, 0, 0, true), TextFunc = () => primalText, HintFunc = () => "Chance for the next Legendary drop to be Primal Ancient." }; double probaAncient = 0; double probaPrimal = 0; double powAncient = legendaryCount - ancientMarker; double powPrimal = legendaryCount - primalMarker; double ancientMaths = 90.00 / 100; double primalMaths = 99.78 / 100; if (powAncient == 0) { powAncient = 1; } if (powPrimal == 0) { powPrimal = 1; } probaAncient = (1 - Math.Pow(ancientMaths, powAncient)) * 100; probaPrimal = (1 - Math.Pow(primalMaths, powPrimal)) * 100; probaAncient = Math.Round(probaAncient, 2); probaPrimal = Math.Round(probaPrimal, 2); ancientText = "A: " + probaAncient + "%"; primalText = "P: " + probaPrimal + "%"; var uiRect = Hud.Render.GetUiElement("Root.NormalLayer.game_dialog_backgroundScreenPC.game_progressBar_manaBall").Rectangle; ancientDecorator.Paint(uiRect.Left - (uiRect.Width / 3f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); if (Hud.Game.Me.HighestSoloRiftLevel >= 70) { primalDecorator.Paint(uiRect.Left + (uiRect.Width / 10f), uiRect.Bottom - (uiRect.Height / 5.7f), 50f, 50f, HorizontalAlign.Left); } bool KanaiRecipe = Hud.Render.GetUiElement("Root.NormalLayer.Kanais_Recipes_main").Visible; double InventoryLegendaryCount = 0; double InventoryAncientCount = 0; double InventoryPrimalCount = 0; foreach (var item in Hud.Inventory.ItemsInInventory) { string itemID = item.SnoItem.Sno.ToString() + item.Perfection.ToString(); if (item.IsLegendary && !legendaries.Contains(itemID)) { InventoryLegendaryCount++; } if (item.AncientRank == 1 && !legendaries.Contains(itemID)) { InventoryAncientCount++; } if (item.AncientRank == 2 && !legendaries.Contains(itemID)) { InventoryPrimalCount++; } if (item.IsLegendary && Hud.Game.Me.CurrentLevelNormal == 70 && !legendaries.Contains(itemID)) { legendaries.Add(itemID); } } if (KanaiRecipe) { if (InventoryLegendaryCount > prevInventoryLegendaryCount && Hud.Game.Me.CurrentLevelNormal == 70) { legendaryCount++; } prevInventoryLegendaryCount = InventoryLegendaryCount; if (InventoryAncientCount > prevInventoryAncientCount || Hud.Game.Me.CurrentLevelNormal < 70) { ancientMarker = legendaryCount; } prevInventoryAncientCount = InventoryAncientCount; if (InventoryPrimalCount > prevInventoryPrimalCount || Hud.Game.Me.HighestSoloRiftLevel < 70) { primalMarker = legendaryCount; } prevInventoryPrimalCount = InventoryPrimalCount; } else { prevInventoryLegendaryCount = InventoryLegendaryCount; } prevInventoryAncientCount = InventoryAncientCount; prevInventoryPrimalCount = InventoryPrimalCount; }
public void PaintTopInGame(ClipState clipState) { NextHeroDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("Microsoft Sans Serif", 9, 225, 255, 255, 255, false, false, 100, 0, 0, 0, true), TextFunc = () => NextHeroText, }; if (Hud.Render.UiHidden) { return; } if (clipState != ClipState.BeforeClip) { return; } var uiInv = Hud.Inventory.InventoryMainUiElement; if (uiInv.Visible) { return; } if (!Hud.Game.IsInTown) { return; } NextHeroText = ""; var PosY = (maxY / 4) * 3 - 80; var PosX = (maxX / 8) * 7 - 80; var timeInGame = _watch.ElapsedMilliseconds; var Heroes = Hud.AccountHeroes.OrderBy(Hero => Hero.PlayedSeconds); var TimePlayedMe = Hud.Game.Me.Hero.PlayedSeconds + (int)(timeInGame / 1000); foreach (var Hero in Heroes.Where(t => t.PlayedSeconds < TimePlayedMe && t.Hardcore == Hud.Game.Me.Hero.Hardcore && t.Seasonal == Hud.Game.Me.Hero.Seasonal && t.Name != Hud.Game.Me.Hero.Name).Take(1)) { var Difference = (TimePlayedMe - Hero.PlayedSeconds); TimeSpan t = TimeSpan.FromSeconds(Difference); string Diff = string.Format("{0:D1}h {1:D1}m {2:D1}s", (int)t.TotalHours, t.Minutes, t.Seconds); NextHeroText = "━━━━━━━ Next Hero to play ━━━━━━━" + Environment.NewLine + Hero.Name + " [" + Hero.ClassDefinition.HeroClass + "]" + Environment.NewLine + Diff + " behind " + Hud.Game.Me.Hero.Name; var HeroTexture = Hud.Texture.GetTexture(890155253); var SeasonTexture = Hud.Texture.GetTexture(1944779632); var HardcoreTexture = Hud.Texture.GetTexture(2946806416); if (Hero.ClassDefinition.HeroClass.ToString() == "Barbarian") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(3921484788); } else { HeroTexture = Hud.Texture.GetTexture(1030273087); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "Crusader") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(3742271755); } else { HeroTexture = Hud.Texture.GetTexture(3435775766); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "DemonHunter") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(3785199803); } else { HeroTexture = Hud.Texture.GetTexture(2939779782); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "Monk") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(2227317895); } else { HeroTexture = Hud.Texture.GetTexture(2918463890); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "Necromancer") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(3285997023); } else { HeroTexture = Hud.Texture.GetTexture(473831658); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "WitchDoctor") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(3925954876); } else { HeroTexture = Hud.Texture.GetTexture(1603231623); } } else if (Hero.ClassDefinition.HeroClass.ToString() == "Wizard") { if (Hero.IsMale) { HeroTexture = Hud.Texture.GetTexture(44435619); } else { HeroTexture = Hud.Texture.GetTexture(876580014); } } HeroTexture.Draw(PosX - 50, PosY, 50f, 50f, 0.59f); if (Hero.Seasonal) { SeasonTexture.Draw(PosX - 50, PosY - 30, 42f, 84.666f, 0.59f); } if (Hero.Hardcore) { HardcoreTexture.Draw(PosX - 20, PosY + 35, 22f, 28.444f, 0.59f); } NextHeroDecorator.Paint(PosX, PosY, 50f, 50f, HorizontalAlign.Left); } }
public void PaintTopInGame(ClipState clipState) { CraftCountDecorator = new TopLabelDecorator(Hud) { TextFont = Hud.Render.CreateFont("Microsoft Sans Serif", 10, opacity, 255, 235, 170, true, true, opacity / 8, 81, 60, 11, false), TextFunc = () => craftCount.ToString("N0") + " owneth", }; var uiInv = Hud.Inventory.InventoryMainUiElement; deathsBreathCount = Hud.Game.Me.Materials.DeathsBreath; reusablePartsCount = Hud.Game.Me.Materials.ReusableParts; arcaneDustCount = Hud.Game.Me.Materials.ArcaneDust; veiledCrystalCount = Hud.Game.Me.Materials.VeiledCrystal; forgottenSoulCount = Hud.Game.Me.Materials.ForgottenSoul; bloodShardCount = Hud.Game.Me.Materials.BloodShard; khanduranRuneCount = Hud.Game.Me.Materials.KhanduranRune; caldeumNightShadeCount = Hud.Game.Me.Materials.CaldeumNightShade; arreatWarTapestryCount = Hud.Game.Me.Materials.ArreatWarTapestry; corruptedAngelFleshCount = Hud.Game.Me.Materials.CorruptedAngelFlesh; westmarchHolyWaterCount = Hud.Game.Me.Materials.WestmarchHolyWater; leoricsRegretCount = Hud.Game.Me.Materials.LeoricsSignet; idolOfTerrorCount = Hud.Game.Me.Materials.IdolOfTerror; vialOfPutridnessCount = Hud.Game.Me.Materials.VialOfPutridness; heartOfFrightCount = Hud.Game.Me.Materials.HeartOfFright; var grkLoopCount = 0; var puzzleRingLoopCount = 0; var bovineBardicheLoopCount = 0; foreach (var item in Hud.Inventory.ItemsInStash) { if (item.SnoItem.Sno == 2835237830) { grkLoopCount += (int)item.Quantity; // GR keystone } if (item.SnoItem.Sno == 2346057823) { bovineBardicheLoopCount += (int)item.Quantity; // Bovine Bardiche } if (item.SnoItem.Sno == 3106130529) { puzzleRingLoopCount += (int)item.Quantity; // Puzzle Ring } } foreach (var item in Hud.Inventory.ItemsInInventory) { if (item.SnoItem.Sno == 2835237830) { grkLoopCount += (int)item.Quantity; // GR keystone } if (item.SnoItem.Sno == 2346057823) { bovineBardicheLoopCount += (int)item.Quantity; // Bovine Bardiche } if (item.SnoItem.Sno == 3106130529) { puzzleRingLoopCount += (int)item.Quantity; // Puzzle Ring } } grkCount = Math.Abs(grkLoopCount); puzzleRingCount = Math.Abs(puzzleRingLoopCount); bovineBardicheCount = Math.Abs(bovineBardicheLoopCount); var craftCountX = (maxX / 4) * 3 + 30; var craftCountY = (maxY / 4) * 3 + 50; if (deathsBreathCount > prevDeathsBreathCount || deathsBreathCount < prevDeathsBreathCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevDeathsBreathCount = deathsBreathCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2087837753; var DeathsBreath = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(DeathsBreath); craftCount = deathsBreathCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (reusablePartsCount > prevReusablePartsCount || reusablePartsCount < prevReusablePartsCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevReusablePartsCount = reusablePartsCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 3931359676; var ReusableParts = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(ReusableParts); craftCount = reusablePartsCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (arcaneDustCount > prevArcaneDustCount || arcaneDustCount < prevArcaneDustCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevArcaneDustCount = arcaneDustCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2709165134; var ArcaneDust = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(ArcaneDust); craftCount = arcaneDustCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (veiledCrystalCount > prevVeiledCrystalCount || veiledCrystalCount < prevVeiledCrystalCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevVeiledCrystalCount = veiledCrystalCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 3689019703; var VeiledCrystal = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(VeiledCrystal); craftCount = veiledCrystalCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (forgottenSoulCount > prevForgottenSoulCount || forgottenSoulCount < prevForgottenSoulCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevForgottenSoulCount = forgottenSoulCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2073430088; var ForgottenSoul = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(ForgottenSoul); craftCount = forgottenSoulCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (bloodShardCount > prevBloodShardCount || bloodShardCount < prevBloodShardCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevBloodShardCount = bloodShardCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2603730171; var BloodShard = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(BloodShard); craftCount = bloodShardCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (grkCount > prevGrkCount || grkCount < prevGrkCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevGrkCount = grkCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2835237830; var grk = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(grk); craftCount = grkCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (bovineBardicheCount > prevBovineBardicheCount || bovineBardicheCount < prevBovineBardicheCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevBovineBardicheCount = bovineBardicheCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2346057823; var bovineBardiche = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(bovineBardiche); craftCount = bovineBardicheCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (puzzleRingCount > prevPuzzleRingCount || puzzleRingCount < prevPuzzleRingCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevPuzzleRingCount = puzzleRingCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 3106130529; var puzzleRing = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(puzzleRing); craftCount = puzzleRingCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (khanduranRuneCount > prevKhanduranRuneCount || khanduranRuneCount < prevKhanduranRuneCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevKhanduranRuneCount = khanduranRuneCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1948629088; var khanduranRune = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(khanduranRune); craftCount = khanduranRuneCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (caldeumNightShadeCount > prevCaldeumNightShadeCount || caldeumNightShadeCount < prevCaldeumNightShadeCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevCaldeumNightShadeCount = caldeumNightShadeCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1948629089; var caldeumNightShade = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(caldeumNightShade); craftCount = caldeumNightShadeCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (arreatWarTapestryCount > prevArreatWarTapestryCount || arreatWarTapestryCount < prevArreatWarTapestryCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevArreatWarTapestryCount = arreatWarTapestryCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1948629090; var arreatWarTapestry = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(arreatWarTapestry); craftCount = arreatWarTapestryCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (corruptedAngelFleshCount > prevCorruptedAngelFleshCount || corruptedAngelFleshCount < prevCorruptedAngelFleshCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevCorruptedAngelFleshCount = corruptedAngelFleshCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1948629091; var corruptedAngelFlesh = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(corruptedAngelFlesh); craftCount = corruptedAngelFleshCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (westmarchHolyWaterCount > prevWestmarchHolyWaterCount || westmarchHolyWaterCount < prevWestmarchHolyWaterCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevWestmarchHolyWaterCount = westmarchHolyWaterCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1948629092; var westmarchHolyWater = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(westmarchHolyWater); craftCount = westmarchHolyWaterCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (leoricsRegretCount > prevLeoricsRegretCount || leoricsRegretCount < prevLeoricsRegretCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevLeoricsRegretCount = leoricsRegretCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 1102953247; var leoricsRegret = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(leoricsRegret); craftCount = leoricsRegretCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (idolOfTerrorCount > prevIdolOfTerrorCount || idolOfTerrorCount < prevIdolOfTerrorCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevIdolOfTerrorCount = idolOfTerrorCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2670343450; var idolOfTerror = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(idolOfTerror); craftCount = idolOfTerrorCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (vialOfPutridnessCount > prevVialOfPutridnessCount || vialOfPutridnessCount < prevVialOfPutridnessCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevVialOfPutridnessCount = vialOfPutridnessCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 2029265596; var vialOfPutridness = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(vialOfPutridness); craftCount = vialOfPutridnessCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else if (heartOfFrightCount > prevHeartOfFrightCount || heartOfFrightCount < prevHeartOfFrightCount) { if (opacity < 200) { opacity += 2; itemOpacity += 0.010f; } else { prevHeartOfFrightCount = heartOfFrightCount; } if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } itemSno = 3336787100; var heartOfFright = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(heartOfFright); craftCount = heartOfFrightCount; texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } else { if (opacity != 0) { opacity -= 2; itemOpacity -= 0.010f; if (uiInv.Visible) { craftCountX -= (maxX / 4) + 60; } var Fadeout = Hud.Inventory.GetSnoItem(itemSno); var texture = Hud.Texture.GetItemTexture(Fadeout); texture.Draw(craftCountX - 24, craftCountY + 12, 23f, 23f, itemOpacity); CraftCountDecorator.Paint(craftCountX, craftCountY, 50f, 50f, HorizontalAlign.Left); } } }