Map icons problem..
#1

Hello i added map icons but they dont show on the map.. The code :

Код:
CreateDynamicMapIcon(1367.8254,-1279.7916,13.5469, 6, -1, -1, -1, -1, 100);//Ammunation1
    CreateDynamicMapIcon(1021.5895,-1930.3885,12.6634, 6, -1, -1, -1, -1, 100);//Ammunation2
    CreateDynamicMapIcon(1952.5363,-2041.1522,13.5469, 6, -1, -1, -1, -1, 100);//Ammunation3
    CreateDynamicMapIcon(2400.6296,-1980.5890,13.5469, 6, -1, -1, -1, -1, 100);//Ammunation4
    CreateDynamicMapIcon(823.4384,-1588.9325,13.5545, 6, -1, -1, -1, -1, 100);//Ammunation5
    CreateDynamicMapIcon(1481.0909,-1770.5958,18.7958, 52, -1, -1, -1, -1, 100);//Bank
    CreateDynamicMapIcon(2229.2771,-1721.9152,13.5674, 54, -1, -1, -1, -1, 100);//Gym
    CreateDynamicMapIcon(2491.2190,-1668.7736,13.3438, 19, -1, -1, -1, -1, 100);//Grove
    CreateDynamicMapIcon(2164.5276,-1688.0425,15.0859, 19, -1, -1, -1, -1, 100);//Ballas
    CreateDynamicMapIcon(2201.4504,-1013.2170,61.6770, 19, -1, -1, -1, -1, 100);//Vagos
    CreateDynamicMapIcon(2808.1697,2190.1521,10.8203, 19, -1, -1, -1, -1, 100);//Aztecas
    CreateDynamicMapIcon(1662.7102,-1707.0779,20.4772, 19, -1, -1, -1, -1, 100);//IMafia
    CreateDynamicMapIcon(665.9885,-1281.0648,13.4609, 19, -1, -1, -1, -1, 100);//DaNangBoys
    CreateDynamicMapIcon(299.2349,-1163.7401,80.9099, 19, -1, -1, -1, -1, 100);//Cripz
    CreateDynamicMapIcon(2039.4788,1914.0044,12.1668, 19, -1, -1, -1, -1, 100);//Triads
    CreateDynamicMapIcon(2788.3376,-1609.3351,10.9219, 19, -1, -1, -1, -1, 100);//RussianMafia
    CreateDynamicMapIcon(434.0928,-1769.7646,5.2899, 19, -1, -1, -1, -1, 100);//Rifa
    CreateDynamicMapIcon(1575.7512,-1701.5604,5.8906, 30, -1, -1, -1, -1, 100);//LSPD
    CreateDynamicMapIcon(2264.7673,2461.9910,10.8203, 30, -1, -1, -1, -1, 100);//LVPD
    CreateDynamicMapIcon(624.6029,-598.9421,16.9301, 30, -1, -1, -1, -1, 100);//RCPD
    CreateDynamicMapIcon(-1461.2150,311.0496,7.1875, 30, -1, -1, -1, -1, 100);//S.A.A.A
    CreateDynamicMapIcon(302.9539,1993.1122,17.6406, 30, -1, -1, -1, -1, 100);//SpecialForces
    CreateDynamicMapIcon(-70.0693,-1131.4658,1.6848, 46, -1, -1, -1, -1, 100);//TruckJob
    CreateDynamicMapIcon(208.3888,-173.2207,1.1782, 46, -1, -1, -1, -1, 100);//PizzaBoy
    CreateDynamicMapIcon(1792.1930,-1919.5452,13.1726, 46, -1, -1, -1, -1, 100);//TaxiJob
    CreateDynamicMapIcon(990.9885,-1301.4009,13.1079, 46, -1, -1, -1, -1, 100);//SweeperJob
    CreateDynamicMapIcon(1310.3949,-1367.8287,13.5415, 37, -1, -1, -1, -1, 100);//OfficeInformation
Reply
#2

Where did you create them?
Should be under OnGameModeInit function.
Reply
#3

Yeah they are there..
Reply
#4

That's how i'm creating dynamic mapicons.

mapicon = CreateDynamicMapIcon(x, y, z, 16, 0, -1, -1, 0, 100000.0);

Streamer_SetIntData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_STYLE, 1);
Streamer_AppendArrayData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_PLAYER_ID, playerid);
Reply
#5

What is this streamer codes? Where to add them?
Reply
#6

1. Streamer_SetIntData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_STYLE, 1);

This line makes style = 1 (global map icon, so everyone can see it)

2. Streamer_AppendArrayData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_PLAYER_ID, playerid);

And this line is for showing map icon for player, put it in onplayerspawn.

You can also remove it by - Streamer_RemoveArrayData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_PLAYER_ID, playerid);
Reply
#7

Where to add the "1."?
And what to remove i dont understand..
Reply
#8

Quote:
Originally Posted by dundolina
Посмотреть сообщение
Where to add the "1."?
And what to remove i dont understand..
I've gave you ready to launch lines, just replace your mapicons positions in my code.

Put it in OnGameModeInit, under createdynamicmapicon lines:

Код:
for(new i=1; i<28; i++)
	{
		Streamer_SetIntData(STREAMER_TYPE_MAP_ICON, i, E_STREAMER_STYLE, 1);
	}
And in OnPlayerSpawn make mapicon visible for player:

Streamer_AppendArrayData(STREAMER_TYPE_MAP_ICON, mapicon, E_STREAMER_PLAYER_ID, playerid);
Reply
#9

Again no one map icon shows on the map..
Reply
#10

Please help..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)