[Pomoc]


Započeo Erorche, April 23, 2012, 11:46:54 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim: Moje
Detaljan opis problema:kako da napravim ovom cmd da moze samo do bliske igrace ako je igrac daleko da nemoziti /invite ?
Dio skripte:
//------------------------------------------------------------------------------
if(strcmp(cmd, "/invite", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
			tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "Koriscenje: /invite [ID Igraca/Dio Imena]");
				return 1;
			}
			new para1;
			new ftext[20];
			para1 = ReturnUser(tmp);
			if (PlayerInfo[playerid][pLeader] >= 1)
			{
			    if(IsPlayerConnected(para1))
			    {
					if(PlayerInfo[para1][pLevel] < 2)
					{
						SendClientMessage(playerid, COLOR_GREY, "[GRESKA] Igrac mora biti minimum level 2! ");
						return 1;
					}
					if(para1 != INVALID_PLAYER_ID)
			        {
					    if (gTeam[para1]==TEAM_GREEN && PlayerInfo[para1][pMember] == 0 && PlayerInfo[para1][pFMember] == 255)
					    {
					        if(PlayerInfo[playerid][pLeader] == 1) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "LS PD"; ChosenSkin[para1] = 265; SetPlayerSkin(para1, 265); }
					        else if(PlayerInfo[playerid][pLeader] == 2) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "FBI"; ChosenSkin[para1] = 286; SetPlayerSkin(para1, 286); }
					        else if(PlayerInfo[playerid][pLeader] == 4) { PlayerInfo[para1][pTeam] = 1; gTeam[para1] = 1; ftext = "Hitna Pomoc"; ChosenSkin[para1] = 274; SetPlayerSkin(para1, 274); }
					        else if(PlayerInfo[playerid][pLeader] == 5) { PlayerInfo[para1][pTeam] = 5; gTeam[para1] = 5; ftext = "The Russian Mafia"; ChosenSkin[para1] = 126; SetPlayerSkin(para1, 126); }
					        else if(PlayerInfo[playerid][pLeader] == 6) { PlayerInfo[para1][pTeam] = 6; gTeam[para1] = 6; ftext = "The Escobar Cartel"; ChosenSkin[para1] = 98; SetPlayerSkin(para1, 98); }
                            else if(PlayerInfo[playerid][pLeader] == 7) { PlayerInfo[para1][pTeam] = 7; gTeam[para1] = 7; ftext = "Vlada"; ChosenSkin[para1] = 61; SetPlayerSkin(para1, 61); }
					        else if(PlayerInfo[playerid][pLeader] == 9) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "[SE:RT] Novinari"; ChosenSkin[para1] = 17; SetPlayerSkin(para1, 17); }
					        else if(PlayerInfo[playerid][pLeader] == 10) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Taxi Company"; ChosenSkin[para1] = 182; SetPlayerSkin(para1, 182); }
					        else if(PlayerInfo[playerid][pLeader] == 12) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Parking Servis"; ChosenSkin[para1] = 8; SetPlayerSkin(para1, 8); }
					        else if(PlayerInfo[playerid][pLeader] == 15) { PlayerInfo[para1][pTeam] = 15; gTeam[para1] = 15; ftext = "Los Santos Vagos"; ChosenSkin[para1] = 108; SetPlayerSkin(para1, 108); }
					        else if(PlayerInfo[playerid][pLeader] == 16) { PlayerInfo[para1][pTeam] = 16; gTeam[para1] = 16; ftext = "Grove Street Family"; ChosenSkin[para1] = 106; SetPlayerSkin(para1, 106); }
					        else { return 1; }
							GetPlayerName(para1, giveplayer, sizeof(giveplayer));
							GetPlayerName(playerid, sendername, sizeof(sendername));
							PlayerInfo[para1][pMember] = PlayerInfo[playerid][pLeader];
							PlayerInfo[para1][pRank] = 1;
							printf("AdmCmd: %s je pozvao %s-a da se pridruzi %s.", sendername, giveplayer, ftext);
							format(string, sizeof(string), "[INFO] {FFFFFF}Pozvani ste u %s, pozvao vas je Lider %s", ftext, sendername);
							SendClientMessage(para1, COLOR_LIGHTBLUE, string);
							format(string, sizeof(string), "[INFO] {FFFFFF}Pozvali ste %s-a da se pridruzi %s.", giveplayer,ftext);
							SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
						}
						else
						{
						    SendClientMessage(playerid, COLOR_GREY, "[ODBIJENO] Taj igrac ima wanted level ili je u drugoj organizaciji.");
						    return 1;
						}
					}
				}
			}
			else
			{
				SendClientMessage(playerid, COLOR_GRAD1, "[GRESKA] Samo Lideri mogu koristiti ovu komandu!");
			}
		}
		return 1;
	}

Neke slike/video za lakse dobivanje pomoci(neobavezno)://
Macedonia <3 !

Koristis   
if (ProxDetectorS(5.0, playerid, giveplayerid))

daj mi u gotove skripte...
Macedonia <3 !

Gotti747

*

Ne mogu da shvatim podelu, kao sto je balkanska...

Citat: Erorche poslato April 23, 2012, 11:51:44 PRE PODNE
daj mi u gotove skripte...

Ne moze sve na gotovo, prouci malo ProxDetector funkciju..
Citat: ...Neno... poslato Januar 26, 2013, 23:31:02 POSLE PODNE
Poceo sam mapati i tu je doslo do problema.Nakon par mapa,vidio sam post Gottia i kaze da nista nevalja da je katastrofa,i pocnemo se svadjati,psovati.Popusimo bananu obojica,i nakon toga nesto sam napravio (mapu) i Gotti kaze dobra,uh reko opet me zajebava,i saljem ja njemu na pm reko ti mene zajebavas,kaze on ne,i pomirimo se.Nakon toga postali smo dosta dobri

Rjeseno, Hfala za silom.. :D
Macedonia <3 !