InterpolateCameraPos Stop Issue
#1

Hello, perspectives sometimes stops. What is the reason for this ?
I'm sorry for my bad English.
Reply
#2

Help !
Reply
#3

Without code, no idea.

Could be SetPlayerCameraPos, SetPlayerCameraLookAt, TogglePlayerSpectating, or any other camera related functions.
Reply
#4

Quote:
Originally Posted by Threshold
Посмотреть сообщение
Without code, no idea.

Could be SetPlayerCameraPos, SetPlayerCameraLookAt, TogglePlayerSpectating, or any other camera related functions.
Here's the code:

Код:
public OnPlayerConnect(playerid)
{
SetPVarInt(playerid,"GirisEkran",1);
return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1455.6040,-1067.5613,213.3759);
	SetPlayerFacingAngle(playerid, 269.8772);
    AnimFix(playerid,"DANCING","DNCE_M_B",4.0,1,0,0,0,-1);
	PlayerPlaySound(playerid, 1089, 0.0, 0.0, 0.0);
    SetPlayerColor(playerid,OLU_RENK);
    TakimMeslegi(playerid,classid);
	return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
	case DIALOG_GIRIS:
	{
		if(!response) return kickat(playerid,1,"");
		if(!strlen(inputtext))
		{
		new str[128];
		girisMenu(playerid);
		HataliSifre[playerid]++;
		format(str,sizeof(str),"{FF5630}Giriş haklarınız tьkeniyor. Kalan hakkınız: [%d/%d]",HataliSifre[playerid],Hatali_Giris);
		SendClientMessage(playerid,-1,str);
		if(HataliSifre[playerid] == Hatali_Giris)
		{
		HataliSifre[playerid] = 0;
		kickat(playerid,2,"");
		return 1;
		}
		return 1;
		}

		new hashed_pass[129];
		WP_Hash(hashed_pass, sizeof(hashed_pass), code(inputtext));
		if(strcmp(hashed_pass, PlayerInfo[playerid][pSifre]) == 0)
		{
			ResetPlayerMoney(playerid);
			//GivePlayerMoney(playerid, PlayerInfo[playerid][pPara]);
			Paraver(playerid, PlayerInfo[playerid][pPara]);
			SetPlayerScore(playerid,PlayerInfo[playerid][pSkor]);
			SendClientMessage(playerid,-1,"{C3FF4A}Hesap: {FFFFFF}Verileriniz başarıyla yьklendi, iyi oyunlar !");
			new ip[24],query[128],serialCek[60];
			GetPlayerIp(playerid, ip, sizeof(ip));
			PlayerInfo[playerid][IPadresim] = ip;
			mysql_format(g_SQL, query, sizeof(query), "UPDATE `oyuncudata` SET `IPAdress` = '%s' WHERE `id` = '%d' LIMIT 1", PlayerInfo[playerid][IPadresim], PlayerInfo[playerid][xxID]);
			mysql_tquery(g_SQL, query);
			gpci(playerid,serialCek,sizeof(serialCek));
			PlayerInfo[playerid][serialID] = serialCek;
			mysql_format(g_SQL, query, sizeof(query), "UPDATE `oyuncudata` SET `SerialID` = '%s' WHERE `id` = '%d' LIMIT 1", PlayerInfo[playerid][serialID], PlayerInfo[playerid][xxID]);
			mysql_tquery(g_SQL, query);
			SendClientMessage(playerid,0x9D6DFCFF,"Spawn olmak istediğiniz Şehri seзin !");
			VipSureKontrol(playerid);
			if(GetPVarInt(playerid,"GirisEkran") == 1)
			{
			InterpolateCameraPos(playerid, 1800.654907, -1061.519897, 133.729736, 1752.653686, -1192.006835, 109.957901, 3000);
			InterpolateCameraLookAt(playerid, 1800.587890, -1066.482055, 133.119201, 1747.654418, -1191.947631, 109.899307, 3000);
			DeletePVar(playerid,"GirisEkran");
			}
			for(new i; i < 46; i++) TextDrawShowForPlayer(playerid, CitySelect[i]);
			SelectTextDraw(playerid, 0xA3B4C5FF);
		}
		else
		{
			new str[128];
			girisMenu(playerid);
			HataliSifre[playerid]++;
			format(str,sizeof(str),"{FF5630}Giriş haklarınız tьkeniyor. Kalan hakkınız: [%d/%d]",HataliSifre[playerid],Hatali_Giris);
			SendClientMessage(playerid,-1,str);
			if(HataliSifre[playerid] == Hatali_Giris)
			{
			HataliSifre[playerid] = 0;
			kickat(playerid,2,"");
			return 1;
			}
		}
	}
return 1;
}
		
public OnPlayerClickTextDraw(playerid, Text:clickedid)
{
if (clickedid != Text:INVALID_TEXT_DRAW)
{
	if(clickedid == CitySelect[43])
	{
	InterpolateCameraPos(playerid, 1728.425781, -1200.589477, 127.501785, 1462.241333, -1067.531494, 214.152999, 3000);
	InterpolateCameraLookAt(playerid, 1723.444824, -1200.474243, 127.081619, 1457.246582, -1067.497802, 213.926834, 3000);
	}else if(clickedid == CitySelect[44])
	{
	InterpolateCameraPos(playerid, 1728.425781, -1200.589477, 127.501785, 1462.241333, -1067.531494, 214.152999, 3000);
	InterpolateCameraLookAt(playerid, 1723.444824, -1200.474243, 127.081619, 1457.246582, -1067.497802, 213.926834, 3000);
	}
	else if(clickedid == CitySelect[45])
	{
	InterpolateCameraPos(playerid, 1728.425781, -1200.589477, 127.501785, 1462.241333, -1067.531494, 214.152999, 3000);
	InterpolateCameraLookAt(playerid, 1723.444824, -1200.474243, 127.081619, 1457.246582, -1067.497802, 213.926834, 3000);
	}
	CancelSelectTextDraw(playerid);
}
return 1;
}
Reply
#5

Try removing the CancelSelectTextDraw(playerid); and see if it still happens. I assume you're referring to the code under OnPlayerClickTextDraw in this instance.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)