C# 클래스 AStarCollisionMap.QuadTree.CollisionTexture

파일 보기 프로젝트 열기: Wotuu/RTS_XNA_v2

Private Properties

프로퍼티 타입 설명
UpdateTexture void

공개 메소드들

메소드 설명
CollisionAt ( int i ) : System.Boolean

Checks whether there is collision at a certain point.

CollisionTexture ( Quad quad, Microsoft.Xna.Framework.Graphics.Texture2D texture ) : System
PointToIndex ( int x, int y ) : int

Returns the index of a certain point.

SetCollisionAt ( int i, System.Boolean value ) : void

Sets collision data at this point.

TextureToBoolean ( ) : System.Boolean[]

Converts a texture to a boolean array

UpdateCollision ( Rectangle rect, System.Boolean add ) : void

Updates the collision of this texture, and update the texture as well.

비공개 메소드들

메소드 설명
UpdateTexture ( ) : void

Updates the texture of this collisiontexture.

메소드 상세

CollisionAt() 공개 메소드

Checks whether there is collision at a certain point.
public CollisionAt ( int i ) : System.Boolean
i int The index of the point to check at. Note that the index has to fall within /// the bounds of this texture, i.e., it's only as large as this.rectangle.Width * this.rectangle.Height.
리턴 System.Boolean

CollisionTexture() 공개 메소드

public CollisionTexture ( Quad quad, Microsoft.Xna.Framework.Graphics.Texture2D texture ) : System
quad Quad
texture Microsoft.Xna.Framework.Graphics.Texture2D
리턴 System

PointToIndex() 공개 메소드

Returns the index of a certain point.
public PointToIndex ( int x, int y ) : int
x int
y int
리턴 int

SetCollisionAt() 공개 메소드

Sets collision data at this point.
public SetCollisionAt ( int i, System.Boolean value ) : void
i int The point to put it at.
value System.Boolean The value to place it at.
리턴 void

TextureToBoolean() 공개 메소드

Converts a texture to a boolean array
public TextureToBoolean ( ) : System.Boolean[]
리턴 System.Boolean[]

UpdateCollision() 공개 메소드

Updates the collision of this texture, and update the texture as well.
public UpdateCollision ( Rectangle rect, System.Boolean add ) : void
rect Microsoft.Xna.Framework.Rectangle The rectangle that is to be updated.
add System.Boolean Whether to add or remove the rectangle.
리턴 void