C# Класс WaveOculusDemoProject.Components.AsteroidFieldController

Наследование: Behavior
Показать файл Открыть проект

Открытые методы

Метод Описание
AsteroidFieldController ( System.Vector3 sectorSize ) : System

Instantiates a new Asteroid field controller, with the size of one asteroid sector.

GetPositionByCoordinates ( int sectorX, int sectorY ) : System.Vector3

Gets sector position by its coordinates

GetSector ( System.Vector3 position, int &sectorX, int &sectorY ) : void

Gets asteroid coordinates by a world position

GetSectorTypeByCoords ( int sectorX, int sectorY ) : int

Gets sector type by its coordinates

Защищенные методы

Метод Описание
Initialize ( ) : void

Initializes the asteroid field controller

Update ( System.TimeSpan gameTime ) : void

Update the asteroid field. If the player camera moves to a different sector, this controller must place each asteroids sectors in its correct place.

Приватные методы

Метод Описание
CleanSectorList ( ) : void

Clean the asteroid sector list.

GetFreeSteroidSector ( int sectorType, int lod ) : AsteroidSectorDecorator

Get a free asteroid sector.

Refresh ( ) : void

Refresh the asteroid field.

Описание методов

AsteroidFieldController() публичный Метод

Instantiates a new Asteroid field controller, with the size of one asteroid sector.
public AsteroidFieldController ( System.Vector3 sectorSize ) : System
sectorSize System.Vector3 The size of one asteroid sector
Результат System

GetPositionByCoordinates() публичный Метод

Gets sector position by its coordinates
public GetPositionByCoordinates ( int sectorX, int sectorY ) : System.Vector3
sectorX int X coord.
sectorY int Y coord.
Результат System.Vector3

GetSector() публичный Метод

Gets asteroid coordinates by a world position
public GetSector ( System.Vector3 position, int &sectorX, int &sectorY ) : void
position System.Vector3 Position in world space
sectorX int X coord.
sectorY int Y coord.
Результат void

GetSectorTypeByCoords() публичный Метод

Gets sector type by its coordinates
public GetSectorTypeByCoords ( int sectorX, int sectorY ) : int
sectorX int X coord.
sectorY int Y coord.
Результат int

Initialize() защищенный Метод

Initializes the asteroid field controller
protected Initialize ( ) : void
Результат void

Update() защищенный Метод

Update the asteroid field. If the player camera moves to a different sector, this controller must place each asteroids sectors in its correct place.
protected Update ( System.TimeSpan gameTime ) : void
gameTime System.TimeSpan
Результат void