Random Messages
#1

Hello ,

Could you please write the code for me about how to add random messages on the server? Also I need to know how to change the time . I would be grateful if you can explain for me in the code by adding the " /* " .

Thank you !
Reply
#2

https://sampwiki.blast.hk/wiki/Random_Messages
Reply
#3

I already read it but It doesn't help enough . I want someone to show me an example so I can edit it.

Thanks for replying .
Reply
#4

Well there is explaned all i don't know what you don't understand i will give you my code but it's same as wiki one...
Put this on top of the GM near forwards
pawn Код:
forward SendMSG(playerid);
put where you define new
pawn Код:
new RandomMSG[][] =
{
    "your txt.",
    "your txt."
};
put near your publics
pawn Код:
public SendMSG(playerid)
{
    if(HelpMessages[playerid] == 1)
    {
        new randMSG = random(sizeof(RandomMSG));
        SendClientMessageToAll(COLOR_SIMPSONS, RandomMSG[randMSG]);
    }
}
Put this under "public OnGameModeInit"
pawn Код:
SetTimer("SendMSG", 450000, true);
Reply
#5

I want it in a filterscript anyways , thanks .
Reply
#6

Then post a request not a script help...
Reply
#7

You're clearly asking for someone to 'create' this for 'you' in the 'Scripting Help' section, if you're not happy with the example ***Niko*** has given you then i suggest looking on the wiki and constantly reading so you know what you're doing, or posting a request on one of the six script request threads.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)