RunStats (+ Menu Plugin System) menu

User Tag List

Page 5 of 5 FirstFirst 12345
Results 61 to 70 of 70
  1. #61
    wad1532's Avatar Member
    Reputation
    7
    Join Date
    Mar 2019
    Posts
    94
    Thanks G/R
    11/6
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Razorfish View Post
    I posted an updated download to fix a couple of issues I noticed with paging through long lists of plugins. The files to update are listed in the changelog entry:
    WOOT way to go Razor!!!!! very awesome plugin and you fix it !!!

    RunStats (+ Menu Plugin System)
  2. #62
    Razorfish's Avatar Contributor
    Reputation
    188
    Join Date
    Apr 2019
    Posts
    178
    Thanks G/R
    19/158
    Trade Feedback
    0 (0%)
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Just rolled out an update to the Menu Plugin System to fill a request and fix a visual bug:

    November 28, 2021
    - RunStats\MenuXP - implemented the ability to click any of the statistics in the hover panel to set it as the display in the menu bar
    - Label\LabelTextDecorator - fixed the jittery text when text labels are updated within tables

    The download is linked on the project page.
    Last edited by Razorfish; 11-28-2021 at 10:32 AM. Reason: added link

  3. Thanks wad1532 (1 members gave Thanks to Razorfish for this useful post)
  4. #63
    knight84's Avatar Active Member
    Reputation
    19
    Join Date
    Mar 2017
    Posts
    270
    Thanks G/R
    24/18
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    is it possible too count 10 squirt stack instead of 5 in the uptime helper ?


    // RunStats Buffs Uptime Helper by Razor
    // Added Flying Dragon Uptime by S4000
    // Added F&R Uptime, Squirt 5+ stacks Uptime & Archon Uptime by HaKache

    using Turbo.Plugins.Default;
    using System.Drawing;
    using SharpDX.DirectInput;
    using SharpDX.DirectWrite;
    using System;
    using System.Collections.Generic;
    using System.Globalization;
    using System.Linq;
    using System.Media;
    using System.Threading;

    namespace Turbo.Plugins.LiveStats.Modules
    {
    public class LiveStats_UptimeHelper : BasePlugin, IAfterCollectHandler, ICustomizer //, IKeyEventHandler //, IInGameTopPainter
    {
    public string TextUptime { get; set; } = "Uptime";
    public int OculusValidDistanceFromTarget { get; set; } = 40; // Skeletal Mage reach is about 40 yards, oculus radius is about 10 yards

    public IFont TextFont { get; set; }
    public IBrush BgBrush { get; set; }
    public IBrush BgBrushAlt { get; set; }

    public class UptimeRule
    {
    // Rules
    public string Name { get; set; } // Name of the rule (For later use ?)
    public bool IsEnabled { get; set; } = true; // Is this rule enabled?
    public Func<bool> IsRelevant { get; set; } // Does this tracked stat apply to the current hero?
    public Func<bool> IsUp { get; set; } // Is this stat up?
    public Func<bool> IsWatching { get; set; } // What is the context for the uptime? (e.g. in a rift + in combat)
    public string Description { get; set; }

    // Track and display
    public IWatch Uptime { get; set; } // Duration for which IsUp returns true
    public IWatch TotalTime { get; set; } // Duration for which IsWatching returns true
    public TopLabelDecorator Label { get; set; } // Display Uptime / TotalTime
    public IBrush BgBrush { get; set; } // Optional
    public IFont Font { get; set; } // Optional

    public UptimeRule() {}

    public decimal Percent() {
    return (TotalTime.ElapsedMilliseconds > 0 ?
    ((decimal)Uptime.ElapsedMilliseconds/(decimal)TotalTime.ElapsedMilliseconds) : 0);
    }
    }
    public List<UptimeRule> Watching { get; set; }

    public TopLabelDecorator Label { get; set; }
    public List<TopLabelDecorator> ExpandUpLabels { get; set; }

    public int Priority { get; set; } = 8;
    public int Hook { get; set; } = 0;

    public LiveStats_UptimeHelper()
    {
    Enabled = true;
    }

    public void Customize()
    {
    // Add this display to the LiveStats readout with a(n optional) specified positional order priority of 2
    Hud.RunOnPlugin<LiveStatsPlugin>(plugin => {
    plugin.Add(this.Label, this.Priority, this.Hook);
    });
    }

    public override void Load(IController hud)
    {
    base.Load(hud);

    TextFont = Hud.Render.CreateFont("tahoma", 7, 200, 255, 255, 255, false, false, true);

    var plugin = Hud.GetPlugin<LiveStatsPlugin>();
    BgBrush = plugin.BgBrush;
    BgBrushAlt = plugin.BgBrushAlt;

    Watching = new List<UptimeRule>();

    // You can sort these rules by priority. The first relevant rule for your character will be the one shown in the non-expended menu label.

    //Track LandOfTheDead uptime
    Watching.Add(new UptimeRule()
    {
    Name = "LandOfTheDead",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Me.Powers.UsedSkills.Any(s => s.SnoPower.Sno == Hud.Sno.SnoPowers.Necromancer_LandOfTheDead.Sno), // landOfTheDead Skill is on the action bar
    IsUp = () => IsInRift() && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Necromancer_LandOfTheDead.Sno, 4), // We watch uptime even if not in combat
    IsWatching = () => IsInRift(),
    Description = Hud.Sno.SnoPowers.Necromancer_LandOfTheDead.NameLocalized + " " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 180, 210, 116, false, false, true),
    });

    // Track Flying Dragon uptime
    Watching.Add(new UptimeRule()
    {
    Name = "FD",
    IsEnabled = true,
    IsRelevant = () => (Hud.Game.Me.CubeSnoItem1?.Sno == Hud.Sno.SnoItems.Unique_CombatStaff_2H_009_x1.Sno), // FD is cubed
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.FlyingDragon.Sno, 1),
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "Flying Dragon " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    //BgBrush = Hud.Render.CreateBrush(200, 81, 78, 72, 0),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 215, 190, 100, false, false, true),
    });

    // Track Simulacrum uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Simulacrum",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Me.Powers.UsedSkills.Any(s => s.SnoPower.Sno == Hud.Sno.SnoPowers.Necromancer_Simulacrum.Sno), // Simulacrum Skill is on the action bar
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Necromancer_Simulacrum.Sno, 1),
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = Hud.Sno.SnoPowers.Necromancer_Simulacrum.NameLocalized + " " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    //BgBrush = Hud.Render.CreateBrush(200, 107, 3, 3, 0),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 60, 60, false, false, true),
    });

    // Track Gruesome Feast 4+ Stacks uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Gruesome",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Me.Powers.UsedPassives.Any(s => s.Sno == Hud.Sno.SnoPowers.WitchDoctor_Passive_GruesomeFeast.Sno), // Gruesome Feast is an active passive (Doesnt account for Hellfire...)
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.GetAttributeValue(Hud.Sno.Attributes.Buff_Icon_Count1, 208594) == 4, // At least 4 stacks of Gruesome Feast
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = Hud.Sno.SnoPowers.WitchDoctor_Passive_GruesomeFeast.NameLocalized + " " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 0, 50, false, false, true),
    });

    // Track Focus + Restraint uptime
    // Note: IsRelevant => Checking for buffs is inconsistent - they sometimes drop off for a moment and then are reapplied (might be due to latency or packet loss), this function has to be consistent because it resets timers when it returns false
    Watching.Add(new UptimeRule()
    {
    Name = "FnR",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Items.Any(x => (x.Location == ItemLocation.LeftRing || x.Location == ItemLocation.RightRing) && x.SnoItem.Sno == Hud.Sno.SnoItems.Unique_Ring_Set_001_x1.Sno) && Hud.Game.Items.Any(x => (x.Location == ItemLocation.LeftRing || x.Location == ItemLocation.RightRing) && x.SnoItem.Sno == Hud.Sno.SnoItems.Unique_Ring_Set_002_x1.Sno), // Unique_Ring_Set_001_x1 (Focus) - Unique_Ring_Set_002_x1 (Restraint)
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.BuffIsActive(359583, 2) && Hud.Game.Me.Powers.BuffIsActive(359583, 1),
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "Focus & Restraint " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 120, 20, false, false, true),
    });

    // Track Squirt >= 10 stacks uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Squirt",
    IsEnabled = true,
    IsRelevant = () => (Hud.Game.Me.CubeSnoItem3?.Sno == 1187653737 || Hud.Game.Items.Any(x => x.Location == ItemLocation.Neck && x.SnoItem.Sno == 1187653737)), // Hud.Sno.SnoItems.Unique_Amulet_010_x1.Sno
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.GetAttributeValue(Hud.Sno.Attributes.Power_Buff_5_Visual_Effect_None , Hud.Sno.SnoPowers.SquirtsNecklace.Sno) == 1, // 5 stacks of Squirt - Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[10]
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "5+ Stacks Squirt " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 200, 30, false, false, true),
    });

    // Track Archon uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Archon",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Me.Powers.UsedSkills.Any(s => s.SnoPower.Sno == Hud.Sno.SnoPowers.Wizard_Archon.Sno), // Archon Skill is on the action bar
    IsUp = () => IsInRift() && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Wizard_Archon.Sno, 2), // We watch uptime even if not in combat
    IsWatching = () => IsInRift(),
    Description = Hud.Sno.SnoPowers.Wizard_Archon.NameLocalized + " " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 180, 76, 216, false, false, true),
    });

    // Track Hexing Pants uptime
    // Note: IsRelevant => Checking for buffs is inconsistent - they sometimes drop off for a moment and then are reapplied (might be due to latency or packet loss), this function has to be consistent because it resets timers when it returns false
    Watching.Add(new UptimeRule()
    {
    Name = "Hexing",
    IsEnabled = true,
    IsRelevant = () => (Hud.Game.Me.CubeSnoItem2?.Sno == Hud.Sno.SnoItems.Unique_Pants_101_x1.Sno) || Hud.Game.Items.Any(x => x.Location == ItemLocation.Legs && x.SnoItem.Sno == Hud.Sno.SnoItems.Unique_Pants_101_x1.Sno), // Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.HexingPantsOfMrYan.Sno), // Hexing pants is equipped/cubed
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.HexingPantsOfMrYan.Sno, 2),
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "Hexing Pants " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 135, 135, 135, false, false, true),
    });

    // Track Dayntee's Buff uptime
    // Note: IsRelevant => Checking for buffs is inconsistent - they sometimes drop off for a moment and then are reapplied (might be due to latency or packet loss), this function has to be consistent because it resets timers when it returns false
    Watching.Add(new UptimeRule()
    {
    Name = "Dayntee",
    IsEnabled = true,
    IsRelevant = () => (Hud.Game.Me.CubeSnoItem2?.Sno == Hud.Sno.SnoItems.P61_Unique_Belt_01.Sno) || Hud.Game.Items.Any(x => x.Location == ItemLocation.Waist && x.SnoItem.Sno == Hud.Sno.SnoItems.P61_Unique_Belt_01.Sno), // Dayntee's is cubed or equipped
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.DaynteesBinding.Sno, 1),
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "Dayntee's " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    //BgBrush = Hud.Render.CreateBrush(200, 81, 78, 72, 0),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 251, 209, false, false, true),
    });

    // Track IP uptime
    Watching.Add(new UptimeRule()
    {
    Name = "IP",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Players.Any(p => p.HeroClassDefinition.HeroClass == HeroClass.Barbarian && p.Powers.UsedSkills.Any(x => x.SnoPower.Sno == Hud.Sno.SnoPowers.Barbarian_IgnorePain.Sno)), //someone in the party has IP equipped
    IsUp = () =>
    IsInRift() &&
    Hud.Game.Me.InCombat &&
    Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Barbarian_IgnorePain.Sno) &&
    !Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Generic_ActorInvulBuff.Sno) && //not in stasis
    !Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Generic_PagesBuffInvulnerable .Sno), //no Shield Pylon
    IsWatching = () =>
    IsInRift() &&
    Hud.Game.Me.InCombat &&
    !Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Generic_ActorInvulBuff.Sno) && //not in stasis
    !Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.Generic_PagesBuffInvulnerable .Sno), //no Shield Pylon
    Description = Hud.Sno.SnoPowers.Barbarian_IgnorePain.NameLocalized + " " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    //BgBrush = Hud.Render.CreateBrush(200, 9, 68, 34, 0),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 18, 234, 110, false, false, true),
    });

    // Track Oculus Buff uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Oculus",
    IsEnabled = true,
    IsRelevant = () => Hud.Game.Players.Any(p => p.Powers.BuffIsActive(Hud.Sno.SnoPowers.OculusRing.Sno)), // Someone in the party (or active follower) has oculus ring equipped/cubed
    IsUp = () =>
    IsInRift() &&
    Hud.Game.Me.InCombat &&
    Hud.Game.Me.Powers.BuffIsActive(Hud.Sno.SnoPowers.OculusRing.Sno, 2) &&
    Hud.Game.AliveMonsters.Any(m => m.IsElite && m.Rarity != ActorRarity.RareMinion && m.CentralXyDistanceToMe < OculusValidDistanceFromTarget), //player.FloorCoordinate.XYZDistanceTo(m.FloorCoordinate)
    IsWatching = () => {
    if (!IsInRift()) return false;
    if (!Hud.Game.Me.InCombat) return false;
    var circles = Hud.Game.Actors.Where(a => a.SnoActor.Sno == ActorSnoEnum._generic_proxy && a.GetAttributeValueAsInt(Hud.Sno.Attributes.Power_Buff_1_Visual_Effect_None, Hud.Sno.SnoPowers.OculusRing.Sno) == 1);
    return circles.Any(c => Hud.Game.AliveMonsters.Any(m => m.IsElite && m.Rarity != ActorRarity.RareMinion && c.FloorCoordinate.XYZDistanceTo(m.FloorCoordinate) < OculusValidDistanceFromTarget+10));
    },
    Description = "Oculus " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    //BgBrush = Hud.Render.CreateBrush(200, 76, 79, 7, 0),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 158, 255, 100, false, false, true), //255, 253, 229
    });

    // Create all the uptime hover labels based on what is being watched
    ExpandUpLabels = new List<TopLabelDecorator>();
    foreach (UptimeRule rule in Watching.Where(r => r.IsEnabled)) // IsEnabled ?
    {
    TopLabelDecorator label = new TopLabelDecorator(Hud) {
    TextFont = (rule.Font == null ? TextFont : rule.Font),
    BackgroundBrush = (rule.BgBrush == null ? BgBrush : rule.BgBrush),
    ExpandedHintFont = TextFont,
    ExpandedHintWidthMultiplier = (float)((Hud.Window.Size.Width / 1000)* 2.0), // 1.5, 1.75 ?
    TextFunc = () => string.Format("{0}/{1}",
    ValueToString(rule.Uptime.ElapsedMilliseconds * TimeSpan.TicksPerMillisecond, ValueFormat.LongTime),
    ValueToString(rule.TotalTime.ElapsedMilliseconds * TimeSpan.TicksPerMillisecond, ValueFormat.LongTime)
    ),
    HintFunc = () =>
    {
    var pct = rule.Percent() * 100;
    return string.Format("({0}%) {1}", pct.ToString((pct == 0 ? "F0" : "F1"), CultureInfo.InvariantCulture), rule.Description);
    },
    };

    rule.Label = label;
    ExpandUpLabels.Add(label);
    }

    // Create the main menu label based on what is being watched
    Label = new TopLabelDecorator(Hud)
    {
    TextFont = TextFont,
    //BackgroundBrush = BgBrush,
    TextFunc = () => {
    var firstActiveRule = Watching.FirstOrDefault(r => r.IsRelevant());
    if (firstActiveRule != null)
    {
    var pct = firstActiveRule.Percent() * 100;
    return string.Format("{0}% {1}", pct.ToString((pct == 0 ? "F0" : "F1"), CultureInfo.InvariantCulture), TextUptime.ToLower());
    }

    return string.Empty;
    }, //ValueToString(Hud.Game.Me.Defense.EhpCur, ValueFormat.ShortNumber),
    HintFunc = () => "Uptime",
    ExpandUpLabels = this.ExpandUpLabels,
    };
    }

    public void AfterCollect()
    {
    if (!Hud.Game.IsInGame) return;

    // Calculate uptimes
    bool isAnyRelevant = false;
    int alternate = 0;
    foreach (UptimeRule rule in Watching.Where(r => r.IsEnabled)) // IsEnabled ?
    {
    // Show or hide labels based on whether or not it is relevant to the current hero
    if (!rule.IsRelevant())
    {
    rule.Label.Enabled = false;
    rule.Uptime.Stop();
    rule.Uptime.Reset();
    rule.TotalTime.Stop();
    rule.TotalTime.Reset();
    continue;
    }
    rule.Label.Enabled = true;
    rule.Label.BackgroundBrush = (alternate++ % 2 == 0 ? BgBrush : BgBrushAlt);
    isAnyRelevant = true;

    // Update uptime
    if (rule.IsUp() && !Hud.Game.IsPaused) // We check if game is not paused
    {
    if (!rule.Uptime.IsRunning)
    rule.Uptime.Start();
    }
    else
    rule.Uptime.Stop();

    // Update total time
    if (rule.IsWatching() && !Hud.Game.IsPaused) // We check if game is not paused
    {
    if (!rule.TotalTime.IsRunning)
    rule.TotalTime.Start();
    }
    else
    rule.TotalTime.Stop();
    }

    Label.Enabled = isAnyRelevant;
    }

    public bool IsInRift()
    {
    return (Hud.Game.SpecialArea == SpecialArea.Rift) || (Hud.Game.SpecialArea == SpecialArea.GreaterRift);
    }
    }
    }

  5. #64
    Razorfish's Avatar Contributor
    Reputation
    188
    Join Date
    Apr 2019
    Posts
    178
    Thanks G/R
    19/158
    Trade Feedback
    0 (0%)
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by knight84 View Post
    is it possible too count 10 squirt stack instead of 5 in the uptime helper ?


    // RunStats Buffs Uptime Helper by Razor
    // Added Flying Dragon Uptime by S4000
    // Added F&R Uptime, Squirt 5+ stacks Uptime & Archon Uptime by HaKache

    using Turbo.Plugins.Default;
    using System.Drawing;
    using SharpDX.DirectInput;
    using SharpDX.DirectWrite;
    using System;
    using System.Collections.Generic;
    using System.Globalization;
    using System.Linq;
    using System.Media;
    using System.Threading;

    namespace Turbo.Plugins.LiveStats.Modules
    {
    I was scratching my head about this question for a moment since RunStats already checks for 10 stacks instead of 5, but then I saw that you're asking about hakache's LiveStats plugin, not RunStats. Wrong thread...


    Code:
                // Track Squirt >= 10 stacks uptime
    Watching.Add(new UptimeRule()
                {
    		Name = "Squirt",
    		IsEnabled = true,
                    IsRelevant = () => (Hud.Game.Me.CubeSnoItem3?.Sno == 1187653737 || Hud.Game.Items.Any(x => x.Location == ItemLocation.Neck && x.SnoItem.Sno == 1187653737)), // Hud.Sno.SnoItems.Unique_Amulet_010_x1.Sno
                    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.GetAttributeValue(Hud.Sno.Attributes.Power_Buff_5_Visual_Effect_None, Hud.Sno.SnoPowers.SquirtsNecklace.Sno) == 1, // 5 stacks of Squirt - Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[10]
                    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
                    Description = "5+ Stacks Squirt " + TextUptime,
                    Uptime = Hud.Time.CreateWatch(),
                    TotalTime = Hud.Time.CreateWatch(),
                    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 200, 30, false, false, true),
                });
    Even so, I think this may answer your question - replace the part above that is highlighted in red with
    Code:
    Hud.Game.Me.Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[5] == 10

  6. Thanks knight84 (1 members gave Thanks to Razorfish for this useful post)
  7. #65
    knight84's Avatar Active Member
    Reputation
    19
    Join Date
    Mar 2017
    Posts
    270
    Thanks G/R
    24/18
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    oh sry i tought its the same plugin .P stupid me


    thx anyway

  8. #66
    knight84's Avatar Active Member
    Reputation
    19
    Join Date
    Mar 2017
    Posts
    270
    Thanks G/R
    24/18
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    did i made an mistake in the code ?? its showing 102% squirts up

    // Track Squirt >= 10 stacks uptime
    Watching.Add(new UptimeRule()
    {
    Name = "Squirt",
    IsEnabled = true,
    IsRelevant = () => (Hud.Game.Me.CubeSnoItem3?.Sno == 1187653737 || Hud.Game.Items.Any(x => x.Location == ItemLocation.Neck && x.SnoItem.Sno == 1187653737)), // Hud.Sno.SnoItems.Unique_Amulet_010_x1.Sno
    IsUp = () => Hud.Game.Me.Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[5] == 10, // 10 stacks of Squirt - Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[10]
    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
    Description = "10 Stacks Squirt " + TextUptime,
    Uptime = Hud.Time.CreateWatch(),
    TotalTime = Hud.Time.CreateWatch(),
    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 200, 30, false, false, true),
    });

  9. #67
    Razorfish's Avatar Contributor
    Reputation
    188
    Join Date
    Apr 2019
    Posts
    178
    Thanks G/R
    19/158
    Trade Feedback
    0 (0%)
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by knight84 View Post
    did i made an mistake in the code ?? its showing 102% squirts up

    Code:
     // Track Squirt >= 10 stacks uptime
                Watching.Add(new UptimeRule()
                {
    		Name = "Squirt",
    		IsEnabled = true,
                    IsRelevant = () => (Hud.Game.Me.CubeSnoItem3?.Sno == 1187653737 || Hud.Game.Items.Any(x => x.Location == ItemLocation.Neck && x.SnoItem.Sno == 1187653737)), // Hud.Sno.SnoItems.Unique_Amulet_010_x1.Sno
                    IsUp = () => Hud.Game.Me.Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[5] == 10, // 10 stacks of Squirt - Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[10]
                    IsWatching = () => IsInRift() && Hud.Game.Me.InCombat,
                    Description = "10 Stacks Squirt " + TextUptime,
                    Uptime = Hud.Time.CreateWatch(),
                    TotalTime = Hud.Time.CreateWatch(),
                    Font = Hud.Render.CreateFont("tahoma", 7, 255, 255, 200, 30, false, false, true),
                });
    Yes, you replaced all of the IsUp condition instead of only the part I highlighted in red previously. If you add back in the rift location and combat checks, then it shouldn't give you an uptime above 100% (it's probably because of the way I originally coded it - IsWatching and IsUp checks are likely distinct instead of working together):
    Code:
    IsUp = () => IsInRift() && Hud.Game.Me.InCombat && Hud.Game.Me.Powers.GetBuff(Hud.Sno.SnoPowers.SquirtsNecklace.Sno).IconCounts[5] == 10,
    Last edited by Razorfish; 12-10-2021 at 12:09 PM.

  10. #68
    Razorfish's Avatar Contributor
    Reputation
    188
    Join Date
    Apr 2019
    Posts
    178
    Thanks G/R
    19/158
    Trade Feedback
    0 (0%)
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Verified that this plugin package works with the latest patch and latest TH. And a little update to add a requested feature: showing the running average of rift completion times when the total number of completions exceeds the number of rift events shown.

    December 10, 2021
    - RunStats\MenuNephalemRift - now also keeps track of a running average for the completion time, separate from the the average of the displayed history events (shown only once the total completions exceeds the history shown count)
    - RunStats\MenuGreaterRift - now also keeps track of a running average for the completion time, separate from the the average of the displayed history events (shown only once the total completions exceeds the history shown count)
    - Util\UIOverlapHelper - added the quest reward dialog (which includes rift completion) to the list of blocking ui elements

    The download is linked on the project page.
    Last edited by Razorfish; 12-10-2021 at 05:29 PM. Reason: added link

  11. #69
    mois's Avatar Member
    Reputation
    8
    Join Date
    Feb 2018
    Posts
    54
    Thanks G/R
    178/7
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey Razor,

    Could you add GR-Tier for PartyCOE? since you added special areas

  12. #70
    Razorfish's Avatar Contributor
    Reputation
    188
    Join Date
    Apr 2019
    Posts
    178
    Thanks G/R
    19/158
    Trade Feedback
    0 (0%)
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by mois View Post
    Hey Razor,

    Could you add GR-Tier for PartyCOE? since you added special areas
    I would say "wrong thread" but I didn't make a thread for PartyCOE It should be possible to add the check by altering the custom condition function PlaySounds on line 66 (or in any Customizer file):

    Code:
    public Func<IController, IPlayer, bool> PlaySounds { get; set; } = (Hud, AnnouncedPlayer) => Hud.Game.SpecialArea == SpecialArea.GreaterRift && Hud.Game.Me.InGreaterRiftRank > x && (AnnouncedPlayer.IsMe || (AnnouncedPlayer.InGreaterRift && AnnouncedPlayer.InGreaterRiftRank > x));
    ...where x is the rift level.

    Note that there's a subtle difference: Hud.Game.SpecialArea == SpecialArea.GreaterRift is only true until the rift guardian dies. Hud.Game.Me.InGreaterRift && Hud.Game.Me.InGreaterRiftRank > 0 is true as long as you are in a greater rift area.

  13. Thanks mois (1 members gave Thanks to Razorfish for this useful post)
Page 5 of 5 FirstFirst 12345

Similar Threads

  1. Movable plugins system
    By Razorfish in forum TurboHUD Community Plugins
    Replies: 103
    Last Post: 09-23-2021, 06:44 PM
  2. Replies: 1
    Last Post: 06-14-2020, 04:57 AM
  3. New to the honor system? Guide here
    By Amedis in forum World of Warcraft Guides
    Replies: 0
    Last Post: 06-16-2006, 09:21 AM
  4. The Honour System Explained
    By Cush in forum World of Warcraft Guides
    Replies: 2
    Last Post: 05-27-2006, 06:50 PM
  5. Replies: 0
    Last Post: 03-24-2006, 01:43 AM
All times are GMT -5. The time now is 07:46 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search