Even More Modifiers  1.0.0.0
A mod for rolling various bonus stats on items
ShaderDrawStyle.cs
Go to the documentation of this file.
1 using Loot.Api.Builder;
2 using Microsoft.Xna.Framework.Graphics;
3 
4 namespace Loot.Api.Graphics.Shader.Style
5 {
9  public abstract class ShaderDrawStyle
10  {
12 
13  protected ShaderDrawStyle(ShaderDrawStyleProperties properties = null)
14  {
15  Properties = properties ?? ShaderDrawStyleProperties.Builder.Build();
16  }
17 
18  public abstract void DrawShader(SpriteBatch spriteBatch, ShaderEntity entity);
19 
21  {
23 
24  public int NumSegments { get; set; } = 8;
25  public int DrawDistance { get; set; } = 4;
26 
27  public class ShaderDrawStylePropertiesBuilder : PropertyBuilder<ShaderDrawStyleProperties>
28  {
29  protected override ShaderDrawStyleProperties DefaultProperty
30  {
31  set
32  {
33  Property.NumSegments = value.NumSegments;
34  Property.DrawDistance = value.DrawDistance;
35  }
36  }
37 
39  {
40  Property.NumSegments = num;
41  return this;
42  }
43 
45  {
46  Property.DrawDistance = dist;
47  return this;
48  }
49  }
50  }
51  }
52 }
Defines a shader drawstyle used by ShaderEntity
Defines a Shader entity, part of GraphicsEntity<T> The entity defines a particular &#39;shader&#39; "of" the ...
Definition: ShaderEntity.cs:16
ShaderDrawStyle(ShaderDrawStyleProperties properties=null)
Defines an abstract implementation of IPropertyBuilder<T>