Show / Hide Table of Contents

Class DungeonDrawerBase

Base class for drawing dungeons.

Inheritance
System.Object
DungeonDrawerBase
DungeonDrawer<TRoom>
Namespace: Edgar.GraphBasedGenerator.Grid2D.Drawing
Assembly: Edgar.dll
Syntax
public abstract class DungeonDrawerBase : Object

Constructors

DungeonDrawerBase()

Declaration
protected DungeonDrawerBase()

Fields

bitmap

Declaration
protected Bitmap bitmap
Field Value
Type Description
System.Drawing.Bitmap

graphics

Declaration
protected Graphics graphics
Field Value
Type Description
System.Drawing.Graphics

polygonPartitioning

Declaration
protected readonly CachedPolygonPartitioning polygonPartitioning
Field Value
Type Description
CachedPolygonPartitioning

random

Declaration
protected readonly Random random
Field Value
Type Description
System.Random

Methods

DrawGrid(PolygonGrid2D)

Declaration
protected void DrawGrid(PolygonGrid2D polygon)
Parameters
Type Name Description
PolygonGrid2D polygon

DrawHatching(PolygonGrid2D, List<Tuple<RectangleGrid2D, List<Vector2>>>, Range<Single>, Range<Single>)

Declaration
protected void DrawHatching(PolygonGrid2D outline, List<Tuple<RectangleGrid2D, List<Vector2>>> usedPoints, Range<float> hatchingClusterOffset, Range<float> hatchingLength)
Parameters
Type Name Description
PolygonGrid2D outline
System.Collections.Generic.List<System.Tuple<RectangleGrid2D, System.Collections.Generic.List<Vector2>>> usedPoints
Range<System.Single> hatchingClusterOffset
Range<System.Single> hatchingLength

DrawOutline(PolygonGrid2D, List<DungeonDrawerBase.OutlineSegment>, Pen)

Declaration
protected void DrawOutline(PolygonGrid2D polygon, List<DungeonDrawerBase.OutlineSegment> outlineSegments, Pen outlinePen)
Parameters
Type Name Description
PolygonGrid2D polygon
System.Collections.Generic.List<DungeonDrawerBase.OutlineSegment> outlineSegments
System.Drawing.Pen outlinePen

DrawRoomBackground(PolygonGrid2D, Color)

Declaration
protected void DrawRoomBackground(PolygonGrid2D polygon, Color color)
Parameters
Type Name Description
PolygonGrid2D polygon
System.Drawing.Color color

DrawShading(List<DungeonDrawerBase.OutlineSegment>, Pen)

Declaration
protected void DrawShading(List<DungeonDrawerBase.OutlineSegment> outlineSegments, Pen shadePen)
Parameters
Type Name Description
System.Collections.Generic.List<DungeonDrawerBase.OutlineSegment> outlineSegments
System.Drawing.Pen shadePen

DrawTextOntoPolygon(PolygonGrid2D, String, Single)

Declaration
protected void DrawTextOntoPolygon(PolygonGrid2D polygon, string text, float penWidth)
Parameters
Type Name Description
PolygonGrid2D polygon
System.String text
System.Single penWidth

GetOutline(PolygonGrid2D, List<OrthogonalLineGrid2D>, Vector2Int)

Declaration
protected List<DungeonDrawerBase.OutlineSegment> GetOutline(PolygonGrid2D polygon, List<OrthogonalLineGrid2D> doorLines, Vector2Int offset = null)
Parameters
Type Name Description
PolygonGrid2D polygon
System.Collections.Generic.List<OrthogonalLineGrid2D> doorLines
Vector2Int offset
Returns
Type Description
System.Collections.Generic.List<DungeonDrawerBase.OutlineSegment>
Back to top Generated by DocFX