Advertisement
zjqyf

SpiritBarragePhantasmPlugin.cs

May 7th, 2017
2,514
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.88 KB | None | 0 0
  1. using System.Linq;
  2. using Turbo.Plugins.Default;
  3.  
  4. namespace Turbo.Plugins.glq
  5. {
  6. public class SpiritBarragePhantasmPlugin : BasePlugin, IInGameWorldPainter
  7. {
  8.  
  9. public WorldDecoratorCollection SpiritBarragePhantasmDecorator { get; set; }
  10.  
  11. public SpiritBarragePhantasmPlugin()
  12. {
  13. Enabled = true;
  14. }
  15.  
  16. public override void Load(IController hud)
  17. {
  18. base.Load(hud);
  19. SpiritBarragePhantasmDecorator = new WorldDecoratorCollection(
  20. new GroundCircleDecorator(Hud)
  21. {
  22. Brush = Hud.Render.CreateBrush(255, 0, 128, 255, 2),
  23. Radius = 10,
  24. },
  25. new GroundLabelDecorator(Hud)
  26. {
  27. CountDownFrom = 5,
  28. TextFont = Hud.Render.CreateFont("tahoma", 9, 255, 100, 255, 150, true, false, 128, 0, 0, 0, true),
  29. },
  30. new GroundTimerDecorator(Hud)
  31. {
  32. CountDownFrom = 5,
  33. BackgroundBrushEmpty = Hud.Render.CreateBrush(100, 0, 0, 0, 0),
  34. BackgroundBrushFill = Hud.Render.CreateBrush(200, 0, 128, 255, 0),
  35. Radius = 25,
  36. }
  37. );
  38. }
  39.  
  40. public void PaintWorld(WorldLayer layer)
  41. {
  42. var actors = Hud.Game.Actors;
  43. foreach (var actor in actors)
  44. {
  45. if (actor.SummonerAcdDynamicId == Hud.Game.Me.SummonerId)
  46. {
  47. switch (actor.SnoActor.Sno)
  48. {
  49. case 181880:
  50. SpiritBarragePhantasmDecorator.Paint(layer, actor, actor.FloorCoordinate, null);
  51. break;
  52. }
  53. }
  54. }
  55. }
  56.  
  57. }
  58.  
  59. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement