Jump to content
  • 0

Problema Job


KeinN

Question

Salut, 

Incerc sa bag un job (Street Sweeper) de pe gamemode-ul Thug 2.0 pe gamemode-ul GTA-SAMP. 

Pana acum in gamemode-ul GTA-SAMP am pus asta: 

cmd:work(playerid, params []) {
	if(pInfo[playerid][pJob] == 0) return SCM(playerid, COLOR_DARKGRAY, "Ai nevoie de un job pentru a putea folosi aceasta comanda.");
    if(pInfo[playerid][aVar][72] != -1) return SendClientMessage(playerid, COLOR_DARKGRAY, "You already created a vehicle.");
    switch(pInfo[playerid][pJob])
    {
        case 2:
        {
            KillTimer(pInfo[playerid][aVar][25]), pInfo[playerid][aVar][25] = -1, pInfo[playerid][aVar][25] = SetTimerEx("GeneralTimer", 980, true, "ii", playerid, 49);
            if(!IsPlayerInRangeOfPoint(playerid, 21.0, 2821.7419,950.2172,10.7500)) return SendClientMessage(playerid, COLOR_DARKGRAY, "You are not at the job point, use /jobpoint.");
            GetPlayerPos(playerid, POSS[0], POSS[1], POSS[2]), DisableRemoteVehicleCollisions(playerid, 1), pInfo[playerid][aVar][115] = 0;
            if(pInfo[playerid][pSweepSkill] < 210 ? (SendClientMessage(playerid, COLOR_YELLOW, "* Mergi cu vehiculul 3 KM pentru a fi platit."))
                : (SendClientMessage(playerid, COLOR_YELLOW, "* Mergi cu vehiculul 6 KM pentru a fi platit.")))
            pInfo[playerid][aVar][72] = CreateVehicle(pInfo[playerid][pSweepSkill] < 210 ? (574) : (552), POSS[0], POSS[1], POSS[2],180.1296,RandomEx(128, 254),RandomEx(128, 254),-1);
            KMVeh[pInfo[playerid][aVar][72]] = 0, pInfo[playerid][aVar][21] = pInfo[playerid][pSweepSkill] < 210 ? (3) : (6);
            if(pInfo[playerid][pVIP] == 1) AddVehicleComponent(pInfo[playerid][aVar][72], 1080);
        }

Tin sa mentionez ca jobul Street Sweeper era deja facut, textdraw-urile sunt facute, skillul e facut insa la cmd:work era doar un text "Acest job va suferii modificari de script".

Pana acum am adaugat doar ce sa faci la /work dar nu gasesc linia responsabila pentru a platii jucatorul. 
Stie cineva cum o pot gasii?

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

Tin sa mentionez ca linia originala din gamemode-ul Thug este asta: 
 

case 2:
        {
            KillTimer(pInfo[playerid][aVar][25]), pInfo[playerid][aVar][25] = -1, pInfo[playerid][aVar][25] = SetTimerEx("GeneralTimer", 980, true, "ii", playerid, 49);
            if(!IsPlayerInRangeOfPoint(playerid, 21.0, 2821.7419,950.2172,10.7500)) return SendClientMessage(playerid, COLOR_DARKGRAY, "You are not at the job point, use /jobpoint.");
            GetPlayerPos(playerid, POSS[0], POSS[1], POSS[2]), DisableRemoteVehicleCollisions(playerid, 1), pInfo[playerid][aVar][115] = 0;
            if(pInfo[playerid][pSweepSkill] < 210 ? (SendClientMessage(playerid, COLOR_YELLOW, "* Mergi cu vehiculul 3 KM pentru a fi platit."))
                : (SendClientMessage(playerid, COLOR_YELLOW, "* Mergi cu vehiculul 6 KM pentru a fi platit.")))
            pInfo[playerid][aVar][72] = CreateVehicle(pInfo[playerid][pSweepSkill] < 210 ? (574) : (552), POSS[0], POSS[1], POSS[2],180.1296,RandomEx(128, 254),RandomEx(128, 254),-1);
            KMVeh[pInfo[playerid][aVar][72]] = 0, pInfo[playerid][aVar][21] = pInfo[playerid][pSweepSkill] < 210 ? (3) : (6);
            TSpeedometer[playerid][3] = CreatePlayerTextDraw(playerid,506.000000, 398.000000, "Loading...");
            PlayerTextDrawBackgroundColor(playerid,TSpeedometer[playerid][3], 250),
            PlayerTextDrawFont(playerid,TSpeedometer[playerid][3], 1),
            PlayerTextDrawLetterSize(playerid,TSpeedometer[playerid][3], 0.289999, 1.399999),
            PlayerTextDrawColor(playerid,TSpeedometer[playerid][3], -1),
            PlayerTextDrawSetOutline(playerid,TSpeedometer[playerid][3], 0),
            PlayerTextDrawSetProportional(playerid,TSpeedometer[playerid][3], 1),
            PlayerTextDrawSetSelectable(playerid,TSpeedometer[playerid][3], 0), PlayerTextDrawSetShadow(playerid,TSpeedometer[playerid][3], 1),
            PlayerTextDrawShow(playerid, TSpeedometer[playerid][3]), PlayerTextDrawSetString(playerid, TSpeedometer[playerid][3], "Kilometers: ~y~0");
            if(pInfo[playerid][pVIP] == 1) AddVehicleComponent(pInfo[playerid][aVar][72], 1080);
        }

 

Dar a trebuit sa sterg cate ceva deoarece imi tot dadea eroare.

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
Answer this question...

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