A single SendClientMessage SPAMMING
#1

Hello, I just made a single sendclientmessage, it's spamming the chat, also, since its a robbery system, its supposed to give me money, it gives me money around 10 times or more..



here's the code
Код:
new RandMoney = random(369);
	    GivePlayerMoney(playerid, RandMoney);
		new msg[128], sName[24];
		GetPlayerName(playerid, sName, 24);
		format(msg, 128, "%s(%d) has robbed $%d.", sName, playerid, RandMoney);
		SendClientMessageToAll(-1, msg);

and this is how it spams..


Код:
[19:26:58] HELLO

[19:26:58] TerminatedTERM(0) has robbed $343.

[19:26:58] HELLO

[19:26:58] TerminatedTERM(0) has robbed $304.

[19:26:58] HELLO

[19:26:59] TerminatedTERM(0) has robbed $39.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $248.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $289.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $252.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $111.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $153.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $208.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $208.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $88.

[19:26:59] HELLO

[19:26:59] TerminatedTERM(0) has robbed $130.

[19:26:59] HELLO
It's just a small example, it spams the chat even more..




Please help



EDIT: NOT GETTING ANY WARNING WHILE COMPILING THE GAMEMODE..
Reply


Messages In This Thread
A single SendClientMessage SPAMMING - by div - 22.06.2018, 14:02
Re: A single SendClientMessage SPAMMING - by Mike861 - 22.06.2018, 14:04
Re: A single SendClientMessage SPAMMING - by Exhibit - 22.06.2018, 14:06
Re: A single SendClientMessage SPAMMING - by XStormiest - 22.06.2018, 14:08
Re: A single SendClientMessage SPAMMING - by div - 22.06.2018, 14:09
Re: A single SendClientMessage SPAMMING - by Exhibit - 22.06.2018, 14:12
Re: A single SendClientMessage SPAMMING - by Mike861 - 22.06.2018, 14:12
Re: A single SendClientMessage SPAMMING - by div - 22.06.2018, 14:14
Re: A single SendClientMessage SPAMMING - by div - 22.06.2018, 14:18
Re: A single SendClientMessage SPAMMING - by Mike861 - 22.06.2018, 14:18

Forum Jump:


Users browsing this thread: 1 Guest(s)