]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/sounds/all.qh
Registry: overflow check
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / sounds / all.qh
index d567d0a446ab4db14dc831e2b513d129eb9f421e..90858f39d7841cf5f2c2f73d0c59fc37a637546f 100644 (file)
@@ -18,7 +18,7 @@
 // Used in places where a string is required
 #define SND(id) (SND_##id.sound_str())
 
-REGISTRY(Sounds, 128)
+REGISTRY(Sounds, BIT(8))
 REGISTER_REGISTRY(RegisterSounds)
 
 CLASS(Sound, Object)
@@ -42,7 +42,7 @@ ENDCLASS(Sound)
 
 #define SOUND(name, path) \
     string SND_##name##_get() { return path; } \
-    REGISTER(RegisterSounds, SND, Sounds, Sounds_COUNT, name, m_id, NEW(Sound, SND_##name##_get))
+    REGISTER(RegisterSounds, SND, Sounds, name, m_id, NEW(Sound, SND_##name##_get))
 
 STATIC_INIT(RegisterSounds_precache) {
     FOREACH(Sounds, true, LAMBDA({