C# Класс geek.GameEngine.Visuals.VisualObjectBase

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
IsVisible bool
Position Microsoft.Xna.Framework.Vector2

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

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

Bring the object 1 layer down in the drawing order.

BringToBack ( ) : void

Bring the object to the bottom of current object batch.

BringToFront ( ) : void

Bring the object to the top of current object batch.

BringUp ( ) : void

Bring the object 1 layer up in the drawing order.

Draw ( SpriteBatch batch ) : void

The update screen method.

GetBoundingBox ( bool absolute = false ) : Rectangle

Get a bounding box for the current object.

GetPosition ( bool absolute = false ) : Vector2

Get a position depending on the flag.

Remove ( ) : void

Remove the object from visual list.

ResetLayerId ( ) : void

Reset the layer id to start new drawing loop.

Update ( ) : void

The update logic method.

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

Метод Описание
VisualObjectBase ( ) : System.Collections.Generic

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

Метод Описание
getContainingObjectList ( List &list, int &index ) : bool

Gets the parent VisualObjectBatch's list for further manipulations with layering.

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

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

Bring the object 1 layer down in the drawing order.
public BringDown ( ) : void
Результат void

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

Bring the object to the bottom of current object batch.
public BringToBack ( ) : void
Результат void

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

Bring the object to the top of current object batch.
public BringToFront ( ) : void
Результат void

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

Bring the object 1 layer up in the drawing order.
public BringUp ( ) : void
Результат void

Draw() публичный абстрактный Метод

The update screen method.
public abstract Draw ( SpriteBatch batch ) : void
batch Microsoft.Xna.Framework.Graphics.SpriteBatch SpriteBatch to draw to.
Результат void

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

Get a bounding box for the current object.
public GetBoundingBox ( bool absolute = false ) : Rectangle
absolute bool Absolute or relative coordinates?
Результат Microsoft.Xna.Framework.Rectangle

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

Get a position depending on the flag.
public GetPosition ( bool absolute = false ) : Vector2
absolute bool Absolute or relative position.
Результат Microsoft.Xna.Framework.Vector2

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

Remove the object from visual list.
public Remove ( ) : void
Результат void

ResetLayerId() публичный статический Метод

Reset the layer id to start new drawing loop.
public static ResetLayerId ( ) : void
Результат void

Update() публичный абстрактный Метод

The update logic method.
public abstract Update ( ) : void
Результат void

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

protected VisualObjectBase ( ) : System.Collections.Generic
Результат System.Collections.Generic

Описание свойств

IsVisible публичное свойство

Gets or sets the flag indicating the object is to be displayed.
public bool IsVisible
Результат bool

Position публичное свойство

Visual object position relative to it's parent (scene, batch, etc).
public Vector2,Microsoft.Xna.Framework Position
Результат Microsoft.Xna.Framework.Vector2