14 static std::string
GetType() {
return "AudioListener"; };
53 int Serialize(std::fstream* data,
int offset)
override;
61 int Deserialize(std::fstream* data,
int offset)
override;
Defines the GameObject class and its related components.
Represents an audio listener component attached to a game object.
Definition AudioListener.h:8
GameObject * attachedObj
The game object that the audio listener is attached to.
Definition AudioListener.h:35
AudioListener()
Default constructor for the AudioListener class.
Definition AudioListener.h:19
int Deserialize(std::fstream *data, int offset) override
Deserializes the audio listener component data.
Definition AudioListener.cpp:44
~AudioListener()
Destructor for the AudioListener class.
Definition AudioListener.cpp:12
static std::map< GameObject *, AudioListener * > componentList
A map of game objects to their corresponding audio listener components.
Definition AudioListener.h:40
static std::string GetType()
Gets the type of the audio listener component.
Definition AudioListener.h:14
void Update() override
Updates the audio listener component.
Definition AudioListener.cpp:18
int Serialize(std::fstream *data, int offset) override
Serializes the audio listener component data.
Definition AudioListener.cpp:39
Base class for game components.
Definition GameObject.h:29
Class representing a game object.
Definition GameObject.h:68