Added clan tag support for CS:GO in CStrike ext (bug 5429, r=psychonic).
This commit is contained in:
parent
5ec6f851c9
commit
42ff151ae4
@ -366,11 +366,6 @@ static cell_t CS_GetWeaponPrice(IPluginContext *pContext, const cell_t *params)
|
||||
|
||||
static cell_t CS_GetClientClanTag(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
#if SOURCE_ENGINE == SE_CSGO
|
||||
size_t len;
|
||||
pContext->StringToLocalUTF8(params[2], params[3], "", &len);
|
||||
return len;
|
||||
#else
|
||||
static void *addr;
|
||||
if (!addr)
|
||||
{
|
||||
@ -406,14 +401,10 @@ static cell_t CS_GetClientClanTag(IPluginContext *pContext, const cell_t *params
|
||||
pContext->StringToLocalUTF8(params[2], params[3], src, &len);
|
||||
|
||||
return len;
|
||||
#endif
|
||||
}
|
||||
|
||||
static cell_t CS_SetClientClanTag(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
#if SOURCE_ENGINE == SE_CSGO
|
||||
return 0;
|
||||
#else
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
if (!pWrapper)
|
||||
@ -448,7 +439,6 @@ static cell_t CS_SetClientClanTag(IPluginContext *pContext, const cell_t *params
|
||||
pWrapper->Execute(vstk, NULL);
|
||||
|
||||
return 1;
|
||||
#endif
|
||||
}
|
||||
|
||||
static cell_t CS_AliasToWeaponID(IPluginContext *pContext, const cell_t *params)
|
||||
|
@ -49,6 +49,12 @@
|
||||
"linux" "47"
|
||||
"mac" "61"
|
||||
}
|
||||
"ClanTagOffset"
|
||||
{
|
||||
"windows" "15"
|
||||
"linux" "41"
|
||||
"mac" "22"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
@ -123,6 +129,13 @@
|
||||
"linux" "@_Z15AliasToWeaponIDPKc"
|
||||
"mac" "@_Z15AliasToWeaponIDPKc"
|
||||
}
|
||||
"SetClanTag"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x55\x8B\xEC\x8B\x2A\x2A\x85\xC0\x74\x2A\x6A\x10\x50\x81\xC1\x2A\x2A\x2A\x2A\x51"
|
||||
"linux" "@_ZN9CCSPlayer10SetClanTagEPKc"
|
||||
"mac" "@_ZN9CCSPlayer10SetClanTagEPKc"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -250,7 +250,6 @@ native CS_GetWeaponPrice(client, CSWeaponID:id, bool:defaultprice = false);
|
||||
* @return Number of non-null bytes written.
|
||||
*
|
||||
* @error Invalid client.
|
||||
* @note Only supported on CS:S. Writes 0-length string on CS:GO.
|
||||
*/
|
||||
native CS_GetClientClanTag(client, String:buffer[], size);
|
||||
|
||||
@ -261,7 +260,6 @@ native CS_GetClientClanTag(client, String:buffer[], size);
|
||||
* @noreturn
|
||||
*
|
||||
* @error Invalid client.
|
||||
* @note Only supported on CS:S. Has no effect on CS:GO.
|
||||
*/
|
||||
native CS_SetClientClanTag(client, const String:tag[]);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user