#include <src/orxonox/objects/worldentities/pawns/Spectator.h>
Public Member Functions | |
virtual void | fire (unsigned int firemode) |
virtual void | greet () |
virtual void | moveFrontBack (const Vector2 &value) |
virtual void | moveRightLeft (const Vector2 &value) |
virtual void | moveUpDown (const Vector2 &value) |
void | registerVariables () |
virtual void | rotatePitch (const Vector2 &value) |
virtual void | rotateRoll (const Vector2 &value) |
virtual void | rotateYaw (const Vector2 &value) |
void | setConfigValues () |
Function to collect the SetConfigValue-macro calls. | |
Spectator (BaseObject *creator) | |
virtual void | tick (float dt) |
Gets called every frame. | |
virtual | ~Spectator () |
Protected Member Functions | |
virtual void | setPlayer (PlayerInfo *player) |
virtual void | startLocalHumanControl () |
Private Member Functions | |
void | changedFlareVisibility () |
void | changedGreeting () |
Private Attributes | |
bool | bGreeting_ |
bool | bGreetingFlareVisible_ |
BillboardSet * | greetingFlare_ |
Vector3 | localVelocity_ |
float | pitch_ |
float | roll_ |
float | speed_ |
float | yaw_ |
orxonox::Spectator::Spectator | ( | BaseObject * | creator | ) |
References orxonox::WorldEntity::attachOgreObject(), bGreeting_, bGreetingFlareVisible_, orxonox::MT_Type::ColourValue, orxonox::BillboardSet::getBillboardSet(), orxonox::BaseObject::getScene(), greetingFlare_, localVelocity_, pitch_, RegisterObject, registerVariables(), roll_, orxonox::BillboardSet::setBillboardSet(), setConfigValues(), orxonox::ControllableEntity::setDestroyWhenPlayerLeft(), orxonox::ControllableEntity::setHudTemplate(), orxonox::BillboardSet::setVisible(), orxonox::GameMode::showsGraphics(), speed_, orxonox::MT_Type::Vector3, and yaw_.
orxonox::Spectator::~Spectator | ( | ) | [virtual] |
void orxonox::Spectator::changedFlareVisibility | ( | ) | [private] |
References bGreetingFlareVisible_, greetingFlare_, and orxonox::BillboardSet::setVisible().
Referenced by changedGreeting(), greet(), and registerVariables().
void orxonox::Spectator::changedGreeting | ( | ) | [private] |
References bGreeting_, bGreetingFlareVisible_, and changedFlareVisibility().
Referenced by registerVariables().
void orxonox::Spectator::fire | ( | unsigned int | firemode | ) | [virtual] |
Reimplemented from orxonox::ControllableEntity.
References orxonox::ControllableEntity::getPlayer(), and orxonox::PlayerInfo::setReadyToSpawn().
void orxonox::Spectator::greet | ( | ) | [virtual] |
Reimplemented from orxonox::ControllableEntity.
References bGreeting_, bGreetingFlareVisible_, changedFlareVisibility(), and orxonox::GameMode::isMaster().
void orxonox::Spectator::moveFrontBack | ( | const Vector2 & | value | ) | [virtual] |
void orxonox::Spectator::moveRightLeft | ( | const Vector2 & | value | ) | [virtual] |
void orxonox::Spectator::moveUpDown | ( | const Vector2 & | value | ) | [virtual] |
void orxonox::Spectator::registerVariables | ( | ) |
Reimplemented from orxonox::ControllableEntity.
References bGreeting_, bGreetingFlareVisible_, changedFlareVisibility(), changedGreeting(), orxonox::Synchronisable::registerVariable(), orxonox::VariableDirection::ToClient, and orxonox::VariableDirection::ToServer.
Referenced by Spectator().
void orxonox::Spectator::rotatePitch | ( | const Vector2 & | value | ) | [virtual] |
Reimplemented from orxonox::ControllableEntity.
References pitch_, and orxonox::ControllableEntity::rotatePitch().
void orxonox::Spectator::rotateRoll | ( | const Vector2 & | value | ) | [virtual] |
Reimplemented from orxonox::ControllableEntity.
References roll_, and orxonox::ControllableEntity::rotateRoll().
void orxonox::Spectator::rotateYaw | ( | const Vector2 & | value | ) | [virtual] |
Reimplemented from orxonox::ControllableEntity.
References orxonox::ControllableEntity::rotateYaw(), and yaw_.
void orxonox::Spectator::setConfigValues | ( | ) |
Function to collect the SetConfigValue-macro calls.
Reimplemented from orxonox::ControllableEntity.
References SetConfigValue, and speed_.
Referenced by Spectator().
void orxonox::Spectator::setPlayer | ( | PlayerInfo * | player | ) | [protected, virtual] |
Reimplemented from orxonox::ControllableEntity.
References orxonox::ControllableEntity::setPlayer().
void orxonox::Spectator::startLocalHumanControl | ( | ) | [protected, virtual] |
Reimplemented from orxonox::ControllableEntity.
References orxonox::ControllableEntity::startLocalHumanControl().
void orxonox::Spectator::tick | ( | float | dt | ) | [virtual] |
Gets called every frame.
dt | The time since the last frame in seconds |
Reimplemented from orxonox::ControllableEntity.
References orxonox::ControllableEntity::getMouseLookSpeed(), orxonox::WorldEntity::getOrientation(), orxonox::ControllableEntity::hasLocalController(), orxonox::ControllableEntity::isInMouseLook(), localVelocity_, orxonox::WorldEntity::pitch(), pitch_, orxonox::MT_Type::Radian, orxonox::WorldEntity::roll(), roll_, orxonox::ControllableEntity::setVelocity(), speed_, SUPER, orxonox::WorldEntity::yaw(), and yaw_.
bool orxonox::Spectator::bGreeting_ [private] |
Referenced by changedGreeting(), greet(), registerVariables(), and Spectator().
bool orxonox::Spectator::bGreetingFlareVisible_ [private] |
Referenced by changedFlareVisibility(), changedGreeting(), greet(), registerVariables(), and Spectator().
BillboardSet* orxonox::Spectator::greetingFlare_ [private] |
Referenced by changedFlareVisibility(), Spectator(), and ~Spectator().
Vector3 orxonox::Spectator::localVelocity_ [private] |
Referenced by moveFrontBack(), moveRightLeft(), moveUpDown(), Spectator(), and tick().
float orxonox::Spectator::pitch_ [private] |
Referenced by rotatePitch(), Spectator(), and tick().
float orxonox::Spectator::roll_ [private] |
Referenced by rotateRoll(), Spectator(), and tick().
float orxonox::Spectator::speed_ [private] |
Referenced by setConfigValues(), Spectator(), and tick().
float orxonox::Spectator::yaw_ [private] |
Referenced by rotateYaw(), Spectator(), and tick().