C# Class WarTornLands.World.Level

Datei anzeigen Open project: floAr/WarTornLands Class Usage Examples

Public Properties

Property Type Description
AreaIndependentEntities List
Ute Entity

Public Methods

Method Description
AddArea ( string name, Area area ) : bool
Clear ( ) : void
Draw ( GameTime gameTime ) : void
GetCurrentAreas ( ) : List
GetEntitiesAt ( Rectangle rect ) : HashSet
GetEntitiesAt ( Vector2 position ) : List
GetEntitiesAt ( Vector2 position, int radius ) : List
IsPositionAccessible ( Vector2 position ) : bool

Queries the Tile Map whether a given pixel position is accessible. Entities are not considered in the collision check. This is done via GetEntitiesAt in the CollisionManager.

IsRectAccessible ( Rectangle rect ) : bool
Level ( ) : System
RemoveArea ( string name ) : bool

Private Methods

Method Description
Update ( GameTime gameTime ) : void

Method Details

AddArea() public method

public AddArea ( string name, Area area ) : bool
name string
area Area
return bool

Clear() public method

public Clear ( ) : void
return void

Draw() public method

public Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
return void

GetCurrentAreas() public method

public GetCurrentAreas ( ) : List
return List

GetEntitiesAt() public method

public GetEntitiesAt ( Rectangle rect ) : HashSet
rect Microsoft.Xna.Framework.Rectangle
return HashSet

GetEntitiesAt() public method

public GetEntitiesAt ( Vector2 position ) : List
position Vector2
return List

GetEntitiesAt() public method

public GetEntitiesAt ( Vector2 position, int radius ) : List
position Vector2
radius int
return List

IsPositionAccessible() public method

Queries the Tile Map whether a given pixel position is accessible. Entities are not considered in the collision check. This is done via GetEntitiesAt in the CollisionManager.
public IsPositionAccessible ( Vector2 position ) : bool
position Vector2 Pixel position to check.
return bool

IsRectAccessible() public method

public IsRectAccessible ( Rectangle rect ) : bool
rect Microsoft.Xna.Framework.Rectangle
return bool

Level() public method

public Level ( ) : System
return System

RemoveArea() public method

public RemoveArea ( string name ) : bool
name string
return bool

Property Details

AreaIndependentEntities public_oe property

public List AreaIndependentEntities
return List

Ute public_oe static_oe property

public static Entity Ute
return Entity