IsPlayerInVehicle problem.
#1

Hello guys.. Again a comand doesn't work for me. When i check if the player is in certain vehicle it just skips this part:
Код:
GetPlayerVehicleID(playerid);
	if(IsPlayerInVehicle(playerid, 509 | 481 | 510 | 462 | 448 | 581 | 522 | 461 | 521 | 523 | 463 | 586 | 468 | 471))
 	{
  	SendClientMessage(playerid,COLOR_BRIGHTRED,"Љo komandu nevar izmantot kamēr atrodies uz motocikla.");
  	return 1;
   	}
Код:
if(strcmp(cmdtext, "/neon 2", true)==0)
	{
	if(GetPlayerScore(playerid) >= 7)
	{
	if(IsPlayerInAnyVehicle(playerid))
 	{
  	SendClientMessage(playerid,COLOR_BRIGHTRED,"Tev jāatrodas maљīnā lai izmantotu љo komandu.");
  	return 1;
   	}
   	GetPlayerVehicleID(playerid);
	if(IsPlayerInVehicle(playerid, 509 | 481 | 510 | 462 | 448 | 581 | 522 | 461 | 521 | 523 | 463 | 586 | 468 | 471))
 	{
  	SendClientMessage(playerid,COLOR_BRIGHTRED,"Љo komandu nevar izmantot kamēr atrodies uz motocikla.");
  	return 1;
   	}
   	GetPlayerVehicleID(playerid);
   	if(IsPlayerInVehicle(playerid, 592 | 577 | 511 | 512 | 593 | 553 | 476 | 519 | 460 | 513 | 548 | 425 | 417 | 487 | 488 | 497 | 562 | 447 | 469))
 	{
  	SendClientMessage(playerid,COLOR_BRIGHTRED,"Љo komandu nevar izmantot kamēr atrodies iekљ helikoptera.");
  	return 1;
   	}
	SetPVarInt(playerid, "Status", 1);
	SetPVarInt(playerid, "neon2", neon2[playerid] = CreateObject(18647,0,0,0,0,0,0));
 	SetPVarInt(playerid, "neon3", neon3[playerid] = CreateObject(18647,0,0,0,0,0,0));
  	AttachObjectToVehicle(GetPVarInt(playerid, "neon2"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
   	AttachObjectToVehicle(GetPVarInt(playerid, "neon3"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
    SendClientMessage(playerid, 0xFFFFFFAA, "Neon installed");
	}
	else
	{
	SendClientMessage(playerid, COLOR_BRIGHTRED, "Љo kommandu var izmantot tikai no 7. līmeņa.");
	}
	return 1;
	}
What could be the problem?
Reply


Messages In This Thread
IsPlayerInVehicle problem. - by Shetch - 27.02.2011, 14:49
Re: IsPlayerInVehicle problem. - by Master_Gangster - 27.02.2011, 15:16
Re: IsPlayerInVehicle problem. - by admantis - 27.02.2011, 15:18
Re: IsPlayerInVehicle problem. - by Shetch - 27.02.2011, 15:28
Re: IsPlayerInVehicle problem. - by Shetch - 27.02.2011, 15:52
Re: IsPlayerInVehicle problem. - by Master_Gangster - 27.02.2011, 16:30
Re: IsPlayerInVehicle problem. - by Mean - 27.02.2011, 17:15
Re: IsPlayerInVehicle problem. - by Shetch - 27.02.2011, 22:01
Re: IsPlayerInVehicle problem. - by Spectre - 28.02.2011, 03:01
Re: IsPlayerInVehicle problem. - by Shetch - 07.03.2011, 07:24

Forum Jump:


Users browsing this thread: 1 Guest(s)