Merge pull request #55 from s1lentq/_fix_ext_func_api

Added missing EXT_FUNC functions to ReHLDS API
This commit is contained in:
dreamstalker 2015-07-14 01:18:50 +04:00
commit ebf0e21cba
4 changed files with 23 additions and 8 deletions

View File

@ -1299,7 +1299,7 @@ void SZ_Clear(sizebuf_t *buf)
buf->cursize = 0; buf->cursize = 0;
} }
void *SZ_GetSpace(sizebuf_t *buf, int length) void *EXT_FUNC SZ_GetSpace(sizebuf_t *buf, int length)
{ {
void *data; void *data;
const char *buffername = buf->buffername ? buf->buffername : "???"; const char *buffername = buf->buffername ? buf->buffername : "???";

View File

@ -1182,7 +1182,7 @@ void EXT_FUNC EV_PlayReliableEvent_api(IGameClient *cl, int entindex, short unsi
EV_PlayReliableEvent_internal(cl->GetClient(), entindex, eventindex, delay, pargs); EV_PlayReliableEvent_internal(cl->GetClient(), entindex, eventindex, delay, pargs);
} }
void EXT_FUNC EV_PlayReliableEvent(client_t *cl, int entindex, short unsigned int eventindex, float delay, event_args_t *pargs) void EV_PlayReliableEvent(client_t *cl, int entindex, short unsigned int eventindex, float delay, event_args_t *pargs)
{ {
g_RehldsHookchains.m_EV_PlayReliableEvent.callChain(EV_PlayReliableEvent_api, GetRehldsApiClient(cl), entindex, eventindex, delay, pargs); g_RehldsHookchains.m_EV_PlayReliableEvent.callChain(EV_PlayReliableEvent_api, GetRehldsApiClient(cl), entindex, eventindex, delay, pargs);
} }

View File

@ -690,9 +690,8 @@ qboolean Steam_NotifyClientConnect(client_t *cl, const void *pvSteam2Key, unsign
.callChain(Steam_NotifyClientConnect_api, FALSE, GetRehldsApiClient(cl), pvSteam2Key, ucbSteam2Key); .callChain(Steam_NotifyClientConnect_api, FALSE, GetRehldsApiClient(cl), pvSteam2Key, ucbSteam2Key);
} }
/* <f1884> ../engine/sv_steam3.cpp:914 */ /* <f1884> ../engine/sv_steam3.cpp:914 */
qboolean EXT_FUNC Steam_NotifyClientConnect_internal(client_t *cl, const void *pvSteam2Key, unsigned int ucbSteam2Key) qboolean Steam_NotifyClientConnect_internal(client_t *cl, const void *pvSteam2Key, unsigned int ucbSteam2Key)
{ {
if (Steam3Server()) if (Steam3Server())
{ {

View File

@ -65,6 +65,22 @@ DLL_FUNCTIONS* EXT_FUNC GetEntityInterface_api() {
return &gEntityInterface; return &gEntityInterface;
} }
void EXT_FUNC MSG_StartBitWriting_api(sizebuf_t *buf) {
MSG_StartBitWriting(buf);
}
void EXT_FUNC MSG_WriteBits_api(uint32 data, int numbits) {
MSG_WriteBits(data, numbits);
}
void EXT_FUNC MSG_WriteBitVec3Coord_api(const vec3_t fa) {
MSG_WriteBitVec3Coord(fa);
}
void EXT_FUNC MSG_EndBitWriting_api(sizebuf_t *buf) {
MSG_EndBitWriting(buf);
}
CRehldsServerStatic g_RehldsServerStatic; CRehldsServerStatic g_RehldsServerStatic;
CRehldsServerData g_RehldsServerData; CRehldsServerData g_RehldsServerData;
CRehldsHookchains g_RehldsHookchains; CRehldsHookchains g_RehldsHookchains;
@ -95,10 +111,10 @@ RehldsFuncs_t g_RehldsApiFuncs =
&GetEntityInterface_api, &GetEntityInterface_api,
&EV_PlayReliableEvent_api, &EV_PlayReliableEvent_api,
&SV_LookupSoundIndex, &SV_LookupSoundIndex,
&MSG_StartBitWriting, &MSG_StartBitWriting_api,
&MSG_WriteBits, &MSG_WriteBits_api,
&MSG_WriteBitVec3Coord, &MSG_WriteBitVec3Coord_api,
&MSG_EndBitWriting, &MSG_EndBitWriting_api,
&SZ_GetSpace &SZ_GetSpace
}; };