Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp> // Include
- #define CURRENT_MESSAGES 5
- // Ovaj Broj Poruka Uvek Mora Biti Tacan.
- #define MESSAGE_COLOR 0x4169E1FF
- // Ovo je Boja Istih, Moze se Editovati.
- #define MESSAGE_TIME 250
- // Sekunde u kojima se racuna koliko treba poruci da se Ispise/Prekuca.
- new RP[CURRENT_MESSAGES][128];
- forward SendRandomMessage();
- public OnFilterScriptInit()
- {
- print("\n------------------------------------------");
- print(" Pet Poruka");
- print(" Random Poruke");
- print(" Volter v1.0");
- print("--------------------------------------------\n");
- AddRandomMessage("{f956ff}[DONACIJE] {FFFFFF}Ukoliko zelite pogledati listu donacija, kucajte {f956ff}/donacije.");
- AddRandomMessage("{00869e}[VOZILO] {FFFFFF}Na serveru mozete posjedovati 4 vozila, listu vozila gledate komandom {00869e}/v(/vozilo).");
- AddRandomMessage("{54d9ff}[POMOC] {FFFFFF}Trenutni PayDay iznosi {54d9ff}15.000$,{FFFFFF} ukoliko zelite vecu cifru, radite poslove.");
- AddRandomMessage("{6dff54}[BUG-FIX] {FFFFFF}Ukoliko pronadjete {6dff54}BUG,{FFFFFF} prijavite ga komandom {6dff54}/reportbug.");
- AddRandomMessage("{f4aa42}[TEAMSPEAK] {FFFFFF}Pricajte sa ostalim igracima na teamspeaku - {f4aa42}/teamspeak.");
- SetTimer("SendRandomMessage", MESSAGE_TIME * 1000, 1);
- return 1;
- }
- public SendRandomMessage()
- {
- static lastmessage = 0;
- new rand = random(CURRENT_MESSAGES);
- while(rand == lastmessage && CURRENT_MESSAGES != 1) { rand = random(CURRENT_MESSAGES); }
- lastmessage = rand;
- SendClientMessageToAll(MESSAGE_COLOR, RP[lastmessage]);
- }
- stock AddRandomMessage(text[])
- {
- for(new m; m < CURRENT_MESSAGES; m++)
- {
- if(!strlen(RP[m]))
- {
- strmid(RP[m], text, 0, 127);
- return 1;
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment