Here is the snippet you need I think.
pawn Код:
for(new h = 0; h < sizeof(HouseInfo); h++)
{
//new string[128];
if(IsPlayerInRangeOfPoint(i,25.0,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez]))
{
if(HouseInfo[h][hOwned] == 1)
{
if(HouseInfo[h][hRentabil] == 0)
{
//SetPlayerCheckpoint(i,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],2.2);
Delete3DTextLabel(Text5);
Delete3DTextLabel(Text);
//format(dialogs , sizeof(dialogs),"This House is owned by %s.",HouseInfo[h][hOwner]);
//ShowPlayerDialog(i ,HOUSE1,DIALOG_STYLE_MSGBOX ,"House1:",dialogs,"Enter" ,"Cancel" );
}
else
{
//format(dialogs , sizeof(dialogs), "This House is owned by %s ",HouseInfo[h][hOwner]);
//ShowPlayerDialog(i ,HOUSE1,DIALOG_STYLE_MSGBOX ,"House1:",dialogs,"Enter" ,"Cancel" );
//SetPlayerCheckpoint(i,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],2.2);
Delete3DTextLabel(Text4);
Delete3DTextLabel(Text);
}
return 1;
}
else
{
//ShowPlayerDialog(i ,YES,DIALOG_STYLE_MSGBOX ,"House1","House is for sale","Buy" ,"Cancel" );
//SetPlayerCheckpoint(i,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],2.2);
Delete3DTextLabel(Text4);
new location[MAX_ZONE_NAME];
Get2DZone(location, MAX_ZONE_NAME, HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez]);
format(text_info,256,"House[%d]\nStreet:%s\nPrice:$%d\nLevel:%d\nLock Level:%d\nAlarm Level:%d",h,location,HouseInfo[h][hValue],HouseInfo[h][hLevel],HouseInfo[h][hLock],HouseInfo[h][hLock]);
Text = Create3DTextLabel(text_info,COLOR_YELLOW4,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],8.5,0, 1);
//AddStaticPickup(1273, 2,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez]);
return 1;
}
}
}