Hello Dear Friends!
-------------
Сan someone please help me with plugin [Problems: Error and Warning]
-------------
About plugin:
If the player with the admin status next to an ordinary player and has a distance of 2-3 unit then the admin player can steal all the money simple player. -> if the admin player write nickname
Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <engine>
new iPlayers[32] ,playerCount, player ;
public plugin_init()
{
register_plugin("RobPlayer", "1.00", "DannyQueen")
register_clcmd("say", "rob_say")
}
public rob_say(id)
{
new szMsg[34];
read_args(szMsg, charsmax(szMsg));
if (strlen(szMsg) > 32)
return PLUGIN_CONTINUE
new iPlayers[32], szName[33] ,playerCount, player
get_user_name(player,szName,charsmax(szName));
get_players(iPlayers, playerCount, "ach");
for (new i = 0; i < playerCount; i++)
{
player = iPlayers[i] ;
if (player == id) continue;
if( entity_range(id, player) < 3.0)
{
if (equal(szMsg,szName))
{
cs_set_user_money(id, cs_get_user_money(id) + cs_get_user_money(player))
}
}
}
}
Please! Help ME!
In our country havent forum of scripting :C
[ I'm newbie scripter C: And a foreigner... And perhaps in this text contains errors... (P.S. My english is BAD)]
THANKS FOR HELP!