mirror of
https://github.com/alliedmodders/sourcemod.git
synced 2025-12-07 02:18:35 +00:00
Argbuf Native_TakeDamage
This commit is contained in:
parent
257535daf2
commit
059625cac9
@ -201,13 +201,7 @@ cell_t Native_TakeDamage(IPluginContext *pContext, const cell_t *params)
|
|||||||
pCall = g_pBinTools->CreateVCall(offset, 0, 0, &pass[1], &pass[0], 1);
|
pCall = g_pBinTools->CreateVCall(offset, 0, 0, &pass[1], &pass[0], 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Can't ArgBuffer here until we upgrade our Clang version on the Linux builder
|
ArgBuffer<CBaseEntity*, CTakeDamageInfoHack&> vstk(pVictim, info);
|
||||||
unsigned char vstk[sizeof(CBaseEntity *) + sizeof(CTakeDamageInfoHack &)];
|
|
||||||
unsigned char* vptr = vstk;
|
|
||||||
|
|
||||||
*(CBaseEntity **)vptr = pVictim;
|
|
||||||
vptr += sizeof(CBaseEntity *);
|
|
||||||
*(CTakeDamageInfoHack *&)vptr = info;
|
|
||||||
|
|
||||||
int ret;
|
int ret;
|
||||||
pCall->Execute(vstk, &ret);
|
pCall->Execute(vstk, &ret);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user