Problem in Getting Zone Names
#2

pawn Код:
stock GetPlayer2DZone(playerid, &zone[])//the & symbol in this line as the value is passed by reference
{
    new Float:X, Float:Y, Float:Z;
    GetPlayerPos(playerid, X, Y, Z);
    if(pInfo[playerid][InTheHouse])
    {
        format(zone,MAX_ZONE_NAME,"%s", HouseInfo[Hin[playerid]][HouseName]);
        return 1;
    }
    for(new a = 0; a < sizeof(zones); a++)
    {
        if(X > zones[a][zone_minx] && X < zones[a][zone_maxx] && Y > zones[a][zone_miny] && Y < zones[a][zone_maxy] && Z > zones[a][zone_minz] && Z < zones[a][zone_maxz])
        {
            format(zone, MAX_ZONE_NAME, "%s",zones[a][zone_name]);
            return 1;
        }
    }
    return 1;
}
Reply


Messages In This Thread
Problem in Getting Zone Names - by AroseKhanNiazi - 18.07.2014, 11:12
Re: Problem in Getting Zone Names - by BroZeus - 18.07.2014, 11:18
Re: Problem in Getting Zone Names - by AroseKhanNiazi - 18.07.2014, 11:28
Re: Problem in Getting Zone Names - by BroZeus - 18.07.2014, 11:30
Re: Problem in Getting Zone Names - by AroseKhanNiazi - 18.07.2014, 11:34
Re: Problem in Getting Zone Names - by Konstantinos - 18.07.2014, 11:39
Re: Problem in Getting Zone Names - by BroZeus - 18.07.2014, 11:42
Re: Problem in Getting Zone Names - by AroseKhanNiazi - 18.07.2014, 11:47
Re: Problem in Getting Zone Names - by Konstantinos - 18.07.2014, 12:01
Re: Problem in Getting Zone Names - by AroseKhanNiazi - 18.07.2014, 12:13

Forum Jump:


Users browsing this thread: 1 Guest(s)