Help with Dynamic Pickups and OnPlayerPickUpDynamicPickup
#5

Quote:
Originally Posted by JaydenJason
Посмотреть сообщение
Teleports you back? Do you immediately set the player's position once the pickup has been picked up? If so you could try getting XY infront of the pickup (GetXYInfrontOfPlayer while making the pickup) And set the exit position to the position infront of the pickup.

Код:
GetXYInFrontOfPlayer(playerid, &Float:x, &Float:y, Float:distance)
{
	new Float:a;
	GetPlayerPos(playerid, x, y, a);
	GetPlayerFacingAngle(playerid, a);
	if (GetPlayerVehicleID(playerid))
	{
	  GetVehicleZAngle(GetPlayerVehicleID(playerid), a);
	}
	x += (distance * floatsin(-a, degrees));
	y += (distance * floatcos(-a, degrees));
}
Let's hope this is going to work, and yes the interior and the exterior are where the pickups are located cause they are dynamic used by /enter and /exit currently but I want to make it easier for players to enter/exit interiors without typing any command.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)