if(Tut[playerid]==1)
{
new Float:xPos, Float:yPos, Float:zPos, Float:Angle;
GetPlayerPos(playerid,xPos,yPos,zPos);
GetPlayerFacingAngle(playerid,Angle);
if(TutTime[playerid]==0)
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,55.55,55.55,55.55);
SetPlayerCameraPos(playerid,66.66,66.66,66);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,59,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==15)
{
SetPlayerPos(playerid,66.66,66.66,66.66);
SetPlayerCameraPos(playerid,77.77,77.77,77);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,61,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==25)
{
SetPlayerPos(playerid,77.77,77.77,77.77);
SetPlayerCameraPos(playerid,88.88,88.88,88);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,62,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==60)
{
Tut[playerid]=0;
SetPlayerPos(playerid,xPos,yPos,zPos);
SetPlayerFacingAngle(playerid,Angle);
}
}
if(Tut[playerid]==1)
{
new Float:xPos, Float:yPos, Float:zPos, Float:Angle;
GetPlayerPos(playerid,xPos,yPos,zPos);
GetPlayerFacingAngle(playerid,Angle);
new TutX; //tried new Float:TutX
new TutY; //tried new Float:TutY
new TutZ; //tried new Float:TutZ
TutX[playerid]=xPos; //tried putting "Float" to both
TutY[playerid]=YPoz; //tried putting "Float" to both
TutZ[playerid]=zPos; //tried putting "Float" to both
TutA[playerid]=Angle; //tried putting "Float" to both
if(TutTime[playerid]==0)
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,55.55,55.55,55.55);
SetPlayerCameraPos(playerid,66.66,66.66,66);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,59,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==15)
{
SetPlayerPos(playerid,66.66,66.66,66.66);
SetPlayerCameraPos(playerid,77.77,77.77,77);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,61,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==25)
{
SetPlayerPos(playerid,77.77,77.77,77.77);
SetPlayerCameraPos(playerid,88.88,88.88,88);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,62,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==60)
{
Tut[playerid]=0;
SetPlayerPos(playerid,TutX,TutY,TutZ);
SetPlayerFacingAngle(playerid,TutA);
}
}
C:\SAMP\mod1.pwn(2671) : error 028: invalid subscript (not an array or too many subscripts): "TutX"
C:\SAMP\mod1.pwn(2671) : warning 215: expression has no effect
C:\SAMP\mod1.pwn(2671) : error 001: expected token: ";", but found "]"
C:\SAMP\mod1.pwn(2671) : error 029: invalid expression, assumed zero
C:\SAMP\mod1.pwn(2671) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
Of course, I tried them.
pawn Код:
pawn Код:
I should have wrote it first time, but I thought it was obvious. |
new Float:TutX[MAX_PLAYERS],Float:TutY[MAX_PLAYERS],Float:TutZ[MAX_PLAYERS],Float:TutA[MAX_PLAYERS];
pawn Код:
|
if(Tut[playerid]==1)
{
new Float:xPos, Float:yPos, Float:zPos, Float:Angle;
GetPlayerPos(playerid,xPos,yPos,zPos);
GetPlayerFacingAngle(playerid,Angle);
new Float:TutX[MAX_PLAYERS],Float:TutY[MAX_PLAYERS],Float:TutZ[MAX_PLAYERS],Float:TutA[MAX_PLAYERS];
TutX[playerid]=xPos;
TutY[playerid]=YPos;
TutZ[playerid]=zPos;
TutA[playerid]=Angle;
if(TutTime[playerid]==0)
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,55.55,55.55,55.55);
SetPlayerCameraPos(playerid,66.66,66.66,66);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,59,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==15)
{
SetPlayerPos(playerid,66.66,66.66,66.66);
SetPlayerCameraPos(playerid,77.77,77.77,77);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,61,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==25)
{
SetPlayerPos(playerid,77.77,77.77,77.77);
SetPlayerCameraPos(playerid,88.88,88.88,88);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,62,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==60)
{
Tut[playerid]=0;
SetPlayerPos(playerid,TutX,TutY,TutZ); //2783
SetPlayerFacingAngle(playerid,TutA); //2784
}
telPos[0][playerid]=TutX;telPos[1][playerid]=TutY; // 2789 sorry forgot to mention, this is anti cheat teleport, in this line telPos[0] must be equal to X coordiante, telPos[1] = Y coordinate
}
C:\SAMP\mod1.pwn(2783) : error 035: argument type mismatch (argument 2)
C:\SAMP\mod1.pwn(2784) : error 035: argument type mismatch (argument 2)
C:\SAMP\mod1.pwn(2789) : error 006: must be assigned to an array
C:\SAMP\mod1.pwn(2789) : error 006: must be assigned to an array
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
pawn Код:
pawn Код:
|
new Float:TutX[MAX_PLAYERS],Float:TutY[MAX_PLAYERS],Float:TutZ[MAX_PLAYERS],Float:TutA[MAX_PLAYERS];
SetPlayerPos(playerid,TutX[playerid],TutY[playerid],TutZ[playerid]); //2783
SetPlayerFacingAngle(playerid,TutA[playerid]); //2784
if(Tut[playerid]==1)
{
new Float:xPos, Float:yPos, Float:zPos, Float:Angle;
GetPlayerPos(playerid,xPos,yPos,zPos);
GetPlayerFacingAngle(playerid,Angle);
new Float:TutX[MAX_PLAYERS],Float:TutY[MAX_PLAYERS],Float:TutZ[MAX_PLAYERS],Float:TutA[MAX_PLAYERS];
TutX[playerid]=xPos;
TutY[playerid]=YPos;
TutZ[playerid]=zPos;
TutA[playerid]=Angle;
if(TutTime[playerid]==0)
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,55.55,55.55,55.55);
SetPlayerCameraPos(playerid,66.66,66.66,66);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,59,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==15)
{
SetPlayerPos(playerid,66.66,66.66,66.66);
SetPlayerCameraPos(playerid,77.77,77.77,77);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,61,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==25)
{
SetPlayerPos(playerid,77.77,77.77,77.77);
SetPlayerCameraPos(playerid,88.88,88.88,88);
SetPlayerCameraLookAt(playerid,-99.9877,-5678.1234,2.0367);
ShowPlayerDialog(playerid,62,DIALOG_STYLE_MSGBOX,"Tutorial","My message","OK","");
}
if(TutTime[playerid]==60)
{
Tut[playerid]=0;
SetPlayerPos(playerid,TutX[playerid],TutY[playerid],TutZ[playerid]); //2783
SetPlayerFacingAngle(playerid,TutA[playerid]); //2784
}
telPos[0][playerid]=TutX[playerid];telPos[1][playerid]=TutY[playerid]; // 2789 sorry forgot to mention, this is anti cheat teleport, in this line telPos[0] must be equal to X coordiante, telPos[1] = Y coordinate.
}