From 3168e5ccf06552b54829358a2032def515541d67 Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Tue, 8 Aug 2023 09:23:23 +0300 Subject: [PATCH] wscript: add an option to request and accept any servers --- 3rdparty/mainui | 2 +- engine/client/cl_main.c | 2 ++ wscript | 4 ++++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/3rdparty/mainui b/3rdparty/mainui index 92c6c375..5fa2c6f6 160000 --- a/3rdparty/mainui +++ b/3rdparty/mainui @@ -1 +1 @@ -Subproject commit 92c6c37507e108190d1a464ccd39dfb62932aad5 +Subproject commit 5fa2c6f62c9037370b75373cdd89d65479524b56 diff --git a/engine/client/cl_main.c b/engine/client/cl_main.c index 3199f6e1..4e7f9c5f 100644 --- a/engine/client/cl_main.c +++ b/engine/client/cl_main.c @@ -1589,7 +1589,9 @@ size_t CL_BuildMasterServerScanRequest( char *buf, size_t size, qboolean nat ) info[0] = 0; +#ifndef XASH_ALL_SERVERS Info_SetValueForKey( info, "gamedir", GI->gamefolder, remaining ); +#endif Info_SetValueForKey( info, "clver", XASH_VERSION, remaining ); // let master know about client version Info_SetValueForKey( info, "nat", nat ? "1" : "0", remaining ); diff --git a/wscript b/wscript index c8f2c834..50132006 100644 --- a/wscript +++ b/wscript @@ -135,6 +135,9 @@ def options(opt): grp.add_option('--enable-tests', action = 'store_true', dest = 'TESTS', default = False, help = 'enable building standalone tests (does not enable engine tests!) [default: %default]') + # a1ba: special option for me + grp.add_option('--debug-all-servers', action='store_true', dest='ALL_SERVERS', default=False, help='') + grp = opt.add_option_group('Renderers options') grp.add_option('--enable-all-renderers', action='store_true', dest='ALL_RENDERERS', default=False, @@ -357,6 +360,7 @@ def configure(conf): conf.env.GAMEDIR = conf.options.GAMEDIR conf.define('XASH_GAMEDIR', conf.options.GAMEDIR) + conf.define_cond('XASH_ALL_SERVERS', conf.options.ALL_SERVERS) # check if we can use C99 stdint conf.define('STDINT_H', 'stdint.h' if conf.check_cc(header_name='stdint.h', mandatory=False) else 'pstdint.h')