Skyscraper 2.0
|
#include <light.h>
Public Member Functions | |
Light (Object *parent, const std::string &name, int type) | |
~Light () | |
void | SetColor (Real color_r=1.0f, Real color_g=1.0f, Real color_b=1.0f) |
void | SetSpecularColor (Real color_r=0.0f, Real color_g=0.0f, Real color_b=0.0f) |
void | SetAttenuation (Real att_range=100000.f, Real att_constant=1.f, Real att_linear=0.f, Real att_quadratic=0.f) |
void | SetSpotlightRange (Real spot_inner_angle=30.f, Real spot_outer_angle=40.f, Real spot_falloff=1.f) |
void | SetDirection (const Vector3 &direction) |
void | SetRenderingDistance (Real distance) |
void | Enabled (bool value) |
bool | IsEnabled () |
![]() | |
Object (Object *parent) | |
virtual | ~Object () |
void | SetValues (const std::string &type, const std::string &name, bool is_permanent, bool is_movable=true) |
bool | IsPermanent () |
bool | IsMovable () |
const std::string & | GetType () |
int | GetNumber () |
void | AddChild (Object *object) |
Object * | GetChild (int index) |
int | GetChildrenCount () |
void | RemoveChild (Object *object) |
SceneNode * | GetSceneNode () |
void | ShowBoundingBox (bool value) |
virtual void | Move (const Vector3 &vector, Real speed=1.0) |
virtual void | Move (Real X, Real Y, Real Z, Real speed=1.0) |
virtual void | SetPosition (const Vector3 &position) |
void | SetPositionRelative (const Vector3 &position) |
virtual void | SetPosition (Real X, Real Y, Real Z) |
void | SetPositionRelative (Real X, Real Y, Real Z) |
virtual void | SetPositionY (Real value) |
virtual Vector3 | GetPosition (bool relative=false) |
virtual void | Rotate (const Vector3 &vector, Real speed=1.0) |
virtual void | Rotate (Real X, Real Y, Real Z, Real speed=1.0) |
virtual void | SetRotation (const Vector3 &rotation) |
virtual void | SetRotation (Real X, Real Y, Real Z) |
virtual Vector3 | GetRotation () |
Quaternion | GetOrientation (bool relative=false) |
void | SetOrientation (const Quaternion &q, bool relative=false) |
virtual void | OnMove (bool parent) |
virtual void | OnRotate (bool parent) |
virtual void | OnClick (Vector3 &position, bool shift, bool ctrl, bool alt, bool right) |
virtual void | OnUnclick (bool right) |
virtual void | OnHit () |
void | NotifyMove (bool parent=false) |
void | NotifyRotate (bool parent=false) |
virtual void | ResetState () |
void | ChangeParent (Object *new_parent) |
bool | IsGlobal () |
void | Init (bool children=true) |
virtual void | OnInit () |
virtual void | Loop () |
void | RegisterLoop (Object *object) |
void | UnregisterLoop (Object *object) |
std::string | GetNameBase () |
template<typename T > | |
bool | IsType () |
template<typename T > | |
T * | ConvertTo () |
![]() | |
ObjectBase (Object *parent) | |
virtual | ~ObjectBase () |
Object * | GetParent () |
SBS * | GetRoot () |
void | SetName (const std::string &name) |
const std::string & | GetName () |
std::string | GetNameBase () |
virtual void | Report (const std::string &message) |
virtual bool | ReportError (const std::string &message) |
Public Attributes | |
int | Type |
![]() | |
std::string | command |
std::string | command_processed |
std::string | context |
int | linenum |
std::string | includefile |
bool | parent_deleting |
Private Attributes | |
Ogre::Light * | light |
Additional Inherited Members | |
![]() | |
void | EnableLoop (bool value) |
void | LoopChildren () |
bool | SelfDestruct () |
![]() | |
SBS * | sbs |
SBS::Light::Light | ( | Object * | parent, |
const std::string & | name, | ||
int | type ) |
Definition at line 37 of file light.cpp.
References SBS::SceneNode::AttachObject(), SBS::Object::GetSceneNode(), light, SBS::SBS::mSceneManager, SBS::ObjectBase::Report(), SBS::ObjectBase::ReportError(), SBS::ObjectBase::sbs, SetRenderingDistance(), SBS::Object::SetValues(), Type, and SBS::SBS::Verbose.
SBS::Light::~Light | ( | ) |
Definition at line 80 of file light.cpp.
References SBS::SceneNode::DetachObject(), SBS::SBS::FastDelete, SBS::ObjectBase::GetParent(), SBS::Object::GetSceneNode(), SBS::Object::GetType(), light, SBS::SBS::mSceneManager, SBS::Object::parent_deleting, SBS::SBS::RemoveLight(), and SBS::ObjectBase::sbs.
|
virtual |
Reimplemented from SBS::Object.
Definition at line 136 of file light.cpp.
References light.
Referenced by SBS::ElevatorCar::AddLight(), and SBS::Action::Run().
void SBS::Light::SetAttenuation | ( | Real | att_range = 100000.f, |
Real | att_constant = 1.f, | ||
Real | att_linear = 0.f, | ||
Real | att_quadratic = 0.f ) |
Definition at line 115 of file light.cpp.
References light, SBS::ObjectBase::sbs, and SBS::SBS::ToRemote().
Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().
Definition at line 104 of file light.cpp.
References light.
Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().
void SBS::Light::SetDirection | ( | const Vector3 & | direction | ) |
Definition at line 126 of file light.cpp.
References SBS::Object::GetSceneNode(), and SBS::SceneNode::SetDirection().
Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().
void SBS::Light::SetRenderingDistance | ( | Real | distance | ) |
Definition at line 131 of file light.cpp.
References light, SBS::ObjectBase::sbs, and SBS::SBS::ToRemote().
Referenced by Light().
Definition at line 110 of file light.cpp.
References light.
Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().
void SBS::Light::SetSpotlightRange | ( | Real | spot_inner_angle = 30.f, |
Real | spot_outer_angle = 40.f, | ||
Real | spot_falloff = 1.f ) |
Definition at line 120 of file light.cpp.
Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().
|
private |
Definition at line 49 of file light.h.
Referenced by Enabled(), IsEnabled(), Light(), SetAttenuation(), SetColor(), SetRenderingDistance(), SetSpecularColor(), SetSpotlightRange(), and ~Light().
int SBS::Light::Type |
Definition at line 33 of file light.h.
Referenced by Light(), and SetSpotlightRange().