07.11.2009, 00:40
Okay, my first problem is solved...
now i have another problem...
i have this:
and this
Problem: Sometimes i get teleported, sometimes not :P
now i have another problem...
i have this:
pawn Код:
new Float:Pickups[][PickInfo] = {
{1,1726.9751,-1636.3334,20.2171,0,1726.9526,-1638.7334,20.2234,18},
{2,2351.9111,-1168.9744,27.9920,0,2350.7036,-1181.1886,1027.9766,5},
{3,1553.6572,-1675.6367,16.1953,0,288.745971,169.350997,1007.171875,3},
{4,1258.3425,-785.4657,92.0302,0,1262.1348,-785.3854,1091.9063,5},
{5,1298.6053,-798.9628,84.1406,0,1299.1544,-795.9728,1084.0078,5},
{6,1929.5431,-1776.2677,13.5469,0,-27.3968,-30.2565,1003.5573,},
{7,1832.5872,-1842.0410,13.5781,0,-31.0414,-90.7142,1003.5469,180},
{8,1835.8566,-1681.8176,13.3723,0,493.6534,-23.5046,1000.6797,17},
{9,1739.3409,-1582.5289,14.1552,0,384.808624,173.804992,1008.382812,3},
{10,1572.2260,-1334.8035,16.4844,0,1548.6030,-1365.5646,326.2109,0},
{11,1698.5256,-1667.8107,20.1945,0,1701.5145,-1667.8511,20.2188,18}
};
pawn Код:
for(new i=0; i<PLAYERS; i++)
{
for(new buildingid = 0; buildingid<MAX_BUILD_PICKUPS;buildingid++)
{
if(PickupsActive[i] == 1)
{
if(PlayerToPoint(2, i, Pickups[buildingid][EnterX], Pickups[buildingid][EnterY], Pickups[buildingid][EnterZ]))
{
SetPlayerPos(i, Pickups[buildingid][ExitX], Pickups[buildingid][ExitY], Pickups[buildingid][ExitZ]);
SetPlayerInterior(i, Pickups[buildingid][ExitInt]);
PickupsActive[i] = 0;
SetTimerEx("EnablePickupsAgain",5000,0,"i",i);
}
else if(PlayerToPoint(2, i, Pickups[buildingid][ExitX], Pickups[buildingid][ExitY], Pickups[buildingid][ExitZ]))
{
SetPlayerPos(i, Pickups[buildingid][EnterX], Pickups[buildingid][EnterY], Pickups[buildingid][EnterZ]);
SetPlayerInterior(i, Pickups[buildingid][EnterInt]);
PickupsActive[i] = 0;
SetTimerEx("EnablePickupsAgain",5000,0,"i",i);
}
}
}
}