C# 클래스 ByChance.Core.ChunkTemplate

Template that is used for creating similar chunks, which in turn make up a level. Chunk templates define the positions of all contexts and anchors of chunks, as well as attributes that are required for the level generation process such as the probability of a chunk being picked to be added next.
파일 보기 프로젝트 열기: npruehs/bychance 1 사용 예제들

공개 메소드들

메소드 설명
GetAnchor ( int index ) : Anchor

Gets the anchor with the specified template-wide unique index.

GetContext ( int index ) : Context

Gets the context with the specified template-wide unique index.

보호된 메소드들

메소드 설명
ChunkTemplate ( int weight, string tag, bool allowChunkRotation ) : System

Constructs a new chunk template with the specified weight, category and rotation permission.

메소드 상세

ChunkTemplate() 보호된 메소드

Constructs a new chunk template with the specified weight, category and rotation permission.
is less then or equal to zero. is null.
protected ChunkTemplate ( int weight, string tag, bool allowChunkRotation ) : System
weight int Relative weight of the new chunk template.
tag string Category of the new chunk template.
allowChunkRotation bool Whether the level generator is allowed to rotate chunks created with the template by 90°, or not.
리턴 System

GetAnchor() 공개 메소드

Gets the anchor with the specified template-wide unique index.
public GetAnchor ( int index ) : Anchor
index int Index of the anchor to get.
리턴 Anchor

GetContext() 공개 메소드

Gets the context with the specified template-wide unique index.
public GetContext ( int index ) : Context
index int Index of the context to get.
리턴 Context