nah, it wont create dozens of icons due to spawning again and again. the icons are numbered, so setting one up again will simply replace the (if) already exsisting icon.
https://sampwiki.blast.hk/wiki/SetPlayerMapIcon
^pay attention to the iconid...
the reason why its not working on OnPlayerConnect(), is simple: theres no interior, nor a virtual world set up for the player, so:
give hiddos' advice a try: place it in the OnPlayerSpawn() callback. this will make the icon permanent.
edit: your line is slightly messed up:
Код:
SetPlayerMapIcon(playerid,12,1984.318725,2059.8835 44,10,55,0);
,playerid == ok i think
![Smiley](images/smilies/smile.png)
,12 == iconid 12? do you already got 12 other icons from 0-11? i assume not, then you should start numbering @ 0.
,1984.318725 == east of the map
,2059.8835 == north
44,10 == ?
,55 == ok your x-y coordinates are at the autobahn shop in lv. then its obvious that you want the car icon.
,0 == color. we dont care here.
after replacing your " 44,10" by ",10.8200" it should look like:
Код:
SetPlayerMapIcon(playerid,12,1984.0000,2059.0000,10.8200,55,0);
conclusion: one space " " can mess up a whole thing hehe i hope this works now.
ah also try that one, starting with the first icon (id 0):
Код:
SetPlayerMapIcon(playerid,0,1984.0000,2059.0000,10.8200,55,0);