Track::StartingPosition Class Reference

The marker where cars start the race from. More...

#include <StartingPosition.h>

Inheritance diagram for Track::StartingPosition:

Track::TrackAttachment Track::UniqueIdentifier Track::Savable List of all members.

Public Member Functions

 StartingPosition (std::istream &source)
 StartingPosition ()
 Create starting position with rank 0.
 StartingPosition (unsigned int rank)
 Create starting position for a rank.
virtual ~StartingPosition ()
virtual std::string get_class_identifier () const
 Return the string used to identify the class.
virtual void draw () const
 Draw the attachment.
virtual void add_data (std::ostream &stream) const
 Write the data needed to reconstruct the object to a stream.
unsigned int get_rank () const
 Return the rank of this starting position.

Protected Attributes

unsigned int m_rank
 rank from 0 of the starting position.

Detailed Description

The marker where cars start the race from.

Definition at line 23 of file StartingPosition.h.


Constructor & Destructor Documentation

Track::StartingPosition::StartingPosition ( std::istream &  source  ) 

Definition at line 29 of file StartingPosition.cpp.

Track::StartingPosition::StartingPosition (  ) 

Create starting position with rank 0.

Definition at line 45 of file StartingPosition.cpp.

Track::StartingPosition::StartingPosition ( unsigned int  rank  ) 

Create starting position for a rank.

Parameters:
rank The starting rank. 0 is first infront of the line.

Definition at line 40 of file StartingPosition.cpp.

Track::StartingPosition::~StartingPosition (  )  [virtual]

Definition at line 50 of file StartingPosition.cpp.


Member Function Documentation

void Track::StartingPosition::add_data ( std::ostream &  stream  )  const [virtual]

Write the data needed to reconstruct the object to a stream.

Reimplemented from Track::TrackAttachment.

Definition at line 62 of file StartingPosition.cpp.

void Track::StartingPosition::draw (  )  const [virtual]

Draw the attachment.

The modelview matrix should be set so that the position using the above and the associated edge is the origin of the modelview matrix.

Reimplemented from Track::TrackAttachment.

Definition at line 54 of file StartingPosition.cpp.

std::string Track::StartingPosition::get_class_identifier (  )  const [virtual]

Return the string used to identify the class.

This is the same string as the associated ClassLoaderBase uses. The return value should be the same for each instance of the class.

Reimplemented from Track::TrackAttachment.

Definition at line 22 of file StartingPosition.cpp.

unsigned int Track::StartingPosition::get_rank (  )  const

Return the rank of this starting position.

Definition at line 68 of file StartingPosition.cpp.


Member Data Documentation

unsigned int Track::StartingPosition::m_rank [protected]

rank from 0 of the starting position.

0 is the rank for the starting position closest to the start line.

Definition at line 50 of file StartingPosition.h.


The documentation for this class was generated from the following files:
Get Racer at SourceForge.net. Fast, secure and Free Open Source software downloads

Generated at Mon Sep 6 00:41:19 2010 by Doxygen version 1.4.7 for Racer version svn335.