Jump to content
  • 0

checkpoint


InceMan

Question

Salut, am o problema  daca sunt 10 playeri on le da checkpoint diferite si imi apare mesajul asta de 10 ori in chat

SendClientMessageToAll(-1, "A new stunting event has just started. It  has been marked on your Map with a Black&White Race Flag Get there first and you'II win.");

 

for(new i = 0; i<MAX_PLAYERS; i++)
    {
	    if(IsPlayerConnected(i))
	    {
	        new randoms = random(sizeof(stuntnrg));
	        {
	            SetPlayerCheckpoint(i, stuntnrg[randoms][0],stuntnrg[randoms][1], stuntnrg[randoms][2], 1.0);//
	            ///SetPlayerMapIcon
				SetPlayerMapIcon(playerid, 53, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2],53, MAPICON_GLOBAL_CHECKPOINT);//CreateDynamicMapIcon
	            pickup_event = CreatePickup(1274, 2, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2], GetPlayerVirtualWorld(playerid));//
                SendClientMessageToAll(-1, "A new stunting event has just started. It  has been marked on your Map with a Black&White Race Flag Get there first and you'II win.");
	            stunton[playerid] = 1;
		    }
	    }
	}

 

Edited by Geani
@Wopss

FiveGame  Lands

Pawno Developer, Mapping , Scripter

Since 2016

Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0
forward SetRaceCheckpointAll();
public SetRaceCheckpointAll() {
    for (new i = 0, j = GetPlayerPoolSize(); i <= j; i++) {
      	if(stunton[i] == 1) { // Cei care sunt la event vor primi toti acelasi CP.
          	new randoms = random(sizeof(stuntnrg));
        	SetPlayerCheckpoint(i, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2], 1.0);
          	SetPlayerMapIcon(i, 53, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2], 53, MAPICON_GLOBAL_CHECKPOINT);
          	pickup_event = CreatePickup(1274, 2, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2], GetPlayerVirtualWorld(i));
        }
    }
    // Asta anunta tot serverul acel mesaj
  	SendClientMessageToAll(-1, "A new stunting event has just started. It  has been marked on your Map with a Black&White Race Flag Get there first and you'II win.");
    return 1;
}

Un mic exemplu

Edited by BuNiCu-RP
Link to comment
Share on other sites

  • 0
Acum 46 minute, Geani a spus:

Salut, am o problema  daca sunt 10 playeri on le da checkpoint diferite si imi apare mesajul asta de 10 ori in chat


SendClientMessageToAll(-1, "A new stunting event has just started. It  has been marked on your Map with a Black&White Race Flag Get there first and you'II win.");

 


for(new i = 0; i<MAX_PLAYERS; i++)
    {
	    if(IsPlayerConnected(i))
	    {
	        new randoms = random(sizeof(stuntnrg));
	        {
	            SetPlayerCheckpoint(i, stuntnrg[randoms][0],stuntnrg[randoms][1], stuntnrg[randoms][2], 1.0);//
	            ///SetPlayerMapIcon
				SetPlayerMapIcon(playerid, 53, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2],53, MAPICON_GLOBAL_CHECKPOINT);//CreateDynamicMapIcon
	            pickup_event = CreatePickup(1274, 2, stuntnrg[randoms][0], stuntnrg[randoms][1], stuntnrg[randoms][2], GetPlayerVirtualWorld(playerid));//
                SendClientMessageToAll(-1, "A new stunting event has just started. It  has been marked on your Map with a Black&White Race Flag Get there first and you'II win.");
	            stunton[playerid] = 1;
		    }
	    }
	}

 

 

Edited by Geani

FiveGame  Lands

Pawno Developer, Mapping , Scripter

Since 2016

Link to comment
Share on other sites

  • 0
Acum 10 ore, SoloREGELE a spus:

Care e problema?

 

Acum 9 ore, Alex03R a spus:

Care e problema ?

voi 2 aveti acelasi cont ?

FiveGame  Lands

Pawno Developer, Mapping , Scripter

Since 2016

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.