PDA

View Full Version : PlayAudioStreamForPlayer chat spam


sirvanec
24/12/2014, 02:07 AM
delete

Banana_Ghost
24/12/2014, 06:40 AM
are you using a loop?

sirvanec
24/12/2014, 10:46 AM
Yes i'm using a loop

Threshold
24/12/2014, 11:06 AM
Show us your code???

sirvanec
24/12/2014, 11:27 AM
I got the same problem if i trying sendclientmessagetoall

BornHuman
24/12/2014, 11:37 AM
Try adding 'return 1;' after TextMessage(estring,fstring);

Flori
24/12/2014, 11:51 AM
You loop through all players and then send a message to everyone for each player.
It's like:

for player 1 a sendclientmessagetoall
for player 2 a sendclientmessagetoall
...

That's the reason for the spam. Just use SendClientMessage(i,COLOR,MESSAGE);

sirvanec
24/12/2014, 11:54 AM
But you can see i don't you sendclientmessagetoall or something... how i can fix my code? Thanks BornHuman i will try this..

Flori
24/12/2014, 11:57 AM
And where shall i know what "TextMessage" does? :D

Also a return 1 won't help here. You need to send to each player only a message. :)

sirvanec
24/12/2014, 12:01 PM
Yes Flori i tried. Spam problem is fixed but the music did not start now.. Look at the picture TextMessage it helps to write there..

sirvanec
24/12/2014, 12:10 PM
btw when i try return 1; music did not start

Flori
24/12/2014, 12:25 PM
Hmm, if the music started before and we just changed the sent message it should still start.

return 1 at the end of the dialog.

Also you need to be sure that the format you want to play is correct. http://wiki.sa-mp.com/wiki/PlayAudioStreamForPlayer

Good luck. :)

sirvanec
24/12/2014, 07:51 PM
I did like this and it still not working..

sirvanec
24/12/2014, 08:13 PM
I tried even like this..

sirvanec
25/12/2014, 02:32 PM
Up..