Skip to content
This repository was archived by the owner on Feb 19, 2020. It is now read-only.

SetPlayerJetpackHeight

GtakillerIV edited this page Nov 13, 2014 · 3 revisions

SetPlayerJetpackHeight

Sets the max achievable height gain able with a jet pack.

tip Default value is 100.00


Parameters

playerid

The player's id.

float:height

The new height limit.

Returns

    0 if player is not connected

Usage

CMD:setmaxheight(playerid, params[])
{
	//If the player has the SA-MP+ plugin installed
	if(IsUsingSAMPP(playerid))
	{
		new Float:height;
		//If the entered parameters are incorrect, show him a message displaying the correct ones
		if(sscanf(params, "f", height)) return SendClientMessage(playerid, -1, "Correct usage: /setmaxheight height");

		//Set the max gainable height with a jetpack
		SetPlayerJetpackHeight(playerid, height);

		SendClientMessage(playerid, -1, "New max height set!");
	}
	else
	{
		SendClientMessage(playerid, -1, "You need the SA-MP+ plugin");
	}

	return 1;
}

See also

GetPlayerJetpackHeight

GetPlayerAircraftHeight

SetPlayerAircraftHeight

Clone this wiki locally