03.03.2009, 10:05
public OnPlayerPickUpPickup(playerid, pickupid)
{
if (pickupid == HealthArmour)
AddStaticPickup(1272, 2, -83.0494, 9.7471, 3.1172);
new tag[10], name[30];
GetPlayerName(playerid, name, 30);
format(tag, 10, "[Y]", tag);
Teleport(playerid, 2324.419921, -1145.568359, 1050.710083, 88.2612, 12, false);
if(strfind(name, tag, true) == -1)
{
SendClientMessage(playerid, COLOR_GREEN, "You cannot teleport to this place as you are not in The Yardies gang.");
return 1;
}
return Teleport(playerid, 2324.419921, -1145.568359, 1050.710083, 88.2612, 12, false);
}
What am I doing wrong?
{
if (pickupid == HealthArmour)
AddStaticPickup(1272, 2, -83.0494, 9.7471, 3.1172);
new tag[10], name[30];
GetPlayerName(playerid, name, 30);
format(tag, 10, "[Y]", tag);
Teleport(playerid, 2324.419921, -1145.568359, 1050.710083, 88.2612, 12, false);
if(strfind(name, tag, true) == -1)
{
SendClientMessage(playerid, COLOR_GREEN, "You cannot teleport to this place as you are not in The Yardies gang.");
return 1;
}
return Teleport(playerid, 2324.419921, -1145.568359, 1050.710083, 88.2612, 12, false);
}
What am I doing wrong?