
native SetPlayerPosEx(playerid, Float:x, Float:y, Float:z, Float:a);
native IsPlayerInRangeOfVehicle(playerid, vehicleid, Float: radius);
native GetPlayerDistanceFromVehicle(playerid, vehicleid);
native GetPlayerDistanceFromPlayer(playerid, targetid);
native TeleportPlayerToVehicle(playerid, vehicleid);
native TeleportPlayerToPlayer(playerid, targetid);
native SendAdminMessage(color, const message[]);
native SetVehicleInterior(vehicleid, interior);
native GivePlayerWantedLevel(playerid, level);
native RemovePlayerWeapon(playerid, weaponid);
native GetVehicleEngineStatus(vehicleid);
native SetPlayerMoney(playerid, money);
native GetPlayerFacingAnglef(playerid);
native GetPlayerWeaponName(playerid);
native GetVehicleHealthf(vehicleid);
native GetVehicleZAnglef(vehicleid);
native FreezePlayer(playerid, time);
native IsVehicleOccupied(vehicleid);
native ClearPlayerScreen(playerid);
native GetPlayerArmourf(playerid);
native GetPlayerHealthf(playerid);
native IsPlayerSwimming(playerid);
native IsVehicleLocked(vehicleid);
native GetVehicleName(vehicleid);
native UnlockVehicle(vehicleid);
native GetWeaponNamef(weaponid);
native GetPlayerNamef(playerid);
native IsPlayerDriver(playerid);
native GetPlayerIpf(playerid);
native LockVehicle(vehicleid);
native FlipVehicle(vehicleid);
| Function Name | Description |
| GetPlayerNamef | Returns the name of a player. |
| GetPlayerArmourf | Returns the armour of a player . |
| GetPlayerHealthf | Returns the health of a player . |
| GetPlayerFacingAnglef | Returns the facing angle of a player . |
| GetPlayerDistanceFromPlayer | Returns the distance of a player from another player . |
| GetPlayerIpf | Returns the player’s IP. |
| GetPlayerWeaponName | Returns the player’s weapon name. |
| ClearPlayerScreen | Clear the player’s screen. |
| SetPlayerMoney | Sets the player’s money. |
| SetPlayerPosEx | Sets the player’s position and facing angle. |
| GivePlayerWantedLevel | Gives wanted level to player. |
| FreezePlayer | Freezes a player for a period. |
| RemovePlayerWeapon | Remove an especific player’s weapon. |
| IsVehicleOccupied | Return if a vehicle is occupied. |
| LockVehicle | Locks a vehicle. |
| UnlockVehicle | Unlocks a vehicle. |
| GetVehicleName | Returns the vehicle’s name from modelid. |
| GetVehicleZAnglef | Returns the vehicle Z angle . |
| GetVehicleHealthf | Returns the health of a vehicle . |
| GetVehicleEngineStatus | Checks vehicle’s engine status. |
| IsVehicleLocked | Checks if a vehicle is locked. |
| GetWeaponNamef | Return the name of a weapon. |
| SendAdminMessage | Sends a message to rcon admins. |
| IsPlayerInRangeOfVehicle | Returns the if a player is in range of a vehicle. |
| GetPlayerDistanceFromVehicle | Returns the distance of a player from a vehicle . |
| IsPlayerDriver | Checks if a player is a driver. |
| SetVehicleInterior | Macro of LinkVehicleToInterior. |
| FlipVehicle | Flips a vehicle. |
| IsPlayerSwimming | Checks if a player is swimming (by anim). |
| TeleportPlayerToPlayer | Teleports a player to another player. |
| TeleportPlayerToVehicle | Teleports a player to a vehicle. |
|
new message[32]; format(message, sizeof(message), "Hello, %s.", GetPlayerNamef(playerid)); SendClientMessage(playerid, DEFINED_COLOR, message); |
|
Why do some functions end in "f", and why would you want inherently fractional data as an integer? Other than that a not too bad collection.
|
|
I use "f" to the function be similar to the original one (f of formatted), i was used to use Ex (but it is more like Extended(params)).
I return fractional data as an integer because i couldn't return it as float, is there a way to do this? edit: i couldn't return it as float without getting a warning 213: tag mismatch. and Thank you. |
stock Float: ReturnFloat()
{
return 1.0;
}
|
Tag the function with 'Float:' just like a variable, ex:
pawn Код:
|