Help! Hook negative value

NhoNYC

Solid & Active Platinian
Original poster
Dec 31, 2017
99
20
28
Far from home
Hi there,

I'm trying to turn game price to negative value so money increase when i click buy.

Code:
int (*old_get_int__)(void *instance);
int get_int__(void *instance)
{
    if ( instance != NULL )
    {
        int number = old_get_int__(instance);
        return number * -1;
    }
    return old_get_int__(instance);
}
But my hook code return 0 price, not negative. I dont know why.

Please help me.

Thanks you & have a nice day.