Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Linq;
- using Turbo.Plugins.Default;
- namespace Turbo.Plugins.BM
- {
- public class WormholePlugin : BasePlugin, IInGameWorldPainter
- {
- public WorldDecoratorCollection WormholeDecorator { get; set; }
- public WormholePlugin()
- {
- Enabled = true;
- }
- public override void Load(IController hud)
- {
- base.Load(hud);
- WormholeDecorator = new WorldDecoratorCollection(
- new GroundCircleDecorator(Hud)
- {
- Brush = Hud.Render.CreateBrush(255, 102, 0, 204, -2),
- Radius = 6f,
- },
- new GroundShapeDecorator(hud)
- {
- ShapePainter = WorldStarShapePainter.NewCross(Hud),
- Radius = 6f,
- Brush = Hud.Render.CreateBrush(255, 102, 0, 204, 20),
- },
- new GroundLabelDecorator(Hud)
- {
- CountDownFrom = 6,
- TextFont = Hud.Render.CreateFont("tahoma", 11, 255, 96, 255, 96, true, false, 128, 0, 0, 0, true),
- },
- new GroundTimerDecorator(Hud)
- {
- CountDownFrom = 6,
- BackgroundBrushEmpty = Hud.Render.CreateBrush(128, 0, 0, 0, 0),
- BackgroundBrushFill = Hud.Render.CreateBrush(200, 0, 192, 0, 0),
- Radius = 30,
- }
- );
- }
- public void PaintWorld(WorldLayer layer)
- {
- if (Hud.Game.IsInTown)
- return;
- var wormhole = Hud.Game.Actors.Where(x => x.SnoActor.Sno == ActorSnoEnum._x1_monsteraffix_teleportmines); // 337109
- foreach (var actor in wormhole)
- {
- WormholeDecorator.Paint(layer, actor, actor.FloorCoordinate, string.Empty);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement