23 #ifndef _PSSOUNDSECTOR_H_ 24 #define _PSSOUNDSECTOR_H_ 29 #include <csutil/hash.h> 30 #include <csutil/csstring.h> 31 #include <csgeom/vector3.h> 74 psSoundSector(csRef<iDocumentNode> sectorNode, iObjectRegistry* objectReg);
84 void AddMusic(csRef<iDocumentNode> Node);
154 void SetEntityState(
int state, iMeshWrapper* mesh,
const char* actorName,
bool forceChange);
162 void Load(csRef<iDocumentNode> sectorNode);
163 void Reload(csRef<iDocumentNode> sector);
167 iObjectRegistry* objectReg;
178 psEntity* GetAssociatedEntity(iMeshWrapper* mesh,
const char* meshName)
const;
psMusic * activemusic
active music
psSoundSector(iObjectRegistry *objectReg)
Create an empty psSoundSector with no musics, ambients, emitters and entities.
void UpdateAmbient(int type, SoundControl *&ctrl)
This is a player or another 'alive' entity on the client.
void AddAmbient(csRef< iDocumentNode > Node)
void Reload(csRef< iDocumentNode > sector)
bool active
is this sector active?
void UpdateAllEntities(SoundControl *&ctrl)
Update all entities times, and based on their status generate a sound.
void AddObjectEntity(iMeshWrapper *mesh, const char *meshName)
Adds an object entity to be managed from the sector.
work in progress - Looks like a mishap.
void UpdateAllEmitters(SoundControl *&ctrl)
Start/stops all emitters based on distance and time of the day.
csString name
name of this sector
void AddEmitter(csRef< iDocumentNode > Node)
Adds one emitter from the current array of known emitters.
void UpdateEntity(iMeshWrapper *mesh, const char *meshName, SoundControl *&ctrl)
Updates an object entity managed from the sector.
csArray< psEmitter * > emitterarray
array of emitters
psMusic * activeambient
active ambient music
csArray< psMusic * > ambientarray
array of available ambients
csHash< psEntity *, csString > meshes
hash of mesh entities
This namespace contains a set of functions that are usefull for the processing of music and musical s...
csArray< psMusic * > musicarray
array of available musics
A Volume and Sound control class.
csHash< psEntity *, uint > tempEntities
hash of all the temporary psEntites (i.e. associated to a specific mesh)
void AddEntityDefinition(csRef< iDocumentNode > entityNode)
Loads an ENTITY entry from an xml file and generates an entity sound definition.
void DeleteAmbient(psMusic *&ambient)
void SetEntityState(int state, iMeshWrapper *mesh, const char *actorName, bool forceChange)
Sets the new state for the entity associated to the given mesh.
~psSoundSector()
Destructor.
void UpdateMusic(bool loopToggle, int type, SoundControl *&ctrl)
void RemoveObjectEntity(iMeshWrapper *mesh, const char *meshName)
Removes an object entity managed from the sector.
This object represents a planeshift soundEmitter.
void AddMusic(csRef< iDocumentNode > Node)
csHash< psEntity *, csString > factories
hash of factory entities
void DeleteEmitter(psEmitter *&emitter)
Deletes one emitter from the current array of known emitters.
void DeleteEntity(psEntity *&entity)
void Load(csRef< iDocumentNode > sectorNode)
Loads the sector's definition from the given node.
void DeleteMusic(psMusic *&music)
This object represents a planeshift entity sound.