Thread: [CSGO] Set Cash
View Single Post
brunoronning
Senior Member
Join Date: Jan 2014
Location: Brazil
Old 01-19-2018 , 00:56   Re: [CSGO] Set Cash
Reply With Quote #6

Quote:
Originally Posted by Papero View Post
PHP Code:
int g_iAccount;

public 
void OnPluginStart()
{
    
g_iAccount FindSendPropOffs("CCSPlayer""m_iAccount");
    if (
g_iAccount == -1)
    {
        
SetFailState("Failed to find offset for m_iAccount!");
    }
}

public 
void MyFunc(int clientint iCash)
{
    
SetEntData(clientg_iAccountiCash);

Snippet from: https://forums.alliedmods.net/showthread.php?p=1434455
In this case it will only be used for CS:GO, it is not necessary to filter. SetEntProp will work perfectly.
brunoronning is offline