Interesting PayDay :) [İdea Please]
#1

Hi friends,I have a payday problem.PayDay gives only few players.I removed return's but problem still continues.With the idea ?


My SyncTime Public:
Код:
public SyncTime()
{
	//new string[64];
	new tmphour;
	new tmpminute;
	new tmpsecond;

	gettime(tmphour, tmpminute, tmpsecond);
	FixHour(tmphour);
	if (((tmphour > ghour) || (tmphour == 0 && ghour == 23)) && !tmpminute)
	{
		PayDay2();
		print("[SYSTEM]:  (( Payday )) !");
		if (realtime)
		{
			SetWorldTime(tmphour);
		}
	}
	else if(((tmphour > ghour) || (tmphour == 0 && ghour == 23)) && tmpminute)
	{
		for(new i=0;i<MAX_PLAYERS;i++)
		{
			camepayday[i] = 0;
		}
		ghour = tmphour;
	}
}
My PayDay Public:
Код:
public PayDay2()
{
	new string[128];
	new eskihesap;
	new kazanc;
	for(new i = 0; i < MAX_PLAYERS; i++)
	{
		if(IsPlayerConnected(i) && GirisYapti[i] && !camepayday[i] && !IsPlayerNPC(i))
		{
			camepayday[i] = 1;
			PlayerInfo[i][pExp] += 1;
			PlayerInfo[i][pOyunSaati] += 1;
			MuzikCal(i);
			PlayerInfo[i][pPara]+= PaydayUcreti[PlayerInfo[i][pLevel]][0];
			eskihesap = PlayerInfo[i][pBankaPara];
			kazanc = PlayerInfo[i][pBankaPara]/1000;
			PlayerInfo[i][pBankaPara] = eskihesap+kazanc;
			SendClientMessage(i, COLOR_HATA, "_______[***]_______");
			format(string,sizeof(string),"Saatlik Kazanз: %d$", PaydayUcreti[PlayerInfo[i][pLevel]][0]);
			SendClientMessage(i, COLOR_WHITE, string);
			format(string,sizeof(string),"Bankanızdaki Para: %d$",eskihesap);
			SendClientMessage(i, COLOR_WHITE, string);
			format(string,sizeof(string),"Işlenen Faiz: %d$",kazanc);
			SendClientMessage(i, COLOR_WHITE, string);
			format(string,sizeof(string),"Bankanızdaki Yeni Para: %d$",PlayerInfo[i][pBankaPara]);
			SendClientMessage(i, COLOR_WHITE, string);
			new nxtlevel = PlayerInfo[i][pLevel]+1;
			new expamount = nxtlevel*ExpSayi;
			if(PlayerInfo[i][pKiraSure] >= 1 && PlayerInfo[i][pKiraSure] <= 4)
			{
				PlayerInfo[i][pKiraSure]--;
			}
			if(PlayerInfo[i][pKiraSure] == 0)
			{
				new id = KiralikAracID2(PlayerInfo[i][pKiraAnahtar]);
				PlayerInfo[i][pKiraSure] = 5;
				KiraDurum[id] = 0;
				PlayerInfo[i][pKiraAnahtar] = -399;
				MotorDurum[id] = false;
				if(GetPlayerVehicleID(i) == id)
				{
					TogglePlayerControllable(i,0);
					RemovePlayerFromVehicle(i);
					TogglePlayerControllable(i,1);
					SendClientMessage(i,COLOR_SFPD,"(( BILGI: Aracinizin kira suresi dolmustur. ))");
	 			}
	 		}
			if(PlayerInfo[i][pExp] == expamount)
			{
				PlayerInfo[i][pLevel]++;
				PlayerInfo[i][pExp] = 0;
				SendClientMessage(i, COLOR_HATA, "_______[***]_______");
				format(string, sizeof(string), "(( BILGI: Level atladiniz, yeni leveliniz %d ! ))", PlayerInfo[i][pLevel]);
				SendClientMessage(i,COLOR_WHITE,string);
			}
		}
	}
}
Reply


Messages In This Thread
Interesting PayDay :) [İdea Please] - by bkart - 26.03.2011, 15:36
Re: Interesting PayDay :) [İdea Please] - by bijoyekuza - 26.03.2011, 15:54
Re: Interesting PayDay :) [İdea Please] - by bkart - 26.03.2011, 16:17
Re: Interesting PayDay :) [İdea Please] - by bkart - 02.04.2011, 13:49

Forum Jump:


Users browsing this thread: 1 Guest(s)