SA-MP Forums Archive
Can we Use...?? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Can we Use...?? (/showthread.php?tid=523685)



Can we Use...?? - TheRaGeLord - 03.07.2014

I Wanna Ask You That Can we Use \n In a Cient Message.....

As I Am Using Client Messages For Random Messages....

If we cannot use \n then how can i sedn two RMs at The Same Time..


Re: Can we Use...?? - greentarch - 03.07.2014

Quote:
Originally Posted by TheRaGeLord
Посмотреть сообщение
I Wanna Ask You That Can we Use \n In a Cient Message.....

As I Am Using Client Messages For Random Messages....

If we cannot use \n then how can i sedn two RMs at The Same Time..
Just use another SendClientMessage
I'll write you an example script; wait.

pawn Код:
/*
    Random Messages?
        DOUBLE Random Messages!
*/


#include < a_samp >

enum e_MSG
{
    MSG1[ 128 ],
    MSG2[ 128 ]
}

new
    gRandomMSG[ ][ e_MSG ] =
    {
        { "Welcome to my server!", "IP: 127.0.0.1:7777" },
        { "Do you want free money?", "Get a job, you lazy bitch!" },
        { "Are you hungry?", "Visit the closest Cluckin' Bell! We got chickens!" }
    };
   
public OnFilterScriptInit( )
{
    SetTimer( "sendRandomMSG", 60 * 1000, true );
    return 1;
}

forward sendRandomMSG( );
public sendRandomMSG( )
{
    new
        i = random( sizeof ( gRandomMSG ) );
    SendClientMessageToAll( 0xFF9933FF, gRandomMSG[ i ][ MSG1 ] );
    SendClientMessageToAll( 0xFF3399FF, gRandomMSG[ i ][ MSG2 ] );
    return 1;
}
Works that way.
You could do another random, and put the same clientmessage script.


Re: Can we Use...?? - TheRaGeLord - 03.07.2014

Ty Brother