Angel
A 2D Game Prototyping Engine
Public Member Functions
HUDActor Class Reference

An Actor that gets drawn in screen-space. More...

#include <HUDActor.h>

+ Inheritance diagram for HUDActor:

List of all members.

Public Member Functions

virtual void Render ()
virtual const String GetClassName ()

Detailed Description

A HUDActor is drawn in screen-space rather than world-space. You can treat it just like any other normal Actor, but both its position and size are described in pixels instead of GL units. The screenspace coordinate system starts at the top-left of the window.

For example, to have an actor be 100 pixels wide and situated in the bottom-right quadrant of the window (assuming the default window size of 1024x768):

 HUDActor *h = new HUDActor();
 h->SetSize(100.0f);
 h->SetPosition(974.0f, 718.0f);
 theWorld.Add(h);

Definition at line 51 of file HUDActor.h.


Member Function Documentation

void HUDActor::Render ( ) [virtual]

Override of the Renderable::Render function to handle drawing in screen-space.

Reimplemented from Actor.

Definition at line 38 of file HUDActor.cpp.

virtual const String HUDActor::GetClassName ( ) [inline, virtual]

Used by the SetName function to create a basename for this class. Overridden from Actor::GetClassName.

Returns:
The string "HUDActor"

Reimplemented from Actor.

Definition at line 66 of file HUDActor.h.


The documentation for this class was generated from the following files: