SA-MP Forums Archive
How do I make this update? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: How do I make this update? (/showthread.php?tid=300786)



How do I make this update? - Dokins - 01.12.2011

As in, Make the house owner update, because it doesnt update if I /buyhouse then go back onto the pickup.

pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
    new string[256];

    for(new x = 0; x < MAX_HOUSES; x++)
    {
        if(IsPlayerInRangeOfPoint(playerid, 5.0, HouseEntX[x], HouseEntY[x], HouseEntZ[x]))
        {
            if(pickupid == HousePickup[x])
            {
                if(!(strcmp(HouseOwner[x], "nobody", true)))
                {
                    format(string, sizeof(string), "~r~For Sale : %s~n~~w~Price: $%d~n~~b~Type '/buyhouse' to purchase.", HouseName[x], HousePrice[x]);
                }
                else
                {
                    format(string, sizeof(string), "~g~Address:~w~ %s ~n~ ~g~Owner:~w~ %s", HouseName[x], HouseOwner[x]);
                }

                GameTextForPlayer(playerid, string, 3000, 5);
                break;
            }
        }



Re: How do I make this update? - Dokins - 03.12.2011

Bump