[ENGLISH] [Prrovoss] PopupNotifications menu

User Tag List

Page 2 of 5 FirstFirst 12345 LastLast
Results 16 to 30 of 75
  1. #16
    xviperousx's Avatar Member
    Reputation
    1
    Join Date
    Aug 2017
    Posts
    3
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Kasztan100 View Post
    it's possible to change popup to color of dropped items, i think about frame when its normal legend then black, when ancient its orange and a primal set it to red
    example :P

    Attachment 52651
    Hi there

    i did those changes. I am not pro so i hope the code is more or less ok, but it works


    PopupNotifications.cs:
    Code:
    using System;
    using System.Linq;
    
    using Turbo.Plugins.Default;
    
    namespace Turbo.Plugins.Prrovoss
    {
    
        public class PopupNotifications : BasePlugin, IInGameWorldPainter 
        {
    
            public enum EnumPopupDecoratorToUse {Default, Ancient, Primal };
    
            public TopLabelWithTitleDecorator PrimalPopupDecorator { get; set; }
            public TopLabelWithTitleDecorator AcientPopupDecorator { get; set; }
            public TopLabelWithTitleDecorator DefaultPopupDecorator { get; set; }
    
            public float RatioX { get; set; }
            public float RatioY { get; set; }
            public float RatioW { get; set; }
            public float RatioH { get; set; }
            public float VerticalGap { get; set; }
    
            public class Popup : IQueueItem
            {
                public string Text { get; set; }
                public string Title { get; set; }
                public string Hint { get; set; }
                public DateTime QueuedOn { get; private set; }
                public TimeSpan LifeTime { get; private set; }
                public EnumPopupDecoratorToUse PopUpDecoratorTouse { get; private set; }
                public Popup(string text, string title, TimeSpan lifetime, string hint, EnumPopupDecoratorToUse popupDecoratorToUse = EnumPopupDecoratorToUse.Default)
                {
                    this.Text = text;
                    this.Title = title;
                    this.LifeTime = lifetime;
                    this.Hint = hint;
                    this.QueuedOn = DateTime.Now;
                    this.PopUpDecoratorTouse = popupDecoratorToUse;
                }
            }
    
    
            public void Show(string text, string title, int duration, string hint = null, EnumPopupDecoratorToUse popupDecoratorToUse = EnumPopupDecoratorToUse.Default)
            {
                Hud.Queue.AddItem(new Popup(text, title, new TimeSpan(0, 0, 0, 0, duration), hint, popupDecoratorToUse));
            }
    
            public PopupNotifications()
            {
                Enabled = true;
            }
    
            public override void Load(IController hud)
            {
                base.Load(hud);
    
                PrimalPopupDecorator = new TopLabelWithTitleDecorator(Hud)
                {
                    BorderBrush = Hud.Render.CreateBrush(255, 255, 0, 0, -1),
               
                    BackgroundBrush = Hud.Render.CreateBrush(200, 0, 0, 0, 0),
                    TextFont = Hud.Render.CreateFont("tahoma", 8, 255, 255, 255, 255, true, false, false),
                    TitleFont = Hud.Render.CreateFont("tahoma", 6, 255, 180, 147, 109, true, false, false),
                };
    
                AcientPopupDecorator = new TopLabelWithTitleDecorator(Hud)
                {
                    BorderBrush = Hud.Render.CreateBrush(255, 255, 165, 0, -1),
    
                    BackgroundBrush = Hud.Render.CreateBrush(200, 0, 0, 0, 0),
                    TextFont = Hud.Render.CreateFont("tahoma", 8, 255, 255, 255, 255, true, false, false),
                    TitleFont = Hud.Render.CreateFont("tahoma", 6, 255, 180, 147, 109, true, false, false),
                };
    
                DefaultPopupDecorator = new TopLabelWithTitleDecorator(Hud)
                {
                    BorderBrush = Hud.Render.CreateBrush(255, 180, 147, 109, -1),
    
                    BackgroundBrush = Hud.Render.CreateBrush(200, 0, 0, 0, 0),
                    TextFont = Hud.Render.CreateFont("tahoma", 8, 255, 255, 255, 255, true, false, false),
                    TitleFont = Hud.Render.CreateFont("tahoma", 6, 255, 180, 147, 109, true, false, false),
                };
    
                RatioX = 0.6f;
                RatioY = 0.75f;
                RatioW = 0.18f;
                RatioH = 0.05f;
                VerticalGap = 1.20f;
            }
    
            public void PaintWorld(WorldLayer layer)
            {
                var w = Hud.Window.Size.Height * RatioW;
                var h = Hud.Window.Size.Height * RatioH;
                var x = Hud.Window.Size.Width * RatioX;
                var y = Hud.Window.Size.Height * RatioY;
    
                foreach (Popup p in Hud.Queue.GetItems<Popup>().Take(13))
                {
                    switch (p.PopUpDecoratorTouse)
                    {
                        case EnumPopupDecoratorToUse.Ancient:
                            AcientPopupDecorator.Paint(x, y, w, h, p.Text, p.Title, p.Hint);
                            break;
                        case EnumPopupDecoratorToUse.Primal:
                            PrimalPopupDecorator.Paint(x, y, w, h, p.Text, p.Title, p.Hint);
                            break;
    
                        case EnumPopupDecoratorToUse.Default:
                        default:
                            DefaultPopupDecorator.Paint(x, y, w, h, p.Text, p.Title, p.Hint);
                            break;
    
                    }
                    
                    y -= h * VerticalGap;
                }
            }
    
    
        }
    
    }

    LegendaryDroppedPopupPopup.cs:
    Code:
    using Turbo.Plugins.Default;
    
    namespace Turbo.Plugins.Prrovoss
    {
    
        public class LegendaryDroppedPopupPopup : BasePlugin, ILootGeneratedHandler
        {
    
            public void OnLootGenerated(IItem item, bool gambled)
            {
                if (item.AncientRank == 2)
                    Hud.RunOnPlugin<PopupNotifications>(plugin =>
                    {
                        plugin.Show(item.SnoItem.NameLocalized + " (P)", "Primal dropped", 10000, "Hurray", PopupNotifications.EnumPopupDecoratorToUse.Primal);
                    });
    
                else if (item.AncientRank == 1)
                    Hud.RunOnPlugin<PopupNotifications>(plugin =>
                    {
                        plugin.Show(item.SnoItem.NameLocalized + " (A)", "Ancient dropped", 10000, "Hurray", PopupNotifications.EnumPopupDecoratorToUse.Ancient);
                    });
    
                else if (item.Quality == ItemQuality.Legendary)
                    Hud.RunOnPlugin<PopupNotifications>(plugin =>
                        {
                            plugin.Show(item.SnoItem.NameLocalized, "Legendary dropped", 10000, "Hurray");
                        });
    
                
    
                
            }
    
            public LegendaryDroppedPopupPopup()
            {
                Enabled = true;
            }
    
        }
    
    }
    Last edited by xviperousx; 08-11-2017 at 05:03 AM. Reason: if cases in wrong order

    [ENGLISH] [Prrovoss] PopupNotifications
  2. #17
    Magic1's Avatar Member
    Reputation
    1
    Join Date
    Aug 2017
    Posts
    1
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Can this notification framework be applied to monsters too? I'm thinking specifically of "Sir William" (Sir William | Diablo Wiki | FANDOM powered by Wikia) of Whimseyshire and "Princess Lillian" (Princess Lilian | Diablo Wiki | FANDOM powered by Wikia) of Whimseydale.

  3. #18
    DJS's Avatar Member
    Reputation
    4
    Join Date
    Mar 2017
    Posts
    39
    Thanks G/R
    6/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Due to very fast Speedrifting (Rathma) and only very short breaks, it is great, now Primals are announced.

    I wonder if and how it is possible to detect this events:
    - appearing channeling pylon
    - the moment when somebody take channeling
    - same for shield pylon
    - when the dying passive procs (Final Service)
    All informations are already on display but in this speed action it would for me helpful to become a popup.

    - and it may sound ridiculous but a popup if somebody is whispering
    There are so many chats and after some hours of action i discovered in battle.net who al whisperes to me and i haven't seen it live.

    Thanx for this great plugin

  4. #19
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Magic1 View Post
    Can this notification framework be applied to monsters too? I'm thinking specifically of "Sir William" (Sir William | Diablo Wiki | FANDOM powered by Wikia) of Whimseyshire and "Princess Lillian" (Princess Lilian | Diablo Wiki | FANDOM powered by Wikia) of Whimseydale.
    Originally Posted by DJS View Post
    Due to very fast Speedrifting (Rathma) and only very short breaks, it is great, now Primals are announced.

    I wonder if and how it is possible to detect this events:
    - appearing channeling pylon
    - the moment when somebody take channeling
    - same for shield pylon
    - when the dying passive procs (Final Service)
    All informations are already on display but in this speed action it would for me helpful to become a popup.

    - and it may sound ridiculous but a popup if somebody is whispering
    There are so many chats and after some hours of action i discovered in battle.net who al whisperes to me and i haven't seen it live.

    Thanx for this great plugin
    Both are implemented and can be found in the original post.
    the only thing that is not possible is the chat message recognition, thud does not provide any data about that (as far as i know)

    make sure to read the note:
    NOTE: If you have used the plugin before, make sure your files are located in the subfolder "Popups". Ive changed their location so you might have to move the existing files!

  5. Thanks DJS (1 members gave Thanks to prrovoss for this useful post)
  6. #20
    HugeTorque's Avatar Member
    Reputation
    1
    Join Date
    Sep 2017
    Posts
    5
    Thanks G/R
    4/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I would also only like ancient or primal notifications.
    I tried this method of creating a file called "AcientDroppedPopupPopup.cs" in the Popups folder but I got exceptions. Can someone please help?
    Last edited by HugeTorque; 09-30-2017 at 11:14 AM.

  7. #21
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I cant read your mind, what exceptions?

  8. #22
    HugeTorque's Avatar Member
    Reputation
    1
    Join Date
    Sep 2017
    Posts
    5
    Thanks G/R
    4/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by prrovoss View Post
    I cant read your mind, what exceptions?
    2017.09.30 11:44:54.916 error while initializing plugins
    2017.09.30 11:44:54.920 c:\TurboHUD 17.9.1.0 (v7.3) x64\plugins\Prrovoss\Popups\AcientDroppedPopupPopup.cs(12,33) : error CS0246: The type or namespace name 'PopupNotifications' could not be found (are you missing a using directive or an assembly reference?)
    2017.09.30 11:47:44.959 error while initializing plugins
    2017.09.30 11:47:44.962 c:\TurboHUD 17.9.1.0 (v7.3) x64\plugins\Prrovoss\Popups\AcientDroppedPopupPopup.cs(12,33) : error CS0246: The type or namespace name 'PopupNotifications' could not be found (are you missing a using directive or an assembly reference?)
    2017.09.30 22:39:05.350 namespace mismatch in plugin file: 'C:\TurboHUD 17.9.1.0 (v7.3) x64\Plugins\Prrovoss\Popups\AcientDroppedPopupPopup.cs': namespace should be this: 'Turbo.Plugins.Prrovoss
    2017.09.30 22:40:07.601 namespace mismatch in plugin file: 'C:\TurboHUD 17.9.1.0 (v7.3) x64\Plugins\Prrovoss\Popups\AcientDroppedPopupPopup.cs': namespace should be this: 'Turbo.Plugins.Prrovoss

  9. #23
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hm. and you got the PopupNotifications.cs in the same folder?
    are you sure that you are using the namespace correctly in your new file? "namespace Turbo.Plugins.Prrovoss.Popups"

  10. #24
    einsteinz's Avatar Member
    Reputation
    1
    Join Date
    Mar 2017
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I got weird sound since tonight with BuffAppliedPopup since new update.So far only with archon teleport.

  11. #25
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by einsteinz View Post
    I got weird sound since tonight with BuffAppliedPopup since new update.So far only with archon teleport.
    related to this?
    What are the beeps?

  12. #26
    einsteinz's Avatar Member
    Reputation
    1
    Join Date
    Mar 2017
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by prrovoss View Post
    related to this?
    What are the beeps?
    great thanks !

  13. #27
    FullmetalEnvy's Avatar Member CoreCoins Purchaser
    Reputation
    8
    Join Date
    Mar 2017
    Posts
    21
    Thanks G/R
    16/7
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by xviperousx View Post
    Hi there

    i love this plugin, so i can share you the solution.

    Simply put following quote into the file "AcientDroppedPopupPopup.cs":

    Code:
    using Turbo.Plugins.Default;
    
    namespace Turbo.Plugins.Prrovoss
    {
    
        public class AcientDroppedPopup : BasePlugin, ILootGeneratedHandler
        {
    
            public void OnLootGenerated(IItem item, bool gambled)
            {
               if (item.AncientRank >= 1)
                    Hud.RunOnPlugin<PopupNotifications>(plugin =>
                        {
                            plugin.Show(item.SnoItem.NameLocalized + (item.AncientRank == 1 ? " (A)" : (item.AncientRank == 2 ? " (P)" : "")) , "Acient dropped", 10000, "Hurray");
                        });
            }
    
            public AcientDroppedPopup()
            {
                Enabled = true;
            }
    
        }
    
    }
    Hey, thanks for the reply, but I'm getting this exception: \plugins\Prrovoss\Popups\AcientDroppedPopup.cs(12,33) : error CS0246: The type or namespace name 'PopupNotifications' could not be found
    Don't Envy the Lust and Greed that Gluttony has for eating things. Be careful about your Pride, because it can drag your Sloth to Wrath.

  14. #28
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    well did you download the PopupNotifications.cs and put it into the same folder?

  15. #29
    FullmetalEnvy's Avatar Member CoreCoins Purchaser
    Reputation
    8
    Join Date
    Mar 2017
    Posts
    21
    Thanks G/R
    16/7
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by prrovoss View Post
    well did you download the PopupNotifications.cs and put it into the same folder?
    Ofc
    [ENGLISH] [Prrovoss] PopupNotifications-ofc-i-did-png
    Don't Envy the Lust and Greed that Gluttony has for eating things. Be careful about your Pride, because it can drag your Sloth to Wrath.

  16. #30
    prrovoss's Avatar Contributor
    Reputation
    152
    Join Date
    Jan 2013
    Posts
    420
    Thanks G/R
    23/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    oh yeah i think now i see it^^
    in the quote you used, the third line should look like this: namespace Turbo.Plugins.Prrovoss.Popups
    the one you used was from before i moved the popups into a subfolder.

  17. Thanks FullmetalEnvy (1 members gave Thanks to prrovoss for this useful post)
Page 2 of 5 FirstFirst 12345 LastLast

Similar Threads

  1. English --> Chinese
    By Login Error in forum Community Chat
    Replies: 4
    Last Post: 02-04-2008, 07:00 PM
  2. [Guide] Proper English Language
    By aggiish in forum Community Chat
    Replies: 31
    Last Post: 02-04-2008, 02:29 PM
  3. Omg,Funniest Thing I ever saw!!! ENGLISH PWNED!!!!
    By anmer in forum Screenshot & Video Showoff
    Replies: 10
    Last Post: 11-12-2007, 10:15 AM
  4. Chinese Names in English WoW
    By pandaman in forum World of Warcraft Exploits
    Replies: 8
    Last Post: 08-12-2006, 05:40 AM
All times are GMT -5. The time now is 07:14 PM. 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