Jump to content
  • 0

Random color


bogdan.trial

Question

Salut! am o intrebare.... exista un fel de random color? A-si dori sa il folosesc in acest caz.

          GetPlayerName( playerid, playrname, sizeof( playrname ));

GetPlayerIp( playerid, ip, sizeof( ip ));

format(string, 256, "*** %s has joined the server. (ID: %d) (IP: %s)", playrname, playerid, ip );

          SendClientMessageToAll( RANDOM, string );

signature.php?bg=000000&text=FFFFFF&border=a0a0a0&ip=176.31.142.87&port=7777&bg_image=
Link to comment
Share on other sites

5 answers to this question

Recommended Posts

exista dar trebuie definite inainte sa zicem:

//la inceputul scriptului
RandColor[2][1]
{
0xFF0000FF//rosu
0x0000FFFF//albastru
//aici mai adaugi culori
}
//unde vrei sa fie culoare random
new rand = random(2);
SendClientMessage(RandColor[rand][1],"mesajul");
Nota: Daca adaugi mai multe culori modifici numarul 2 de la
 RandColor
si
random

cu numarul de culori pe care le ai

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.