120 if (autocvar_g_logTimestamps)
121 print(sprintf(
"^9%f ^xF50%s^7: %s\n", time, functionName, msg));
123 print(sprintf(
"^xF50%s^7: %s\n", functionName, msg));
130#define SndLog(...) if (autocvar_s_logLevel >= LOGLEVEL_DEBUG) _SndLog(__FUNC__, sprintf(__VA_ARGS__))
133_SndEntLog(
string className,
string functionName,
float edictNum,
string warnMessage)
135 if (autocvar_g_logTimestamps)
136 print(sprintf(
"^9%f ^xF50%s (id: %d)^7: %s\n", time, functionName, edictNum, warnMessage));
138 print(sprintf(
"^xF50%s (id: %d)^7: %s\n", functionName, edictNum, warnMessage));
145#define SndEntLog(...) if (autocvar_s_logLevel >= LOGLEVEL_DEBUG) _SndEntLog(classname, __FUNC__, num_for_edict(this), sprintf(__VA_ARGS__))
203void Sound_Play(entity targetEntity,
int sndChannel,
string sndDef);
211void Sound_Update(entity targetEntity,
int sndChannel,
int sndSample,
float desiredVolume);
216void Sound_Speak(entity targetEntity,
string sentencesEntry);
float flags
Definition: sound.h:114
var logLevel_t autocvar_s_logLevel
Definition: sound.h:116
void _SndLog(string functionName, string msg)
Definition: sound.h:118
int Sound_GetID(string sndDef)
Definition: sound.qc:780
void Sound_Update(entity targetEntity, int sndChannel, int sndSample, float desiredVolume)
Client-side only: Update the sound parameters on a given entity.
Definition: sound.qc:789
int Sound_Precache(string sndDef)
Force the precache of a soundDef file.
Definition: sound.qc:383
float maxspeed
Definition: sound.h:113
snd_t * g_sounds
Pointer to the global soundDef table.
Definition: sound.h:192
void Sound_Play(entity targetEntity, int sndChannel, string sndDef)
Play a soundDef on a given target entity.
Definition: sound.qc:577
var hashtable g_hashsounds
Global hash table for name > soundDef id lookup.
Definition: sound.h:148
void Sound_Stop(entity target, float chan)
Stops sounds on a given channel, on a target entity.
Definition: sound.qc:571
void Sound_PlayAt(vector worldPos, string sndDef)
Play a soundDef a a given location.
Definition: sound.qc:696
int g_sounds_count
Total amount of registered soundDef entries.
Definition: sound.h:194
void _SndEntLog(string className, string functionName, float edictNum, string warnMessage)
Definition: sound.h:133
void Sound_Shutdown(void)
Called by CSQC_Shutdown() and in theory, somewhere on the server.
Definition: sound.qc:39
void Sound_DebugList()
Called by listSoundDef.
Definition: sound.qc:937
void Sound_PlayLocal(string shader)
Client-side only: Play a sound locally, outside the game world.
Definition: sound.qc:754
void Sound_Init(void)
Called by the client inside CSQC_Init(), and on the server inside init().
Definition: sound.qc:52
typedef enumflags
Enumeration of valid sound flags.
Definition: sound.h:152
A soundDef aka 'sound shader' type.
Definition: sound.h:166
soundFlag_t flags
Sound flags that are applied to this soundDef.
Definition: sound.h:174
int playc
Number of plays.
Definition: sound.h:175
float dist_min
Minimum playback distance.
Definition: sound.h:167
int sample_count
Total amount of samples within this soundDef.
Definition: sound.h:176
float pitch_min
Minimum sound pitch.
Definition: sound.h:170
float offset
Sound sample offset.
Definition: sound.h:169
float pitch_max
Maximum sound pitch.
Definition: sound.h:171
float pointparticle
Definition: sound.h:180
float dist_max
Maximum playback distance.
Definition: sound.h:168
float shakes
Earthquake/Shake amplifier.
Definition: sound.h:172
string samples
Separated list of samples.
Definition: sound.h:177
string distshader
soundDef to play where this soundDef is not audible.
Definition: sound.h:179
float volume
Desired playback volume.
Definition: sound.h:173
string name
Name of the soundDef.
Definition: sound.h:178
A sound sample of a sentences.txt word sequence.
Definition: sound.h:185
string m_strSnd
Definition: sound.h:186
float m_flLength
Definition: sound.h:187
float m_flPitch
Definition: sound.h:188