C# 클래스 Ballz.GameSession.World.Terrain

Represents the Terrain.
파일 보기 프로젝트 열기: SpagAachen/Ballz 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
PublicShape TerrainShape
Scale float
WaterSpawnBitmap ].bool[
decimateOutlines bool
gravityPoint Vector2

공개 메소드들

메소드 설명
AddCircle ( float x, float y, float radius ) : void
ApplyModification ( TerrainModification mod ) : void
BuildTerrainTypeTexture ( ) : void
GetOutline ( bool enforceUpdate = false ) : List>
GetTerrainTypeTexture ( ) : Microsoft.Xna.Framework.Graphics.Texture2D
GetTriangles ( bool enforceUpdate = false ) : List
IsWaterSpawn ( float x, float y ) : bool
Mix ( Vector2 a, Vector2 b, float wa, float wb ) : Vector2
SubtractCircle ( float x, float y, float radius ) : void
Terrain ( Microsoft.Xna.Framework.Graphics.Texture2D terrainTexture ) : Microsoft.Xna.Framework
Update ( ) : void

비공개 메소드들

메소드 설명
DecimateOutline ( List outline ) : void
Distance ( float x1, float y1, float x2, float y2 ) : float
ExtractOutline ( System.Edge edge ) : void
ExtractOutlineFromEdges ( ) : void
ExtractOutlineInternal ( System.Edge edge ) : List
ExtractTrianglesAndOutline ( ) : void
ExtractTrianglesFromCells ( ) : void
PerformMarchingSquares ( ) : void
SmoothTerrain ( float gauss ) : void
UpdateTerrain ( int minY, int minX, int maxX ) : void
area ( Vector2 a, Vector2 b, Vector2 c ) : float

메소드 상세

AddCircle() 공개 메소드

public AddCircle ( float x, float y, float radius ) : void
x float
y float
radius float
리턴 void

ApplyModification() 공개 메소드

public ApplyModification ( TerrainModification mod ) : void
mod TerrainModification
리턴 void

BuildTerrainTypeTexture() 공개 메소드

public BuildTerrainTypeTexture ( ) : void
리턴 void

GetOutline() 공개 메소드

public GetOutline ( bool enforceUpdate = false ) : List>
enforceUpdate bool
리턴 List>

GetTerrainTypeTexture() 공개 메소드

public GetTerrainTypeTexture ( ) : Microsoft.Xna.Framework.Graphics.Texture2D
리턴 Microsoft.Xna.Framework.Graphics.Texture2D

GetTriangles() 공개 메소드

public GetTriangles ( bool enforceUpdate = false ) : List
enforceUpdate bool
리턴 List

IsWaterSpawn() 공개 메소드

public IsWaterSpawn ( float x, float y ) : bool
x float
y float
리턴 bool

Mix() 공개 메소드

public Mix ( Vector2 a, Vector2 b, float wa, float wb ) : Vector2
a Vector2
b Vector2
wa float
wb float
리턴 Vector2

SubtractCircle() 공개 메소드

public SubtractCircle ( float x, float y, float radius ) : void
x float
y float
radius float
리턴 void

Terrain() 공개 메소드

public Terrain ( Microsoft.Xna.Framework.Graphics.Texture2D terrainTexture ) : Microsoft.Xna.Framework
terrainTexture Microsoft.Xna.Framework.Graphics.Texture2D
리턴 Microsoft.Xna.Framework

Update() 공개 메소드

public Update ( ) : void
리턴 void

프로퍼티 상세

PublicShape 공개적으로 프로퍼티

The most recent terrain shape. Will be updated by the background worker once WorkingShape is finished.
Changes can be made to the terrainBitmap of this shape. They will be pulled by the background worker, which will process the changes and write the resulting triangles and outline back to this shape when finished. Use a lock on the publicShape object when accessing it.
public TerrainShape PublicShape
리턴 TerrainShape

Scale 공개적으로 프로퍼티

The world scale of the terrain, in meters per pixel.
public float Scale
리턴 float

WaterSpawnBitmap 공개적으로 프로퍼티

public bool[,] WaterSpawnBitmap
리턴 ].bool[

decimateOutlines 공개적으로 정적으로 프로퍼티

public static bool decimateOutlines
리턴 bool

gravityPoint 공개적으로 프로퍼티

public Vector2 gravityPoint
리턴 Vector2