Jump to content

Cum adaug Job


Grigo

Recommended Posts

Pai una dintre variante e sa faci un dialog in care sa adaugi un checkpoint pentru fiecare job.

Edited by Transkrey

Ofer servicii de web designer/developer(contact me pentru portofoliu etc)

Metode de plata: Paysafecard,Skrill,PayPal,Bitcoin

Ofer si servicii de Penetration Testing.

Vand si VPN-uri. 5 euro pe luna

Skype: live:mrtunne.tkcode

Discord: https://mrtunne.info/discord

Link to comment
Share on other sites

Daca esti incepator si nu ai joburile in baza de date poti face asa:

 

CMD:jobs(playerid, params[])
{
  if(CP[playerid] == 0 && FindTime[playerid] == 0)
  {
       ShowPlayerDialog(playerid, DIALOG_JOBS, DIALOG_STYLE_LIST, "Server:jobs", "job1 \n job2 etc...", "Select", "Cancel");
  }
  return 1;
}

 

case DIALOG_JOBS:
        {
            if(!response)
            {
                hidePlayerDialog(playerid);
            }
            else
            {
                new Float: playerPos[3];
                GetPlayerPos(playerid, playerPos[0], playerPos[1], playerPos[2]);
                switch(listitem)
                {
                    case 0:
                    {
                        SetPlayerCheckpoint(playerid, coordonate job, 3.0);
                        playerVariables[playerid][pCheckpoint] = 1;
                        SCM(playerid, COLOR_YELLOW, "A checkpoint has been set on the job1");
                    }

 case 1:
                    {
                        SetPlayerCheckpoint(playerid, coordonate job2, 3.0);
                        playerVariables[playerid][pCheckpoint] = 1;
                        SCM(playerid, COLOR_YELLOW, "A checkpoint has been set on the job2");
                    }

             }

}

}

 

 

 

Edited by TrueCross
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.