23.03.2012, 16:01
(
Последний раз редактировалось QuaTTrO; 24.03.2012 в 07:10.
)
Make something like MapAndreas but client-side and using GTA Engine so it will be work for created objects
Example:
This will be can used for OnPlayerClickMap or airstrike system
pawn Код:
native Float:GetPlayerGroundZ(playerid, Float:x, Float:y, Float:z);
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp("/undercover", cmdtext, true) == 0)
{
new Float:x, Float:y, Float:z
new Float:gz;
GetPlayerPos(playerid, x, y, z);
gz = GetPlayerGroundZ(playerid, x, y, 400);
if(gz == z) SendClientMessage(playerid, -1, "You are not under cover");
else SendClientMessage(playerid, -1, "You are undercover");
return 1;
}
return 0;
{

