Skyscraper 2.0
SBS::DoorManager Class Reference

#include <manager.h>

Inheritance diagram for SBS::DoorManager:
Collaboration diagram for SBS::DoorManager:

Public Member Functions

 DoorManager (Object *parent)
 
 ~DoorManager ()
 
DoorAddDoor (std::string name, const std::string &open_sound, const std::string &close_sound, bool open_state, const std::string &texture, const std::string &side_texture, Real thickness, const std::string &face_direction, const std::string &open_direction, bool rotate, Real open_speed, Real close_speed, Real CenterX, Real CenterZ, Real width, Real height, Real voffset, Real tw, Real th, Real side_tw, Real side_th)
 
DoorCreateDoor (std::string name, const std::string &open_sound, const std::string &close_sound, bool rotate)
 
DoorGetDoor (const std::string &name)
 
void RemoveDoor (Door *door)
 
int GetCount ()
 
DoorGetIndex (int index)
 
void Loop ()
 
- Public Member Functions inherited from SBS::Manager
 Manager (Object *parent)
 
virtual ~Manager ()
 
- Public Member Functions inherited from SBS::Object
 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)
 
ObjectGetChild (int index)
 
int GetChildrenCount ()
 
void RemoveChild (Object *object)
 
SceneNodeGetSceneNode ()
 
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 ()
 
void RegisterLoop (Object *object)
 
void UnregisterLoop (Object *object)
 
virtual void Enabled (bool value)
 
std::string GetNameBase ()
 
template<typename T >
bool IsType ()
 
template<typename T >
T * ConvertTo ()
 
- Public Member Functions inherited from SBS::ObjectBase
 ObjectBase (Object *parent)
 
virtual ~ObjectBase ()
 
ObjectGetParent ()
 
SBSGetRoot ()
 
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)
 

Private Attributes

std::vector< Door * > Array
 
DynamicMeshwrapper
 

Additional Inherited Members

- Public Attributes inherited from SBS::Object
std::string command
 
std::string command_processed
 
std::string context
 
int linenum
 
std::string includefile
 
bool parent_deleting
 
- Protected Member Functions inherited from SBS::Object
void EnableLoop (bool value)
 
void LoopChildren ()
 
bool SelfDestruct ()
 
- Protected Attributes inherited from SBS::ObjectBase
SBSsbs
 

Detailed Description

Definition at line 156 of file manager.h.

Constructor & Destructor Documentation

◆ DoorManager()

SBS::DoorManager::DoorManager ( Object * parent)

Definition at line 698 of file manager.cpp.

References SBS::Object::EnableLoop(), SBS::DynamicMesh::force_combine, SBS::Object::GetSceneNode(), SBS::Object::SetValues(), and wrapper.

Here is the call graph for this function:

◆ ~DoorManager()

SBS::DoorManager::~DoorManager ( )

Definition at line 709 of file manager.cpp.

References Array, and wrapper.

Member Function Documentation

◆ AddDoor()

Door * SBS::DoorManager::AddDoor ( std::string name,
const std::string & open_sound,
const std::string & close_sound,
bool open_state,
const std::string & texture,
const std::string & side_texture,
Real thickness,
const std::string & face_direction,
const std::string & open_direction,
bool rotate,
Real open_speed,
Real close_speed,
Real CenterX,
Real CenterZ,
Real width,
Real height,
Real voffset,
Real tw,
Real th,
Real side_tw,
Real side_th )

Definition at line 727 of file manager.cpp.

References Array, SBS::Door::CreateDoor(), SBS::ToString(), and wrapper.

Referenced by SBS::Floor::AddDoor(), and Skyscraper::ScriptProcessor::CommandsSection::Run().

Here is the call graph for this function:

◆ CreateDoor()

Door * SBS::DoorManager::CreateDoor ( std::string name,
const std::string & open_sound,
const std::string & close_sound,
bool rotate )

Definition at line 739 of file manager.cpp.

References Array, SBS::ToString(), and wrapper.

Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().

Here is the call graph for this function:

◆ GetCount()

int SBS::DoorManager::GetCount ( )
virtual

Implements SBS::Manager.

Definition at line 774 of file manager.cpp.

References Array.

◆ GetDoor()

Door * SBS::DoorManager::GetDoor ( const std::string & name)

Definition at line 750 of file manager.cpp.

References Array, and SBS::ObjectBase::GetName().

Referenced by Skyscraper::ScriptProcessor::CommandsSection::Run().

Here is the call graph for this function:

◆ GetIndex()

Door * SBS::DoorManager::GetIndex ( int index)

Definition at line 780 of file manager.cpp.

References Array.

◆ Loop()

void SBS::DoorManager::Loop ( )
virtual

Implements SBS::Manager.

Definition at line 788 of file manager.cpp.

References SBS::Object::LoopChildren(), and SBS_PROFILE.

Here is the call graph for this function:

◆ RemoveDoor()

void SBS::DoorManager::RemoveDoor ( Door * door)

Definition at line 760 of file manager.cpp.

References Array.

Referenced by SBS::Door::~Door().

Member Data Documentation

◆ Array

std::vector<Door*> SBS::DoorManager::Array
private

Definition at line 170 of file manager.h.

Referenced by AddDoor(), CreateDoor(), GetCount(), GetDoor(), GetIndex(), RemoveDoor(), and ~DoorManager().

◆ wrapper

DynamicMesh* SBS::DoorManager::wrapper
private

Definition at line 171 of file manager.h.

Referenced by AddDoor(), CreateDoor(), DoorManager(), and ~DoorManager().


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