From 4b6de096e516bf4579d2367639ae71d12ea865d2 Mon Sep 17 00:00:00 2001 From: spherallic Date: Wed, 12 Apr 2023 00:59:08 +0200 Subject: [PATCH] Define cv_addons_folder in dedicated --- src/d_netcmd.c | 4 ++-- src/r_main.c | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/d_netcmd.c b/src/d_netcmd.c index 1fbdfdce2..28e7727e1 100644 --- a/src/d_netcmd.c +++ b/src/d_netcmd.c @@ -794,8 +794,8 @@ void D_RegisterClientCommands(void) CV_RegisterVar(&cv_digitaldeadzone2); // filesrch.c - CV_RegisterVar(&cv_addons_option); - CV_RegisterVar(&cv_addons_folder); + //CV_RegisterVar(&cv_addons_option); // These two are now defined + //CV_RegisterVar(&cv_addons_folder); // in R_RegisterEngineStuff CV_RegisterVar(&cv_addons_md5); CV_RegisterVar(&cv_addons_showall); CV_RegisterVar(&cv_addons_search_type); diff --git a/src/r_main.c b/src/r_main.c index 4d801dc80..53f6ee2f9 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -36,6 +36,7 @@ #include "r_main.h" #include "i_system.h" // I_GetPreciseTime #include "r_fps.h" // Frame interpolation/uncapped +#include "filesrch.c" // cv_addons_folder #ifdef HWRENDER #include "hardware/hw_main.h" @@ -1589,6 +1590,10 @@ void R_RegisterEngineStuff(void) CV_RegisterVar(&cv_flipcam); CV_RegisterVar(&cv_flipcam2); + // Other filesrch.c consvars are defined in D_RegisterClientCommands + CV_RegisterVar(&cv_addons_option); + CV_RegisterVar(&cv_addons_folder); + // Enough for dedicated server if (dedicated) return;