Advertisement
psychopyro212

Untitled

Mar 28th, 2017
310
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.96 KB | None | 0 0
  1. using Turbo.Plugins.Default;
  2. namespace Turbo.Plugins.Psycho
  3. {
  4.     public class PrimalAncientDecoratorPlugin : BasePlugin, IInGameWorldPainter
  5.     {
  6.         public WorldDecoratorCollection PrimalAncientDecorator { get; set; }
  7.  
  8.         public PrimalAncientDecoratorPlugin()
  9.         {
  10.             Enabled = true;
  11.         }
  12.  
  13.         public override void Load(IController hud)
  14.         {
  15.             base.Load(hud);
  16.        
  17.             PrimalAncientDecorator = new WorldDecoratorCollection(
  18.                 new GroundCircleDecorator(Hud)
  19.                 {
  20.                     Brush = Hud.Render.CreateBrush(192, 255, 140, 0, -3),
  21.                     Radius = 2.2f,
  22.                     RadiusTransformator = new StandardPingRadiusTransformator(Hud, 500),
  23.                 },
  24.                 new GroundLabelDecorator(Hud)
  25.                 {
  26.                     BackgroundBrush = Hud.Render.CreateBrush(160, 255, 140, 0, 0),
  27.                     BorderBrush = Hud.Render.CreateBrush(160, 0, 0, 0, -1),
  28.                     TextFont = Hud.Render.CreateFont("tahoma", 7, 255, 0, 0, 0, true, false, false)
  29.                 },
  30.                 new MapShapeDecorator(Hud)
  31.                 {
  32.                     ShapePainter = new RotatingTriangleShapePainter(Hud),
  33.                     Brush = Hud.Render.CreateBrush(255, 255, 120, 0, 3),
  34.                     ShadowBrush = Hud.Render.CreateBrush(96, 0, 0, 0, 1),
  35.                     Radius = 11,
  36.                     RadiusTransformator = new StandardPingRadiusTransformator(Hud, 333),
  37.                 });
  38.         }
  39.  
  40.         public void PaintWorld(WorldLayer layer)
  41.         {
  42.             var items = Hud.Game.Items;
  43.             foreach (var item in items)
  44.             {
  45.                 var ancientRank = item.AncientRank;
  46.                 if (ancientRank >= 1)
  47.                 {
  48.                     PrimalAncientDecorator.Paint(layer,item,item.FloorCoordinate,string.Empty);
  49.                 }
  50.             }
  51.         }
  52.     }
  53. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement