[FilterScript] Hwang's Lotto System.
#1

Hi, my server was using the lottery system did, and after making a few edits have decided to share, let the system health edit the line in the system 114. Put your server, use at your leisure, the players remain satisfied, players health use number between 1 and 50, because number is between 1 to 50, the winner's life armor (100hp) and +20 score is $ 90,000. Do not get confused because he created a stock lottoprizes, he can change Stock looking at the awards.

Hwang's Lotto System Click To Download!
Reply
#2

Pastebin link add please
Reply
#3

Код:
/*

»»»»»»»»          						    Yapımcı 	=;
             													  		   Hwang

»»»»»»»»                                    Tarih	    =;
 																      07.09.2013

*/

#include	a_samp
#pragma     tabsize		0
#define 	dcmd(%1,%2,%3) if ((strcmp((%3)[1], #%1, true, (%2)) == 0) && ((((%3)[(%2) + 1] == 0) && (dcmd_%1(playerid, "")))||(((%3)[(%2) + 1] == 32) && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1

new LotoBitti,
		LotoBasladi,
			LotoNumarasi,
				LotoBasladiVOL2;

public OnFilterScriptInit(){
InitInfos();
return 1;}

public OnFilterScriptExit(){
ExitInfos();
return 1;}

public OnPlayerCommandText(playerid, cmdtext[]){
dcmd(lotto,5,cmdtext);
return 1;}

dcmd_lotto(playerid,params[]){
if(LotoBasladiVOL2 == 1){
new tmp[256];
if(!strlen(params)) return SendClientMessage(playerid,-1,"{00FFFF}+- Loto -+ {ffffff}/lotto [Number]");
if(IsNumeric(tmp)){
new 			lCevabi;
lCevabi 	= 	strval(params);
if(lCevabi == LotoNumarasi){
LotoBasladiVOL2 = 0;
LotoNumarasi = 0;
KillTimer(LotoBitti);
LotoBasladi = SetTimer("LotoBasladiVOL0", 300000, 0);
lotteryprizes(playerid);
new isim[MAX_PLAYER_NAME];
GetPlayerName(playerid,isim, sizeof(isim));
new str[128];
format(str,128,"{00FFFF}+- Lotto -+ {00FF00}%s {ffffff}has won the lottery player 90.000$ and +20 score win!",isim);
SendClientMessageToAll(-1,str);
}else{
SendClientMessage(playerid,-1,"{00FFFF}+- Lotto -+ {ffffff}You incorrectly answered.");
}
}
else
{
return SendClientMessage(playerid,-1,"{00FFFF}+- Lotto -+ {ffffff}Is not active!");
}
return 1;
}
}

forward LotoBasladiVOL0();
public LotoBasladiVOL0(){
LotoNumarasi = random(50);
LotoBasladiVOL2 = 1;
new LotoyaZi[128];
new LotoyaZi2[128];
format(LotoyaZi, sizeof(LotoyaZi), "{00FFFF}+- Lotto -+ {ffffff}Lotto started lotto /lotto number between 1-50 to play using the lottery!");
SendClientMessageToAll(-1, LotoyaZi);
LotoBitti = SetTimer("LotoSonaErdi", 120000, 0);
return 1;}

forward LotoSonaErdi();
public LotoSonaErdi(){
new LotoyaZi[128];
new LotoyaZi2[128];
LotoBasladiVOL2 = 0;
format(LotoyaZi, sizeof(LotoyaZi), "{00FFFF}+- Lotto -+ {ffffff}No one failed to meet the lottery, lotto, whereas numerous as follows: {00FFFF}%d",LotoNumarasi);
SendClientMessageToAll(-1, LotoyaZi);
LotoBasladi = SetTimer("LotoBasladiVOL0", 300000, 0);
return 1;}

stock IsNumeric(string[])
{
	for (new i = 0, j = strlen(string);
	i < j; i++)
	{
	if (string[i] > '9' || string[i] < '0')
	return 0;
	}
	return 1;
}

stock lotteryprizes(playerid){
SetPlayerScore(playerid,GetPlayerScore(playerid)+20);
GivePlayerMoney(playerid,90000);
SetPlayerHealth(playerid,100);
SetPlayerArmour(playerid,100);
GameTextForPlayer(playerid, "you lotto winner!", 1000, 3);
return 1;}

stock InitInfos(){
print("@@@@@@@  Lotto System Settings Installed!  @@@@@@@\n");
print("			Author:					Hwang\n");
print("			Create Date:			07.09.2013\n");
print("			System Active			 !			\n");
LotoBasladi = SetTimer("LotoBasladiVOL0", 300000, 0);
LotoBasladiVOL2 = 0;
return 1;}

stock ExitInfos(){
print("@@@@@@ 	Lotto System Info 	@@@@@@@\n");
print("			==>> System Closed !!!");
return 1;}
Reply
#4

Stop flooding! ¬¬

Screens?
Reply
#5

Quote:
Originally Posted by EnzoMetlc
Посмотреть сообщение
Stop flooding! ¬¬

Screens?
I did not need the picture, everything in the middle.
Reply
#6

Updated!
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)