Snippet Collection Thread menu

User Tag List

Page 1 of 2 12 LastLast
Results 1 to 15 of 16
  1. #1
    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)

    Snippet Collection Thread

    This is a collection thread for all THUD code snippets that don't qualify as complete plugins.

    If you want to use a snippet from this thread but have no idea about how to actually make it work, read through this Guide (third section):
    Default theme customization 101

    Post your snippets in [code] tags and a short description of what the snippet does.

    DO NOT post anything else than snippets in here!

    If you have questions or problems with a specific snippet you found in here, head over to this thread and post it there:
    Snippet Collection Discussion

    Snippet Collection Thread
  2. Thanks RealGsus, bobbydigital12, cherouvim13, sorv (4 members gave Thanks to prrovoss for this useful post)
  3. #2
    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)
    Disable all plugins:
    Code:
                foreach (IPlugin plugin in Hud.AllPlugins)
                {
                    plugin.Enabled = false;
                }

    Add some (mainly raekor) barbarian and (mainly tal/vyr) wizard buffs to the BuffList below your character:
    Code:
                var feetBuffs = Hud.GetPlugin<PlayerBottomBuffListPlugin>().RuleCalculator.Rules;
    
    
                if (feetBuffs != null)
                {
                    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
    
                }

    Add map labels for dropped legendary and set items:

    Code:
    Hud.RunOnPlugin<ItemsPlugin>(plugin =>
    
                {
    
                    plugin.LegendaryDecorator.Decorators.Add(new MapLabelDecorator(Hud)
    
                    {
                        LabelFont = Hud.Render.CreateFont("tahoma", 6, 255, 235, 120, 0, false, false, false),
                        RadiusOffset = 14,
                        Up = true,
                    });
    
                    plugin.SetDecorator.Decorators.Add(new MapLabelDecorator(Hud)
                    {
    
                        LabelFont = Hud.Render.CreateFont("tahoma", 6, 255, 0, 170, 0, false, false, false),
                        RadiusOffset = 14,
                        Up = true,
                    });
    
    
    
    
                    plugin.AncientDecorator.Decorators.Add(new MapLabelDecorator(Hud)
                    {
                        LabelFont = Hud.Render.CreateFont("tahoma", 6, 255, 235, 120, 0, true, false, false),
                        RadiusOffset = 14,
                        Up = true,
                    });
    
                    plugin.AncientSetDecorator.Decorators.Add(new MapLabelDecorator(Hud)
                    {
    
                        LabelFont = Hud.Render.CreateFont("tahoma", 6, 255, 0, 170, 0, true, false, false),
                        RadiusOffset = 14,
                        Up = true,
                    });
    
    
    
    
                    plugin.PrimalDecorator.Decorators.Add(new MapLabelDecorator(Hud)
                    {
    
                        LabelFont = Hud.Render.CreateFont("tahoma", 7, 255, 240, 20, 0, true, false, false),
                        RadiusOffset = 14,
                        Up = true,
    
                    });
    
    
                    plugin.PrimalSetDecorator.Decorators.Add(new MapLabelDecorator(Hud)
                    {
                        LabelFont = Hud.Render.CreateFont("tahoma", 7, 255, 240, 20, 0, true, false, false),
                        RadiusOffset = 14,
                        Up = true,
                    });
    
                });

    Turn off sell darkening (greying out of items)
    Code:
    Hud.GetPlugin<InventoryAndStashPlugin>().NotGoodDisplayEnabled = false;
    Last edited by prrovoss; 11-20-2017 at 12:29 AM.

  4. Thanks cherouvim13, sorv, Klootviooltje (3 members gave Thanks to prrovoss for this useful post)
  5. #3
    JackCeparou's Avatar Savvy ? 🐒
    Reputation
    534
    Join Date
    Mar 2017
    Posts
    588
    Thanks G/R
    51/490
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Add ground circle for rift/gr progression globes

    PHP Code:
                Hud.RunOnPlugin<GlobePlugin>(plugin =>
                {
                    
    plugin.RiftOrbDecorator.Add(new GroundCircleDecorator(Hud)
                    {
                        
    Brush Hud.Render.CreateBrush(2552401202403),
                        
    Radius 1.5f
                    
    });
                }); 
    Add ground circle for Death Breaths :

    PHP Code:
                Hud.RunOnPlugin<ItemsPlugin>(plugin =>
                {
                    
    plugin.DeathsBreathDecorator.Add(new GroundCircleDecorator(Hud)
                    {
                        
    Brush Hud.Render.CreateBrush(192102202177, -2),
                        
    Radius 1.25f,
                    });
                }); 
    Last edited by JackCeparou; 04-05-2017 at 04:01 PM.
    Hide the Rum! --> Default theme customization 101 <--

  6. Thanks prrovoss (1 members gave Thanks to JackCeparou for this useful post)
  7. #4
    JackCeparou's Avatar Savvy ? 🐒
    Reputation
    534
    Join Date
    Mar 2017
    Posts
    588
    Thanks G/R
    51/490
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Display countdown for Arcane beams :



    PHP Code:
                Hud.RunOnPlugin<EliteMonsterSkillPlugin>(plugin =>
                {
                    
    plugin.ArcaneDecorator.Add(new GroundLabelDecorator(Hud)
                    {
                        
    CountDownFrom 10,
                        
    TextFont Hud.Render.CreateFont("tahoma"9255255255255truefalse128000true),
                    });
                    
    plugin.ArcaneDecorator.Add(new GroundTimerDecorator(Hud)
                    {
                        
    CountDownFrom 10,
                        
    BackgroundBrushEmpty Hud.Render.CreateBrush(1280000),
                        
    BackgroundBrushFill Hud.Render.CreateBrush(200255322550),
                        
    Radius 30,
                    });
                }); 
    Hide the Rum! --> Default theme customization 101 <--

  8. Thanks cherouvim13 (1 members gave Thanks to JackCeparou for this useful post)
  9. #5
    coreyblack's Avatar Active Member
    Reputation
    35
    Join Date
    Oct 2009
    Posts
    35
    Thanks G/R
    9/33
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)


    This helps You not to lose discipline when vaulting

    PHP Code:
     // Default PLUGIN CUSTOMIZATION: PlayerTopBuffListPlugin
                
    Hud.RunOnPlugin<PlayerTopBuffListPlugin>(plugin => {
                    
                    
    plugin.PositionOffset = -0.20f;
        

                    
    plugin.BuffPainter = new BuffPainter(Hudtrue)
                    {
                    
    Opacity 1.00f,
                    
    ShowTimeLeftNumbers true,
                    
    ShowTooltips false,
                    
                    
    TimeLeftFont Hud.Render.CreateFont("tahoma"15255255255255falsefalse255000true), // 12 size default Timeleft font, you can adjust it
                    
    StackFont Hud.Render.CreateFont("tahoma"9255255255255falsefalse255000true), // 9 size default Stacks font, you can adjust it
                    
    };
                    
                    
    plugin.RuleCalculator.SizeMultiplier 1.00f;
                    
                    
    plugin.RuleCalculator.Rules.Add(new BuffRule(445266) { IconIndex nullMinimumIconCount 1ShowStacks falseShowTimeLeft trueDisableName true}); // DemonHunter, After using Impale, Vault costs no resource for 2 seconds.
                
    }); 
    Last edited by coreyblack; 04-25-2017 at 07:04 AM.
    Ukrainian PluginPack for TurboHUD ( https://drive.google.com/open?id=0Bz7ZdWYp_QbuOVVJbHpJUFM5QjQ )

  10. Thanks cherouvim13 (1 members gave Thanks to coreyblack for this useful post)
  11. #6
    gjuz's Avatar Contributor
    Reputation
    121
    Join Date
    Mar 2017
    Posts
    228
    Thanks G/R
    49/118
    Trade Feedback
    0 (0%)
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Note: this is no full plugin!!



    this is a method for Plugins, to indicate if a Monster is "Krysbined"
    - u'll do full Krysbin dmg.

    [C#] isKrysbin - snippet - Pastebin.com

    the return value "2" means, the triple bonus dmg from Krysbin is active for this monster.
    the return value "1" means, the single bonus dmg from Krysbin is active for this monster.
    the return value "0" means, no bonus dmg from Krysbin is active for this monster.


    greetz gjuz
    Last edited by gjuz; 11-30-2017 at 06:29 PM.

  12. Thanks Levithan (1 members gave Thanks to gjuz for this useful post)
  13. #7
    bm206's Avatar Active Member
    Reputation
    73
    Join Date
    Mar 2017
    Posts
    285
    Thanks G/R
    57/64
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by gjuz View Post
    Note: this is no full plugin!!



    this is a method for Plugins, to indicate if a Monster is "Krysbined"
    - u'll do full Krysbin dmg.

    [C#] isKrysbin - snippet - Pastebin.com

    the return value "true" means, the triple bonus dmg from Krysbin is active for this monster.


    greetz gjuz
    A full plugin would be awesome. I think it is only important to show on GRift Boss.

  14. #8
    cherouvim13's Avatar Member
    Reputation
    14
    Join Date
    Mar 2017
    Posts
    212
    Thanks G/R
    258/13
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by gjuz View Post
    Note: this is no full plugin!!



    this is a method for Plugins, to indicate if a Monster is "Krysbined"
    - u'll do full Krysbin dmg.

    [C#] isKrysbin - snippet - Pastebin.com

    the return value "true" means, the triple bonus dmg from Krysbin is active for this monster.


    greetz gjuz
    Where do I place this? PluginEnablerOrDisablerPlugin ?

  15. #9
    gjuz's Avatar Contributor
    Reputation
    121
    Join Date
    Mar 2017
    Posts
    228
    Thanks G/R
    49/118
    Trade Feedback
    0 (0%)
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    this is a method to use in a plugin.

    for example in [ENGLISH] [Gigi] EliteBarPlugin
    (which shows debuffs like locust + haunt for WD)

    or a similar plugin.


    Originally Posted by cherouvim13 View Post
    Where do I place this? PluginEnablerOrDisablerPlugin ?
    No.
    this is no plugin, and no cutomization.
    this is a code snippet to use in a full plugin.

    greetz gjuz
    Last edited by gjuz; 11-08-2017 at 01:27 PM.

  16. #10
    SeaDragon's Avatar Contributor
    Reputation
    321
    Join Date
    Aug 2016
    Posts
    1,041
    Thanks G/R
    140/299
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by gjuz View Post
    this is a method to use in a plugin.

    for example in [ENGLISH] [Gigi] EliteBarPlugin
    (which shows debuffs like locust + haunt for WD)

    or a similar plugin.



    No.
    this is no plugin, and no cutomization.
    this is a code snippet to use in a full plugin.

    greetz gjuz
    I improved some,Used in some of my plugins,Thx

  17. #11
    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)
    Guys, this thread is supposed to be a collection only. if you start discussions in here, its super hard to find the actual snippets.

    Originally Posted by prrovoss View Post
    DO NOT post anything else than snippets in here!

    If you have questions or problems with a specific snippet you found in here, head over to this thread and post it there:
    Snippet Collection Discussion

  18. Thanks JackCeparou, gjuz (2 members gave Thanks to prrovoss for this useful post)
  19. #12
    Noobz's Avatar Member
    Reputation
    6
    Join Date
    Mar 2017
    Posts
    143
    Thanks G/R
    8/5
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Still confused gjuz. I am trying to use the krysbins and can not get it to work. I copy and pasted it into pluginenablerordisablerplugin.cs and got 3 exceptions. The above post makes it sound more like a full plugin or maybe even put it in your other plugin. Please help, too confused.

    Noobz

  20. #13
    coreyblack's Avatar Active Member
    Reputation
    35
    Join Date
    Oct 2009
    Posts
    35
    Thanks G/R
    9/33
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Color modification for OculusPlugin


    PHP Code:
    Hud.RunOnPlugin<OculusPlugin>(plugin => 
                {
                    
    plugin.Decorator.Add(new GroundCircleDecorator(Hud)
                                
                    {
                        
    Brush Hud.Render.CreateBrush(244220970, -2),
                        
    Radius 10.0f,
                    });
    }); 
    Ukrainian PluginPack for TurboHUD ( https://drive.google.com/open?id=0Bz7ZdWYp_QbuOVVJbHpJUFM5QjQ )

  21. #14
    RevoLand's Avatar Member
    Reputation
    12
    Join Date
    Feb 2018
    Posts
    11
    Thanks G/R
    3/6
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not sure if it is shared before but, Goblin names on minimap

    PHP Code:
                Hud.RunOnPlugin<GoblinPlugin>(plugin =>
                {
                    
    plugin.AllGoblinDecorators().ForEach(=> x.Add(new MapLabelDecorator(Hud)
                    {
                        
    LabelFont Hud.Render.CreateFont("tahoma"7f19225525555falsefalse128000true),
                        
    RadiusOffset 5.0f,
                    }));
                }); 

  22. #15
    Xenthalon's Avatar Active Member
    Reputation
    18
    Join Date
    Mar 2017
    Posts
    22
    Thanks G/R
    1/16
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Apparently this information was lost between the forum moves; there is a LineFromMeShapePainter that can draw lines from you to a target on the minimap. Extending the MarkerPlugin in your Customization method like this:

    Code:
    Hud.GetPlugin<MarkerPlugin>().Decorator.Add(new MapShapeDecorator(Hud)
    {
        Brush = Hud.Render.CreateBrush(192, 255, 255, 55, -1),
        ShapePainter = new LineFromMeShapePainter(Hud)
    });
    gives you neat lines to bounty targets, key wardens and rift guardians:



    I'm sure this could be expanded into a full plugin, with different colors etc.

  23. Thanks prrovoss, mumungan, Arkahr, johnbl (4 members gave Thanks to Xenthalon for this useful post)
Page 1 of 2 12 LastLast

Similar Threads

  1. Warlords of Draenor Collection Thread
    By Ehnoah in forum World of Warcraft General
    Replies: 43
    Last Post: 09-06-2014, 08:21 PM
  2. [Animation Swaps] My Animation Swap Collection Thread.
    By PewPewBoom in forum World of Warcraft Model Editing
    Replies: 31
    Last Post: 05-19-2008, 09:12 AM
  3. [Model Changes] Mount collection thread !
    By Mudkip in forum World of Warcraft Model Editing
    Replies: 21
    Last Post: 02-15-2008, 05:10 PM
  4. [Spell Edit] Spell Pack Collection Thread!
    By Aliv3 in forum World of Warcraft Model Editing
    Replies: 15
    Last Post: 12-20-2007, 09:22 AM
  5. [Mac] thread collection
    By hootch in forum World of Warcraft Bots and Programs
    Replies: 9
    Last Post: 12-05-2007, 06:56 PM
All times are GMT -5. The time now is 04:58 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