From c1f67576a4e23f3c0e06e86c0b1cf1f0b51949b3 Mon Sep 17 00:00:00 2001 From: hendricks266 Date: Tue, 12 Jan 2016 10:31:01 +0000 Subject: [PATCH] CON: Add userdef[].soundtoggle. Read-only. git-svn-id: https://svn.eduke32.com/eduke32@5553 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/gamedef.c | 1 + polymer/eduke32/source/gamedef.h | 1 + polymer/eduke32/source/gamestructures.c | 1 + 3 files changed, 3 insertions(+) diff --git a/polymer/eduke32/source/gamedef.c b/polymer/eduke32/source/gamedef.c index 67f82515c..f51aeef33 100644 --- a/polymer/eduke32/source/gamedef.c +++ b/polymer/eduke32/source/gamedef.c @@ -1177,6 +1177,7 @@ const memberlabel_t UserdefsLabels[]= { "vm_player", USERDEFS_VM_PLAYER, 0, 0 }, { "vm_sprite", USERDEFS_VM_SPRITE, 0, 0 }, { "vm_distance", USERDEFS_VM_DISTANCE, 0, 0 }, + { "soundtoggle", USERDEFS_SOUNDTOGGLE, 0, 0 }, { "", -1, 0, 0 } // END OF LIST }; diff --git a/polymer/eduke32/source/gamedef.h b/polymer/eduke32/source/gamedef.h index cd8e584ac..f0709a6b1 100644 --- a/polymer/eduke32/source/gamedef.h +++ b/polymer/eduke32/source/gamedef.h @@ -479,6 +479,7 @@ enum UserdefsLabel_t USERDEFS_VM_PLAYER, USERDEFS_VM_SPRITE, USERDEFS_VM_DISTANCE, + USERDEFS_SOUNDTOGGLE, USERDEFS_END }; diff --git a/polymer/eduke32/source/gamestructures.c b/polymer/eduke32/source/gamestructures.c index 54a8dcbe0..c85a2c1e3 100644 --- a/polymer/eduke32/source/gamestructures.c +++ b/polymer/eduke32/source/gamestructures.c @@ -173,6 +173,7 @@ int32_t __fastcall VM_GetUserdef(register int32_t lLabelID) case USERDEFS_VM_PLAYER: lLabelID = vm.g_p; break; case USERDEFS_VM_SPRITE: lLabelID = vm.g_i; break; case USERDEFS_VM_DISTANCE: lLabelID = vm.g_x; break; + case USERDEFS_SOUNDTOGGLE: lLabelID = ud.config.SoundToggle; break; default: lLabelID = -1; break; }