File tree 1 file changed +7
-0
lines changed
Client/mods/deathmatch/logic/luadefs
1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change 8
8
*****************************************************************************/
9
9
10
10
#include " StdInc.h"
11
+ #include " CScriptArgReader.h"
11
12
12
13
#define MIN_CLIENT_REQ_CALLREMOTE_QUEUE_NAME " 1.5.3-9.11270"
13
14
#define MIN_CLIENT_REQ_FETCHREMOTE_CONNECT_TIMEOUT " 1.3.5"
14
15
#define MIN_CLIENT_REQ_CALLREMOTE_OPTIONS_TABLE " 1.5.4-9.11342"
15
16
#define MIN_CLIENT_REQ_CALLREMOTE_OPTIONS_FORMFIELDS " 1.5.4-9.11413"
16
17
18
+ static auto GetServerIp (std::optional<bool > includePort) -> const char*
19
+ {
20
+ return g_pNet->GetConnectedServer (includePort.value_or (false ));
21
+ }
22
+
17
23
void CLuaNetworkDefs::LoadFunctions ()
18
24
{
19
25
constexpr static const std::pair<const char *, lua_CFunction> functions[]{
20
26
{" fetchRemote" , FetchRemote},
21
27
{" getRemoteRequests" , GetRemoteRequests},
22
28
{" getRemoteRequestInfo" , GetRemoteRequestInfo},
23
29
{" abortRemoteRequest" , AbortRemoteRequest},
30
+ {" getServerIp" , ArgumentParser<GetServerIp>},
24
31
};
25
32
26
33
// Add functions
You can’t perform that action at this time.
0 commit comments