SA-MP Forums Archive
Gate Commands - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Gate Commands (/showthread.php?tid=429517)



Gate Commands - Cheynoa - 09.04.2013

Код:
COMMAND:bcsdo(playerid, params[])
{
	for (new i = 0; i < APPROX_PLAYERS; i++)
 	{
	   if (IsPlayerConnected(i) )
	   {
  		 if(gteam[i]==Team_LSPD)
 		 {
		 	MoveObject(BCSDDoor1, -227.91, 1214.85, 19.66, 2 ,0.00, 0.00, 0.00);
		 	MoveObject(BCSDDoor2, -232.86, 1214.87, 19.66, 2 ,0.00, 0.00, 179.46);
         	}
		}
	}
	return 1;
}
COMMAND:bcsdc(playerid, params[])
{
	for (new i = 0; i < APPROX_PLAYERS; i++)
 	{
	   if (IsPlayerConnected(i) )
	   {
	     if(gteam[i]==Team_LSPD)
		 {
		 	MoveObject(BCSDDoor1, -229.5500000, 1214.85, 19.66, 2 ,0.00, 0.00, 0.00);
		 	MoveObject(BCSDDoor2, -231.2700000, 1214.85, 19.66, 2 ,0.00, 0.00, 179.46);
			}
		}
	}
	return 1;
}
ERROR:
Код:
C:\Users\Owner\Desktop\BC ELGIN RP\gamemodes\ProjectElgin.pwn(36600) : error 076: syntax error in the expression, or invalid function call
C:\Users\Owner\Desktop\BC ELGIN RP\gamemodes\ProjectElgin.pwn(36601) : error 076: syntax error in the expression, or invalid function call
C:\Users\Owner\Desktop\BC ELGIN RP\gamemodes\ProjectElgin.pwn(36615) : error 076: syntax error in the expression, or invalid function call
C:\Users\Owner\Desktop\BC ELGIN RP\gamemodes\ProjectElgin.pwn(36616) : error 076: syntax error in the expression, or invalid function call



Re: Gate Commands - iJumbo - 09.04.2013

Lines 36600,36601,36615,36616 are?


Re: Gate Commands - Cheynoa - 09.04.2013

Same error and the lines the error is talking about are the MoveObject lines


Re: Gate Commands - iJumbo - 09.04.2013

How you define BCSDDoor1 BCSDDoor2 vars?

EDIT: Like

pawn Код:
new BCSDDoor1,BCSDDoor2;

BCSDDoor1 = createobject bla bla
are you using BCSDDoor1 BCSDDoor2 as functions too ?


Re: Gate Commands - Cheynoa - 09.04.2013

Yes I did


Re: Gate Commands - Cheynoa - 09.04.2013

And they have the same error

Код:
BCSDDoor1 = CreateObject(19303, -229.55, 1214.85, 19.66,   0.00, 0.00, 0.00);
BCSDDoor2 = CreateObject(19303, -231.27, 1214.85, 19.66,   0.00, 0.00, 179.46);



Re: Gate Commands - iJumbo - 09.04.2013

You have function with BCSDDoor1 and BCSDDoor2 name?


Re: Gate Commands - Pottus - 09.04.2013

This code doesn't really make sense you only need to move an object once whats up with this code? Also error on line 36616 your game mode must be a serious pain in the ass to try and work with use includes and create modules throwing that much code into a single file and trying to edit it is silly.


Re: Gate Commands - Cheynoa - 10.04.2013

Quote:
Originally Posted by [uL]Pottus
Посмотреть сообщение
This code doesn't really make sense you only need to move an object once whats up with this code? Also error on line 36616 your game mode must be a serious pain in the ass to try and work with use includes and create modules throwing that much code into a single file and trying to edit it is silly.
Look if your not going to help then don't bother commenting.