diff --git a/dlls/fun/fun.cpp b/dlls/fun/fun.cpp index 552e783d..f5780389 100755 --- a/dlls/fun/fun.cpp +++ b/dlls/fun/fun.cpp @@ -195,7 +195,7 @@ static cell AMX_NATIVE_CALL set_user_money(AMX *amx, cell *params) // set_user_m // Give money to user // params[1] = user // params[2] = money - // params[3] = flash money? (NYI) + // params[3] = flash money? // Check index if (params[1] < 1 || params[1] > gpGlobals->maxClients) @@ -210,6 +210,12 @@ static cell AMX_NATIVE_CALL set_user_money(AMX *amx, cell *params) // set_user_m // Give money (int)*((int *)pPlayer->pvPrivateData + CSMONEYOFFSET) = params[2]; + // Update display + MESSAGE_BEGIN(MSG_ONE, GET_USER_MSG_ID(PLID, "Money", NULL), NULL, pPlayer); + WRITE_LONG(params[2]); + WRITE_BYTE(params[3] ? 1 : 0); // if params[3] is 0, there will be no +/- flash of money in display... + MESSAGE_END(); + return 1; } @@ -531,7 +537,7 @@ AMX_NATIVE_INFO fun_Exports[] = { {"set_user_health", set_user_health}, {"give_item", give_item}, {"spawn", spawn}, - {"user_spawn", spawn}, // No, it's not a typo! Uses the same as "spawn", because they do the same stuff! This is made only to maintain comp. with old plugins! + //{"user_spawn", spawn}, // No, it's not a typo! Uses the same as "spawn", because they do the same stuff! This is made only to maintain comp. with old plugins! {"set_user_money", set_user_money}, {"get_user_money", get_user_money}, {"set_user_deaths_cs", set_user_deaths_cs}, diff --git a/dlls/fun/fun.h b/dlls/fun/fun.h index 3c20b8e1..85e39b11 100755 --- a/dlls/fun/fun.h +++ b/dlls/fun/fun.h @@ -29,7 +29,7 @@ pfnmodule_engine_g* g_engModuleFunc; // These seem to be meta/amxmod related #define NAME "fun" #define AUTHOR "JGHG" -#define VERSION "0.2" +#define VERSION "0.3" #define URL "http://?" #define LOGTAG "fun" #define DATE __DATE__