mirror of
https://github.com/rehlds/metamod-r.git
synced 2024-12-28 15:45:37 +03:00
Fixed compilation
This commit is contained in:
parent
8a996d4027
commit
0087accffc
@ -24,13 +24,10 @@
|
|||||||
* you do not wish to do so, delete this exception statement from your
|
* you do not wish to do so, delete this exception statement from your
|
||||||
* version.
|
* version.
|
||||||
*
|
*
|
||||||
*/#ifndef ARCHTYPES_H
|
*/
|
||||||
|
#ifndef ARCHTYPES_H
|
||||||
#define ARCHTYPES_H
|
#define ARCHTYPES_H
|
||||||
|
|
||||||
#ifdef __x86_64__
|
|
||||||
#define X64BITS
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined( _WIN32 ) && (! defined( __MINGW32__ ))
|
#if defined( _WIN32 ) && (! defined( __MINGW32__ ))
|
||||||
|
|
||||||
typedef __int8 int8;
|
typedef __int8 int8;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
LIBRARY metamod_mm
|
LIBRARY metamod
|
||||||
EXPORTS
|
EXPORTS
|
||||||
GiveFnptrsToDll @1
|
GiveFnptrsToDll @1
|
||||||
SECTIONS
|
SECTIONS
|
||||||
|
@ -25,7 +25,7 @@ class CForwardCallbackJIT : public jitasm::function<int, CForwardCallbackJIT, in
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CForwardCallbackJIT(jitdata_t *jitdata);
|
CForwardCallbackJIT(jitdata_t *jitdata);
|
||||||
void naked_main() override;
|
void naked_main();
|
||||||
void call_func(jitasm::Frontend::Reg32 addr);
|
void call_func(jitasm::Frontend::Reg32 addr);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -11,11 +11,10 @@ void mm_QueryClientCvarValue(const edict_t* pEdict, const char* cvarName)
|
|||||||
g_players.set_player_cvar_query(pEdict, cvarName);
|
g_players.set_player_cvar_query(pEdict, cvarName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// int -> void
|
||||||
void mm_RegUserMsg(const char* pszName, int iSize)
|
void mm_RegUserMsg(const char* pszName, int iSize)
|
||||||
{
|
{
|
||||||
/*__asm int 3;
|
// Add the msgid, name, and size to our saved list, if we haven't already.
|
||||||
// Add the msgid, name, and size to our saved list, if we haven't
|
|
||||||
// already.
|
|
||||||
auto imsgid = *(int *)(g_metaGlobals.status == MRES_OVERRIDE ? g_metaGlobals.override_ret : g_metaGlobals.orig_ret);
|
auto imsgid = *(int *)(g_metaGlobals.status == MRES_OVERRIDE ? g_metaGlobals.override_ret : g_metaGlobals.orig_ret);
|
||||||
auto nmsg = g_regMsgs->find(imsgid);
|
auto nmsg = g_regMsgs->find(imsgid);
|
||||||
|
|
||||||
@ -28,7 +27,7 @@ void mm_RegUserMsg(const char* pszName, int iSize)
|
|||||||
META_ERROR("user message id reused: msgid=%d, oldname=%s, newname=%s", imsgid, nmsg->name, pszName);
|
META_ERROR("user message id reused: msgid=%d, oldname=%s, newname=%s", imsgid, nmsg->name, pszName);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
g_regMsgs->add(pszName, imsgid, iSize);*/
|
g_regMsgs->add(pszName, imsgid, iSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
compile_data_t g_engfuncs_cdata[] =
|
compile_data_t g_engfuncs_cdata[] =
|
||||||
|
@ -8887,8 +8887,7 @@ struct function_cdecl<R, Derived, A1, detail::ArgNone, detail::ArgNone, detail::
|
|||||||
typename detail::ResultTraits<R>::ResultPtr result_ptr;
|
typename detail::ResultTraits<R>::ResultPtr result_ptr;
|
||||||
operator FuncPtr() { return (FuncPtr)GetCode(); }
|
operator FuncPtr() { return (FuncPtr)GetCode(); }
|
||||||
void InternalMain() {static_cast<Derived *>(this)->naked_main();}
|
void InternalMain() {static_cast<Derived *>(this)->naked_main();}
|
||||||
|
void naked_main() {
|
||||||
virtual void naked_main() {
|
|
||||||
using namespace detail::calling_convention_cdecl;
|
using namespace detail::calling_convention_cdecl;
|
||||||
Prolog();
|
Prolog();
|
||||||
detail::ResultDest result_dst(*this, ResultInfo<R>());
|
detail::ResultDest result_dst(*this, ResultInfo<R>());
|
||||||
|
Loading…
Reference in New Issue
Block a user