03.09.2013, 17:19
Hey everyone.
I'm needing some pointers on what I'm doing wrong, here.
No matter how I put this, it continues to show the default LookAt point when connecting to the server.
Any ideas would be appreciated.
I've tried putting it at the top, the end, and in the dialogs. The camera will not go nor move. It just sits at the default camera position that SA-MP has!
I'm needing some pointers on what I'm doing wrong, here.
No matter how I put this, it continues to show the default LookAt point when connecting to the server.
pawn Код:
public OnPlayerConnect(playerid)
{
playerOnline++;
ResetVars(playerid);
ConnectVars(playerid);
new Query[300],string[128],pname[24],escpname[24];
GetPlayerName(playerid,pname,24);
mysql_real_escape_string(pname, escpname);
format(Query, sizeof(Query), "SELECT * FROM `users` WHERE `Username` = '%s'", escpname);
mysql_query(Query);
mysql_store_result();
if(mysql_num_rows() != 0)
{
InterpolateCameraLookAt(playerid, -1971.6453,137.9267,27.6875, 1582.3514,-1732.9550,20.9012, 32000);
format(string,sizeof(string),""chat" Welcome back %s",PlayerName(playerid));
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD,string,""chat" Our system have detected your username registered please login","Login","Quit");
}
else
{
InterpolateCameraLookAt(playerid, -1971.6453,137.9267,27.6875, 1582.3514,-1732.9550,20.9012, 32000);
format(string,sizeof(string),""chat" Hello %s to "NAME"",PlayerName(playerid));
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD,string,""chat" Welcome to "NAME" you'll be forced to register please click register!","Register","Quit");
}
mysql_free_result();
return 1;
}
I've tried putting it at the top, the end, and in the dialogs. The camera will not go nor move. It just sits at the default camera position that SA-MP has!