OnPlayerEnterVehicle (Message)
#1

Hi guys.
I've try to send a message to the person who enters any vehicle as a driver. I tried this: https://sampforum.blast.hk/showthread.php?tid=254723
and not works, wouldn't compile.

I use strange gamemode, where my OnPlayerEnterVehicle function is other than link typed up.
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{

	if(ispassenger)
	{
		if(GetVehicleModel(vehicleid) == 519)
		{
			IsInShml[playerid]=vehicleid;

			SetPlayerFacingAngle(playerid, 0);
			SetCameraBehindPlayer(playerid);

			SetPlayerInterior(playerid, 1);
			SetPlayerPos(playerid, 1.5527,32.4773,1199.5938);

		}
		return 1;
	}

	if(vehicleid < MaxPojazdow) return 1;

	for(new x=0;x<HOUSES_LOOP;x++){
		if(vehicleid == HouseInfo[x][hCarid]){

			if(HouseID[playerid] != x){
				SendClientMessage(playerid,COLOR_RED2,"To jest prywatny pojazd!");
				SendClientMessage(playerid,COLOR_RED2,"Aby taki mieć musisz kupić dom  /Kupdom");
				new Float:fx,Float:y,Float:z;
				GetPlayerPos(playerid,fx,y,z);
				SetPlayerPos(playerid,fx,y,z+2);
				break;
			}

		}
	}

	
	return 1;
}
Anyone know how help me? ;/
Reply


Messages In This Thread
OnPlayerEnterVehicle (Message) - by Levtu - 20.07.2013, 19:31
Re: OnPlayerEnterVehicle (Message) - by NeroX98 - 20.07.2013, 19:34
Re: OnPlayerEnterVehicle (Message) - by Levtu - 20.07.2013, 19:39
Re: OnPlayerEnterVehicle (Message) - by NeroX98 - 20.07.2013, 19:45
Re: OnPlayerEnterVehicle (Message) - by Levtu - 20.07.2013, 19:56
Re: OnPlayerEnterVehicle (Message) - by NeroX98 - 20.07.2013, 20:03
Re: OnPlayerEnterVehicle (Message) - by Levtu - 20.07.2013, 20:16

Forum Jump:


Users browsing this thread: 6 Guest(s)