[HELP] Football Script
#1

Hi, I'm Makin Football Script it works OK But I cant do how to request Join etc

Here is the codes and what i would like todo



/mackur = When Player Types That -50 From His Money And He will can /macbaslat
/macbaslat = Starts The Match That Who joined
/macagir = request to join match
/macakabulet = Accepts request
Here is the coder

Код:
	if (strcmp(cmd, "/mackur", true) == 0)
	{
	    if(FutbolOyananiyor == 0)
	    {
		MacKuruyor[playerid] = 1;
	    SendClientMessage(playerid, COLOR_GRAD1,"  Maз Kurmaya Başladınız. Maз 10 Dakika Sonra Bitecektir.");
 	    SendClientMessage(playerid, COLOR_GRAD1,"/Macabasla ile Maзa Başlayabilirsin |Halı Saha Fiyatı: 50TL.");
		Ascore = 0;
		Bscore = 0
		new wstring[256];
		format(wstring, sizeof(wstring), "[Skor A] %d", Ascore);
		Update3DTextLabelText(labelSkorA, 0xFFFFFFFF, wstring);
		format(wstring, sizeof(wstring), "[Skor B] %d", Bscore);
		Update3DTextLabelText(labelSkorB, 0xFFFFFFFF, wstring);
  		GivePlayerMoney(playerid, -50);
  		SetTimer("MacBitir",60000,0);
  		FutbolOyananiyor = 1;
	    }
	else
		{
	    SendClientMessage(playerid, COLOR_GRAD1,"Zaten Devam Eden bir maз var yada Maз kuruluyor");
	    }
    }
    

  	if (strcmp(cmd, "/macakabulet", true) == 0)
	{
	    	tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "Kullanım: /macakabulet");
				return 1;
			}
			giveplayerid = ReturnUser(tmp);
			if(MacaGirmekIstio[giveplayerid] != 1)
			{
			    if(IsPlayerConnected(giveplayerid))
			    {
			        if(giveplayerid != INVALID_PLAYER_ID)
			        {
			            new wstring[128];
					    GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						new length = strlen(cmdtext);
						while ((idx < length) && (cmdtext[idx] <= ' '))
						{
							idx++;
						}
						new offset = idx;
						new result[64];
						while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
						{
							result[idx - offset] = cmdtext[idx];
							idx++;
						}
						MacaGirdi[playerid] = 1;
						format(wstring, sizeof(wstring), " %s [ID:%d] Tarafından Maзa Alındınız.",sendername,playerid);
					    SendClientMessage(giveplayerid, COLOR_GRAD1, wstring);
						return 1;
					}
				}//not connected
				else
				{
				format(string, sizeof(string), "   %d Oyuncu aktif değil.", giveplayerid);
				SendClientMessage(playerid, COLOR_GRAD1, string);
				}
				}
		return 1;
	}
	
  	if (strcmp(cmd, "/macagir", true) == 0)
	{
	    	tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "Kullanım: /macagir");
				return 1;
			}
			giveplayerid = ReturnUser(tmp);
			if(MacKuruyor[giveplayerid] == 1)
			{
			    if(IsPlayerConnected(giveplayerid))
			    {
			        if(giveplayerid != INVALID_PLAYER_ID)
			        {
			            new wstring[128];
					    GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						new length = strlen(cmdtext);
						while ((idx < length) && (cmdtext[idx] <= ' '))
						{
							idx++;
						}
						new offset = idx;
						new result[64];
						while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
						{
							result[idx - offset] = cmdtext[idx];
							idx++;
						}
						MacaGirmekIstio[playerid] = 1;
						format(wstring, sizeof(wstring), " %s [ID:%d] Maзa Girmek istiyor. /macakabulet ID.",sendername,playerid);
					    SendClientMessage(giveplayerid, COLOR_GRAD1, wstring);
						return 1;
					}
				}//not connected
			else
			{
				format(string, sizeof(string), "   %d Oyuncu aktif değil.", giveplayerid);
				SendClientMessage(playerid, COLOR_GRAD1, string);
			}
			}
			else
			{
				format(string, sizeof(string), " %d  Bu Oyuncu maз Kurmuyor.", giveplayerid);
				SendClientMessage(playerid, COLOR_GRAD1, string);
			}
		return 1;
	}
Reply
#2

anan zaaaaaaaaaaaaaaaaaaaa
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)