SA-MP Forums Archive
Create3DTextLabel problem - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Create3DTextLabel problem (/showthread.php?tid=270578)



Create3DTextLabel problem - Matu- - 20.07.2011

Hey! I have a problem. If i buy a house the Create3DTextLabel don't change.
pawn Код:
new Text3D:housesale
new Text3D:houseinfo
for(new h = 0; h < sizeof(HouseInfo); h++)
    {
        if(HouseInfo[h][hOwned] == 0)
        {
            format(string4, sizeof(string4), "%s\nSale: %d Saki",HouseInfo[h][hDiscription],HouseInfo[h][hValue]);
            housesale = Create3DTextLabel(string4,0xF9A406FF,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],15,0,1);
        }
        else if(HouseInfo[h][hOwned] == 1)
        {

            format(string4, sizeof(string4), "%s\n Owner: %s",HouseInfo[h][hDiscription], HouseInfo[h][hOwner]);
            houseinfo = Create3DTextLabel(string4,0xF9A406FF,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],15,0,1);
        }
    }
I have tried Delete3DTextLabel in cmds like that /buyhouse and /sellhouse. I have got that when i use the buy cmd then the housesale do not delete and the i have two Create3DTextLabel. I somebody can me help the i will be happy. But now it is fucked up :S


Re: Create3DTextLabel problem - Matu- - 21.07.2011

Can somebody help me wiht that?


Re: Create3DTextLabel problem - Matu- - 24.07.2011

up ?


Re: Create3DTextLabel problem - iggy1 - 24.07.2011

Looks like you need to use arrays. Try this.
pawn Код:
new Text3D:housesale[sizeof(HouseInfo)];
new Text3D:houseinfo[sizeof(HouseInfo)];

for(new h = 0; h < sizeof(HouseInfo); h++)
{
    if(HouseInfo[h][hOwned] == 0)
    {
        format(string4, sizeof(string4), "%s\nSale: %d Saki",HouseInfo[h][hDiscription],HouseInfo[h][hValue]);
        housesale[h] = Create3DTextLabel(string4,0xF9A406FF,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],15,0,1);
    }
    else
    {
        format(string4, sizeof(string4), "%s\n Owner: %s",HouseInfo[h][hDiscription], HouseInfo[h][hOwner]);
        houseinfo[h] = Create3DTextLabel(string4,0xF9A406FF,HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez],15,0,1);
    }
}



Re: Create3DTextLabel problem - Matu- - 25.07.2011

It doesn't work. But thanks. It looks like the first part of Sale freeze. But why? I dont no.


Re: Create3DTextLabel problem - =WoR=Varth - 25.07.2011

https://sampwiki.blast.hk/wiki/Update3DTextLabelText