Just warnings ...
#1

Hey guys ! Can someone help me with these warnings ? Thanks.
pawn Код:
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(8120) : warning 217: loose indentation
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(8140) : warning 217: loose indentation
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(8294) : warning 217: loose indentation
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(10228) : warning 217: loose indentation
Line 8120 :
pawn Код:
if(strcmp(cmdtext,"/respawnv",true)==0)
Line 8140 :
pawn Код:
if (!strcmp("/v Landstalker", cmdtext, true))
Line 8294 :
pawn Код:
if (!strcmp("/v Pony", cmdtext, true))
Line 10228 :
pawn Код:
return 0;
Reply
#2

loose indentications are speces that aren't allowed to be there, like this:
Код:
     if(cookie == 1)
{
nocookie = 1;
}
That would give a loose indentication cause of the spaces or tabs.
Reply
#3

Ohh .. thanks.I fixed it.
Reply
#4

Nice to hear i helped you, feel free to send me a pm if you need any further help.
Reply
#5

Hmmm.Just one more warning :
pawn Код:
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(10317) : warning 217: loose indentation
Command :
pawn Код:
if (!strcmp("/v Boxville2", cmdtext, true))
    {
        if(SpawnedVehicles[playerid] != 0) DestroyVehicle(SpawnedVehicles[playerid]);
        new Float:X,Float:Y,Float:Z,Float:ROT;
        GetPlayerPos(playerid,X,Y,Z);
        GetPlayerFacingAngle (playerid,ROT);
        SetVehicleNumberPlate(SpawnedVehicles[playerid] = CreateVehicle(606,X,Y,Z,ROT,-1,-1,60), "{0049FF}D{F3FF02}K{F81414}R");
        PutPlayerInVehicle(playerid,SpawnedVehicles[playerid],0);
        GameTextForPlayer(playerid,"~h~~w~Boxville 2~n~~h~~w~ID:~h~~r~606",2500,1);
        return 1;
    }
    return 0; // Here is the warning.
}
Reply
#6

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (!strcmp("/v Boxville2", cmdtext, true))
    {
        if(SpawnedVehicles[playerid] != 0) DestroyVehicle(SpawnedVehicles[playerid]);
        new Float:X,Float:Y,Float:Z,Float:ROT;
        GetPlayerPos(playerid,X,Y,Z);
        GetPlayerFacingAngle (playerid,ROT);
        SetVehicleNumberPlate(SpawnedVehicles[playerid] = CreateVehicle(606,X,Y,Z,ROT,-1,-1,60), "{0049FF}D{F3FF02}K{F81414}R");
        PutPlayerInVehicle(playerid,SpawnedVehicles[playerid],0);
        GameTextForPlayer(playerid,"~h~~w~Boxville 2~n~~h~~w~ID:~h~~r~606",2500,1);
        return 1;
    }
    return 0;
}
Is it indented like this?

Also, if indentations don't bother you, you can always use this at the top of your script:

pawn Код:
#pragma tabsize 0
Reply
#7

answered the pm of you too, the same answer as austin actually.
Reply
#8

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (!strcmp("/v Boxville2", cmdtext, true))
    {
        if(SpawnedVehicles[playerid] != 0) DestroyVehicle(SpawnedVehicles[playerid]);
        new Float:X,Float:Y,Float:Z,Float:ROT;
        GetPlayerPos(playerid,X,Y,Z);
        GetPlayerFacingAngle (playerid,ROT);
        SetVehicleNumberPlate(SpawnedVehicles[playerid] = CreateVehicle(606,X,Y,Z,ROT,-1,-1,60), "{0049FF}D{F3FF02}K{F81414}R");
        PutPlayerInVehicle(playerid,SpawnedVehicles[playerid],0);
        GameTextForPlayer(playerid,"~h~~w~Boxville 2~n~~h~~w~ID:~h~~r~606",2500,1);
        return 1;
    }
return 0;
}
Reply
#9

I tried all ... but still giving me
pawn Код:
C:\Users\Win7\Desktop\Stunt King Romania 0.3d\Server\gamemodes\SKR.pwn(10317) : warning 217: loose indentation
Reply
#10

Try this one below
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (!strcmp("/v Boxville2", cmdtext, true))
{
if(SpawnedVehicles[playerid] != 0) DestroyVehicle(SpawnedVehicles[playerid]);
new Float:X,Float:Y,Float:Z,Float:ROT;
GetPlayerPos(playerid,X,Y,Z);
GetPlayerFacingAngle (playerid,ROT);
SetVehicleNumberPlate(SpawnedVehicles[playerid] = CreateVehicle(606,X,Y,Z,ROT,-1,-1,60), "{0049FF}D{F3FF02}K{F81414}R");
PutPlayerInVehicle(playerid,SpawnedVehicles[playerid],0);
GameTextForPlayer(playerid,"~h~~w~Boxville 2~n~~h~~w~ID:~h~~r~606",2500,1);
return 1;
}
return 0;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)