The quest problem
#1

When I command /startquest, I do not put my checkpoints on the mini-map, it's only the first one, I want it all.
https://pastebin.com/UbCpEeuP
Reply
#2

bump
Reply
#3

The way you are using SetPlayerMapIcon is invalid, because you would set all map icon in each iteration.

First solution:
- You can put all X, Y and Z data in one multidimensional array and use it in only one line of for loop. For example:

PHP код:
//Declaring the array
new Float:Coords[5][3] = {
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0}
};
//Iteration
for(new 05i++)
    
quest_MapIcon[playerid][i] = SetPlayerMapIcon(playeridiCoords[i][0], Coords[i][1], Coords[i][2], 56, -1MAPICON_GLOBAL); 
Second solution:
- Forget the loop and create all lines with SetPlayerMapIcon and without i variable
Reply
#4

Quote:
Originally Posted by iHollyZinhO
Посмотреть сообщение
The way you are using SetPlayerMapIcon is invalid, because you would set all map icon in each iteration.

First solution:
- You can put all X, Y and Z data in one multidimensional array and use it in only one line of for loop. For example:

PHP код:
//Declaring the array
new Float:Coords[5][3] = {
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0},
{
1.02.03.0}
};
//Iteration
for(new 05i++)
    
quest_MapIcon[playerid][i] = SetPlayerMapIcon(playeridiCoords[i][0], Coords[i][1], Coords[i][2], 56, -1MAPICON_GLOBAL); 
Second solution:
- Forget the loop and create all lines with SetPlayerMapIcon and without i variable
I do not understand how to put: quest_MapIcon [playerid] [i] = SetPlayerMapIcon (playerid, i, Coords [i] [0], Coords [i] [1], Coords [i] [2], 56 1, MAPICON_GLOBAL);
Should I put it only once? or How many times? Can not you make an example of the code I gave you?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)