22.08.2010, 18:13
Ok i change the system to work with OnPlayerEnterCheckpoint.
so its look like this:
still didnt work. i mean, when i come near the house the checkpoint is not apear.
so i think the problem in the housetimer2 timer.
but i couldnt find what the problem...
so its look like this:
pawn Код:
public housetimer2()
{
for(new i=0;i<MAX_PLAYERS;i++)
{
for(new m=0;m<MAX_HOUSES;m++)
{
if(PlayerToPoint(4, i, h2Info[m][iconx], h2Info[m][icony], h2Info[m][iconz]))
{
CP[i] = 69;
SetPlayerCheckpoint(i, h2Info[m][iconx], h2Info[m][icony], h2Info[m][iconz], 2);
}
else
{
if(backupst[i] == 0)
{
CP[i] = 0;
DisablePlayerCheckpoint(i);
}
}
}
}
}
public OnPlayerEnterCheckPoint
{
if (CP[playerid]==69)
{
GetHouseStats(playerid, GetHouseID(playerid));
}
}
so i think the problem in the housetimer2 timer.
but i couldnt find what the problem...