#1

How to fix that ?

Код:
undefined symbol "MInfo"
Код:
new MapIcons[][MInfo] = //WARNING HERE 'MInfo'
{
    	{1, -314.8433,1773.9176,43.6406, 16, 2},
	{2, -311.0136,1542.9733,75.5625, 16, 2}
};
Код:
for(new i = 0;i <sizeof(MapIcons);i++) SetPlayerMapIcon(playerid, MapIcons[i][0], MapIcons[i][1], MapIcons[i][2], MapIcons[i][3], MapIcons[i][4], MapIcons[i][5], MAPICON_LOCAL);
Reply
#2

im still a smartass though.
Reply
#3

Quote:
Originally Posted by Meller
Посмотреть сообщение
im still a smartass though.
You are..

Can you now help me to fix this problem ?
Reply
#4

you don't have an enum named MInfo
Reply
#5

Care to explain what to do in enum ?
Reply
#6

MapIcons[MAX_PLAYERS][MInfo]
This would work fine
Reply
#7

It doesen't. After that compiler stop to work.
Reply
#8

https://sampforum.blast.hk/showthread.php?tid=318307
Reply
#9

Just kill me, I have no idea how to work with that lol.
Reply
#10

Quote:
Originally Posted by Hunud
Посмотреть сообщение
Care to explain what to do in enum ?
Enumerators shortly are called enums

you can store any type of variable strings inegers also float's

example you have en enum called

Код:
enum MapIcons
{ // from the function SetPlayerMapIcon these are the parameters stored in enumerator
       Icon_id,  
       Float: fX,
       Float: fY,
       Float: fZ,
       Type,
       Style
}
new BlimpIcons[100][MapIcons] = {    // this is an array that will hold variables internaly, you store them manualy in your script
      {1, 20.2, 47.35, 12.66, 46, 0},
      {.....},
      {.....},
};

public OnPlayerConnect(playerid)
{
       // you set player mapicons  later you destroy them when player disconnects
       for(new i=0; i < sizeof(BlimpIcons); i++) SetPlayerMapIcon(.......); // this loop will Retrieve the data from the array you just added
       return 1;
}
Код:
SetPlayerMapIcon(playerid, iconid, Float:x, Float:y, Float:z, markertype, color, style = MAPICON_LOCAL);
edited so you clearly understand how they work
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)