Warning 217: loose indentation
#1

Hello!
I am getting 2 error in my script can someone please fix it. Thank you

Here is the code;
Quote:

//enter
if (strcmp("/enter", cmdtext, true, 10) == 0)
{
if(IsPlayerInRangeOfPoint(playerid, 2.5, 2690.3850,-1511.2466,30.6013))//garage1
{
SetPlayerPos(playerid,2688.5320,-1515.0651,6.3116);
}
if(IsPlayerInRangeOfPoint(playerid, 2.5, 2660.2078,-1569.8726,6.3022))//garage2
{
SetPlayerPos(playerid,2695.8667,-1530.7009,-12.9733);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2677.9819,-1502.7472,30.5875))//door1
{
SetPlayerPos(playerid,2675.6777,-1503.8555,-12.9141);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2660.3020,-1544.5735,-12.9819))//KojiOffice
{
SetPlayerPos(playerid,2698.4766,-1567.9470,34.2633);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2658.0918,-1544.1715,-12.9817))//DirectorOffice
{
SetPlayerPos(playerid,2665.0110,-1532.1143,39.0994);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2706.9485,-1526.7321,47.0547))//ZRoof
{
SetPlayerPos(playerid,2648.0857,-1544.4661,-6.7801);
}
return 1;
}
// Exiting
if (strcmp("/exit", cmdtext, true, 10) == 0)
{
if(IsPlayerInRangeOfPoint(playerid, 2.5, 2688.5320,-1515.0651,6.3116))//garage1
{
SetPlayerPos(playerid,2690.3850,-1511.2466,30.6013);
}
if(IsPlayerInRangeOfPoint(playerid, 2.5, 2695.8667,-1530.7009,-12.9733))//garage2
{
SetPlayerPos(playerid,2660.2078,-1569.8726,6.3022);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2675.6777,-1503.8555,-12.9141))//door1
{
SetPlayerPos(playerid,2677.9819,-1502.7472,30.5875);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2698.4766,-1567.9470,34.2633))//KojiOffice
{
SetPlayerPos(playerid,2660.3020,-1544.5735,-12.9819);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2665.0110,-1532.1143,39.0994))//DirectorOffice
{
SetPlayerPos(playerid,2658.0918,-1544.1715,-12.9817);
}
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2648.0857,-1544.4661,-6.7801))//ZRoof
{
SetPlayerPos(playerid,2706.9485,-1526.7321,47.0547);
}
return 1;
}
return 0;
}

Its the error;
Quote:

C:\Users\Basit & Wajahat\Desktop\ZaibatsuHQ.pwn(473) : warning 217: loose indentation
C:\Users\Basit & Wajahat\Desktop\ZaibatsuHQ.pwn(502) : warning 217: loose indentation
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Warnings.

Reply
#2

Have you actually ever heard of indentation? ._.

https://www.******.co.uk/search?q=how+to+indent+code
Reply
#3

Quote:
Originally Posted by MP2
Посмотреть сообщение
Have you actually ever heard of indentation? ._.

https://www.******.co.uk/search?q=how+to+indent+code
Yes, but i don't know how to fix it. i tried much but still getting the same error. can someone just fix this code, it would be helpful and great for me.
Reply
#4

Hey, use this to indent your code:
Just click me.

Put your code like it is from the script.
Reply
#5

Quote:
Originally Posted by JimmyCh
Посмотреть сообщение
Hey, use this to indent your code:
Just click me.

Put your code like it is from the script.
Thank you so much bro, it fixed 1+Rep
Reply
#6

Код:
//enter
if (strcmp("/enter", cmdtext, true, 10) == 0)
{
	if(IsPlayerInRangeOfPoint(playerid, 2.5, 2690.3850,-1511.2466,30.6013))//garage1
	{
		SetPlayerPos(playerid,2688.5320,-1515.0651,6.3116);
	}
	if(IsPlayerInRangeOfPoint(playerid, 2.5, 2660.2078,-1569.8726,6.3022))//garage2
	{
		SetPlayerPos(playerid,2695.8667,-1530.7009,-12.9733);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2677.9819,-1502.7472,30.5875))//door1
	{
		SetPlayerPos(playerid,2675.6777,-1503.8555,-12.9141);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2660.3020,-1544.5735,-12.9819))//KojiOffice
	{
		SetPlayerPos(playerid,2698.4766,-1567.9470,34.2633);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2658.0918,-1544.1715,-12.9817))//DirectorOffice
	{
		SetPlayerPos(playerid,2665.0110,-1532.1143,39.0994);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2706.9485,-1526.7321,47.0547))//ZRoof
	{
		SetPlayerPos(playerid,2648.0857,-1544.4661,-6.7801);
	}
	return 1;
}
// Exiting
if (strcmp("/exit", cmdtext, true, 10) == 0)
{
	if(IsPlayerInRangeOfPoint(playerid, 2.5, 2688.5320,-1515.0651,6.3116))//garage1
	{
		SetPlayerPos(playerid,2690.3850,-1511.2466,30.6013);
	}
	if(IsPlayerInRangeOfPoint(playerid, 2.5, 2695.8667,-1530.7009,-12.9733))//garage2
	{
		SetPlayerPos(playerid,2660.2078,-1569.8726,6.3022);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2675.6777,-1503.8555,-12.9141))//door1
	{
		SetPlayerPos(playerid,2677.9819,-1502.7472,30.5875);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2698.4766,-1567.9470,34.2633))//KojiOffice
	{
		SetPlayerPos(playerid,2660.3020,-1544.5735,-12.9819);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2665.0110,-1532.1143,39.0994))//DirectorOffice
	{
		SetPlayerPos(playerid,2658.0918,-1544.1715,-12.9817);
	}
	if(IsPlayerInRangeOfPoint(playerid, 1.0, 2648.0857,-1544.4661,-6.7801))//ZRoof
	{
		SetPlayerPos(playerid,2706.9485,-1526.7321,47.0547);
	}
	return 1;
}
return 0;
}
easy

EDIT: NVM HE FIXED IT
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)