SA-MP Forums Archive
A little 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)
+--- Thread: A little problem (/showthread.php?tid=280725)



A little problem - Gomma - 02.09.2011

Hi,
I got a little issue with using Incongito's Streamer.

The problem is:

I want to display a Map Icon for every business that is loaded by my script. The code which handles this looks like this:

pawn Код:
for(new idx = 0; idx < sizeof(BizzInfo) ; idx++)
    {
        new bicon;
        switch(BizzInfo[idx][Type])
        {
            case 0: //Tankstelle
            {
                bicon = 56;
            }
            case 1: //Essensbizz
            {
                bicon = 50;
            }
            case 2: //Ammu Nation
            {
                bicon = 18;
            }
            default:
            {
                bicon = 1;
            }
        }
       
        BizzInfo[idx][BIcon] = CreateDynamicMapIcon(BizzInfo[idx][EnterX],BizzInfo[idx][EnterY],BizzInfo[idx][EnterZ],bicon,0);
    }
It is located at OnGameModeInit .


The Issue is: It does display the Icon, but it always displays 2 at one time, that means one overlays the other one and that looks really bad.


Re: A little problem - FireCat - 02.09.2011

pawn Код:
for(new idx = 0; idx < sizeof(BizzInfo) ; idx++)
    {
        new bicon[sizeof(BizzInfo)];
        switch(BizzInfo[idx][Type])
        {
            case 0: //Tankstelle
            {
                bicon[idx] = 56;
            }
            case 1: //Essensbizz
            {
                bicon[idx] = 50;
            }
            case 2: //Ammu Nation
            {
                bicon[idx] = 18;
            }
            default:
            {
                bicon[idx] = 1;
            }
        }
       
        BizzInfo[idx][BIcon] = CreateDynamicMapIcon(BizzInfo[idx][EnterX],BizzInfo[idx][EnterY],BizzInfo[idx][EnterZ],bicon[idx],0);
    }