Jump to content
  • 0

Ajutor.


Bogdan's

Question

Problema intalnita (descriere): Buna,deci nu stiu de ce,dar imi afiseaza de 100000 de mii de ori ce comanda am folosit.Exemplu daca dau /goto la X imi zice ca m-a teleportat de 1000 de ori,deci cum as putea sa scap de acele mesaje cand dau pe /b tot asa,la toate comenzile per general.
Ero(area / rile) / warning-(ul / urile): Nu am erori
Liniile de cod / sursa / script-ul(obligatoriu): Nu am ce sa va arat.
Imagini / Video (optional): Daca doriti postez.
Ati incercat sa rezolvati singur?: Da,m-am uitat in gm poate duplitica SendClientMessage-u da nu face nimic.

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

Buna ziua, incearca comanda [/goto] care o public eu mai jos, dupa care, daca eroarea persista,va rugam sa ne spuneti :

if(strcmp(cmd, "/goto", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
			tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "Tasteaza: /goto [ID/nume jucator]");
				return 1;
			}
			new Float:plocx,Float:plocy,Float:plocz;
			new plo;
			plo = ReturnUser(tmp);
			if (IsPlayerConnected(plo))
			{
			    if(plo != INVALID_PLAYER_ID)
			    {
					if (PlayerInfo[playerid][pAdmin] >= 1 || PlayerInfo[playerid][pAsistent] >= 1)
					{
						if(Spectate[playerid] != 255)
						{
							Spectate[playerid] = 256;
						}
						GetPlayerPos(plo, plocx, plocy, plocz);
						if(PlayerInfo[plo][pInt] > 0)
						{
							SetPlayerInterior(playerid,PlayerInfo[plo][pInt]);
							PlayerInfo[playerid][pInt] = PlayerInfo[plo][pInt];
							PlayerInfo[playerid][pLocal] = PlayerInfo[plo][pLocal];
						}
						if(PlayerInfo[playerid][pInt] == 0)
						{
							SetPlayerInterior(playerid,0);
						}
						if(plocz > 530.0 && PlayerInfo[plo][pInt] == 0)
						{
							SetPlayerInterior(playerid,1);
							PlayerInfo[playerid][pInt] = 1;
						}
						if (GetPlayerState(playerid) == 2)
						{
							new tmpcar = GetPlayerVehicleID(playerid);
							SetVehiclePos(tmpcar, plocx, plocy+4, plocz);
							TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
						}
						else
						{
							SetPlayerPos(playerid,plocx,plocy+2, plocz);
						}
						GetPlayerName(plo, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						format(string, sizeof(string), "Te-ai teleportat cu succes la %s (%d)!", giveplayer, plo);
						SCM(playerid, -1, string);
						new string1[128];
						format(string1, sizeof(string1), "ADMIN INFO: {FFFFFF}Administrator %s (%d) s-a teleportat la jucatorul %s (%d)", sendername,playerid, giveplayer, giveplayerid);
						ABroadCast(COLOR_LIGHTRED, string1, 1);
						SetPlayerInterior(playerid, GetPlayerInterior(plo));
						SetPlayerVirtualWorld(playerid, GetPlayerVirtualWorld(plo));
						GetPlayerName(plo, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
					}
					else
					{
						SendClientMessage(playerid, COLOR_GRAD1, "Nu ai acces la aceasta comanda!");
					}
				}
			}
			else
			{
				format(string, sizeof(string), "Acest jucator este offline!", plo);
				SendClientMessage(playerid, COLOR_GRAD1, string);
			}
		}
		return 1;
	}
Edited by MrAndrei
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.