Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2015-01-18, 18:21


Shogo12345

LuA






Wiek: 32
Na forum: 4322 dni
Posty: 48
Nick w MP: Artux

Piwa: 505

Respekt: 70

Ostrzeżeń: 100%
Witam mam problem z Skryptem bo jak odpalam skrypt wchodze w Marker odpalam Prace i nie ma punkt?w gdzie mam Je?dzi? A ja napisalem aby te punkty na drodze sie pojawia?y.

Za Pomoc Daje Piwko Zimne!!!

Kod:

--[[ Prawa autorskie nadane przez Milo i xDanioPLx ]]--
--[[ Zakaz usuwania Autora ]]--
--[[ Chcesz by?‡ autorem tego dodaj si?™,ale nie usuwaj mnie! ]]--



local blip = createBlip ( -2276, 212, 35.1640625, 56 ) -- miejsce pracy dorywczej "smieciarki"

local marker_zacznijprace = createMarker ( -2276, 212, 35.1640625, "cylinder", 3, 255, 0, 0, 85 ) -- marker w kt??rym zaczyna si?™ prace

local cele = -- cele Smieciarki
{
    { -2267.0231933594, 167.6136932373, 35.1640625};
    { -2255.1479492188, 121.88951873779, 35.171875};
    { -2270.0515136719, 52.963054656982, 35.1640625};
    { -2369.0495605469, 38.616809844971, 35.1640625};
    { -2374.0041503906, -63.33224105835, 35.235378265381};
    { -2421.3684082031, -81.510925292969, 35.171875};
    { -2433.201171875, -205.91644287109, 35.171875};   
    { -2498.4323730469, -199.83741760254, 25.46875}; 
    { -2501.0700683594, -131.45915222168, 25.46875};
    { -2498.7836914063, -72.772506713867, 25.5859375};
    { -2424.6474609375, -72.505531311035, 35.28125};
    { -2374.9873046875, -77.440299987793, 35.230819702148}; 
    { -2368.6740722656, -179.50451660156, 35.171875};
    { -2313.9113769531, -190.70227050781, 35.171875};
    { -2255.82421875, -185.68449401855, 35.171875};
    { -2250.3234863281, -72.290222167969, 35.171875};
    { -2249.0180664063, 47.747428894043, 35.179672241211}; 
    { -2258.3930664063, 166.20565795898, 35.171875}; 
    { -2266.7568359375, 188.54379272461, 35.1640625};
}

 
addEventHandler("onResourceStart",marker_zacznijprace,
function(panel) 
    if panel == gracz and not isPedInVehicle(gracz) then 
        guiSetVisible(marker_zacznijprace,true) 
        showCursor(true) 
    end 
end)



function marker_cel ()
    return unpack ( cele [ math.random ( #cele ) ] )
end



                                                                           -- [[ Panel Pracy Dorywczej ]] --
                                                                           
----------------------------------------------------------------------------------------------------------------------------------------------------                                                                           
sx,sy = guiGetScreenSize()
gracz = getLocalPlayer()
pieniadze = math.random(1,2)
----------------------------------------------------------------------------------------------------------------------------------------------------
praca_panel = guiCreateWindow(541/1366*sx, 112/768*sy, 363/1366*sx, 416/768*sy,"Praca Smieciarki", false)
guiWindowSetSizable(praca_panel, false)
guiSetAlpha(praca_panel, 0.70)
----------------------------------------------------------------------------------------------------------------------------------------------------
tekst = guiCreateMemo(25/1366*sx, 115/768*sy, 314/1366*sx, 123/768*sy, "     Praca Smieciarki     Zarobki: 185$", false, praca_panel)
----------------------------------------------------------------------------------------------------------------------------------------------------

label = guiCreateLabel(15/1366*sx, 19/768*sy, 334/1366*sx, 46/768*sy, "       Praca Dorywcza by xDanioPLx. ", false, praca_panel)
guiSetFont(label, "default-bold-small")
----------------------------------------------------------------------------------------------------------------------------------------------------
zaczyna_prace = guiCreateButton(52/1366*sx, 264/768*sy, 260/1366*sx, 57/768*sy, "Zacznij Prac?™", false, praca_panel)
guiSetProperty(zaczyna_prace, "NormalTextColour", "FFAAAAAA")
----------------------------------------------------------------------------------------------------------------------------------------------------
skoncz_prace = guiCreateButton(52/1366*sx, 337/768*sy, 260/1366*sx, 57/768*sy, "Wy?‚?…cz Panel", false, praca_panel)
guiSetProperty(skoncz_prace, "NormalTextColour", "FFAAAAAA")  
guiSetVisible (praca_panel,false)
guiMemoSetReadOnly(tekst,true)
guiWindowSetMovable (praca_panel,true )
guiWindowSetSizable (praca_panel,false )
----------------------------------------------------------------------------------------------------------------------------------------------------
addEventHandler("onClientGUIClick",praca_panel,
function(liczba,thePlayer)
    if liczba == "left" then
        if source == zaczyna_prace then
            outputChatBox ("((Teraz wejdz ponownie w marker aby wzi?…?›?‡ pojazd!))",225,225,225, true)
            guiSetVisible(praca_panel,false)
            guiSetVisible(zaczyna_prace,false)
            showCursor(false)
            --
            wez_pojazd = guiCreateButton(52/1366*sx, 264/768*sy, 260/1366*sx, 57/768*sy, "We?? Pojazd", false, praca_panel)
            koncz = guiCreateButton(52/1366*sx, 337/768*sy, 260/1366*sx, 57/768*sy, "Wy?‚?…cz Panel", false, praca_panel)
            guiSetAlpha(koncz, 0.0)
            --
            end
        end
    end
)

addEventHandler("onClientGUIClick",praca_panel,
function(liczba,thePlayer)
    if liczba == "left" then
        if source == skoncz_prace then
        guiSetVisible(praca_panel,false)
        showCursor(false)
    end
  end
end)

addEventHandler("onClientGUIClick",praca_panel,
function(liczba,thePlayer)
    if liczba == "left" then
        if source == koncz then
        guiSetVisible(praca_panel,false)
        guiSetVisible(koncz,false)
        guiSetVisible(wez_pojazd,false)
        guiSetVisible(offduty,false)
        guiSetVisible(skoncz_prace,true)
        guiSetVisible(zaczyna_prace,true)
        showCursor(false)
        destroyElement ( pojazdmarker )
        destroyElement ( blipcelu )
    end
  end
end)
    
addEventHandler("onClientGUIClick",praca_panel,
function(liczba,thePlayer)
    if liczba == "left" then
        if source == wez_pojazd then
        outputChatBox ("((Jeste?› ju?? w poje??dzie jed?? do wyznaczonego celu))",thePlayer,225,225,225, true)
        triggerServerEvent ( "praca_dorywcza", gracz)
        triggerServerEvent ( "dajepojazd", gracz)
        guiSetVisible(praca_panel,false)
        guiSetVisible(koncz,true)
        guiSetVisible(zaczyna_prace,false)
        guiSetVisible(wez_pojazd,false)
        guiSetVisible(skoncz_prace,true)
        showCursor(false)
        end
    end
end)


        
addEventHandler("onClientMarkerHit",marker_zacznijprace,
    function(panel)
        if panel == gracz and not isPedInVehicle(gracz) then
            guiSetVisible(praca_panel,true)
            showCursor(true)
        end
    end
)


addEventHandler ( "onClientMarkerHit", root,
    function ( hitElement )
        if source == pojazdmarker and localPlayer == hitElement  then
        local pojazd = getPedOccupiedVehicle ( localPlayer )
        if pojazd and getElementModel(pojazd) == 574 then -- pojazd 
            triggerServerEvent ( "dostaje_pieniadze", localPlayer )
            destroyElement ( pojazdmarker )
 
            if isElement(blipcelu) then 
            destroyElement ( blipcelu ) -- usuwa blip celu 
end
 
            guiSetVisible(dalsza_praca,true)
            showCursor(true)
        end
    end
end)




addEventHandler("onClientGUIClick",dalsza_praca,
function(liczba,thePlayer)
    if liczba == "left" then
        if source == dalej then
            x, y, z = marker_cel ()
            pojazdmarker = createMarker ( x, y, z, "checkpoint", 5, 255, 51, 102, 85, localPlayer )
            blipcelu = createBlipAttachedTo ( pojazdmarker, 41, localPlayer )
            guiSetVisible(dalsza_praca,false)
            showCursor(false)
            elseif source == koniec then
            guiSetVisible(dalsza_praca,false)
            showCursor(false)
        end
    end
end)


addEvent("praca_dorywcza", true)
function createDestinations ()
    x, y, z = marker_cel ()
    pojazdmarker = createMarker ( x, y, z, "checkpoint", 5, 255, 51, 102, 85, localPlayer )
    blipcelu = createBlipAttachedTo ( pojazdmarker, 41, localPlayer )
end
addEventHandler ( "praca_dorywcza", root, createDestinations )


Ostatnio zmieniony przez MeeShuffle 2015-01-18, 18:35, w całości zmieniany 1 raz  
Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-01-18, 20:16


Loop

Inspektor






Wiek: 28
Na forum: 4430 dni
Posty: 311
Nick w MP: Inspektor

Piwa: 201

Respekt: 130
Respekt: 130

Te ; zamien na ͵

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-02-21, 19:47


OskarYT

Mapper MTA






Wiek: 26
Na forum: 4386 dni
Posty: 267
Nick w MP: Kaczorek2306

Piwa: 1230

Respekt: 85,3

Jakie ; na . ?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-02-21, 20:28


PanPrezes







Wiek: 32
Na forum: 4696 dni
Posty: 63
Nick w MP: PanPrezes

Piwa: 980

Respekt: 111,2
Respekt: 111,2

mniej wi?cej tak
    { -2267.0231933594, 167.6136932373, 35.1640625},
    { -2255.1479492188, 121.88951873779, 35.171875},
    { -2270.0515136719, 52.963054656982, 35.1640625},
    { -2369.0495605469, 38.616809844971, 35.1640625},
    { -2374.0041503906, -63.33224105835, 35.235378265381},
    { -2421.3684082031, -81.510925292969, 35.171875},
    { -2433.201171875, -205.91644287109, 35.171875}, 
    { -2498.4323730469, -199.83741760254, 25.46875},
    { -2501.0700683594, -131.45915222168, 25.46875},
    { -2498.7836914063, -72.772506713867, 25.5859375},
    { -2424.6474609375, -72.505531311035, 35.28125},
    { -2374.9873046875, -77.440299987793, 35.230819702148},
    { -2368.6740722656, -179.50451660156, 35.171875},
    { -2313.9113769531, -190.70227050781, 35.171875},
    { -2255.82421875, -185.68449401855, 35.171875},
    { -2250.3234863281, -72.290222167969, 35.171875},
    { -2249.0180664063, 47.747428894043, 35.179672241211},
    { -2258.3930664063, 166.20565795898, 35.171875},
    { -2266.7568359375, 188.54379272461, 35.1640625}, 
pomog?em?

Podpis
Reaktywacja zapomnianego serwera YL-Games!


Prace nad serwerem 54/100%

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-02-21, 22:15


Artysta

Lua, Lua, Czekolada






Wiek: 28
Na forum: 4607 dni
Posty: 240
Nick w MP: Artysta/Koojot

Piwa: 1427

Respekt: 205,8
Respekt: 205,8Respekt: 205,8

Wydaje mi si?, ?e tak.


   { -2267.0231933594, 167.6136932373, 35.1640625},
    { -2255.1479492188, 121.88951873779, 35.171875},
    { -2270.0515136719, 52.963054656982, 35.1640625},
    { -2369.0495605469, 38.616809844971, 35.1640625},
    { -2374.0041503906, -63.33224105835, 35.235378265381},
    { -2421.3684082031, -81.510925292969, 35.171875},
    { -2433.201171875, -205.91644287109, 35.171875}, 
    { -2498.4323730469, -199.83741760254, 25.46875},
    { -2501.0700683594, -131.45915222168, 25.46875},
    { -2498.7836914063, -72.772506713867, 25.5859375},
    { -2424.6474609375, -72.505531311035, 35.28125},
    { -2374.9873046875, -77.440299987793, 35.230819702148},
    { -2368.6740722656, -179.50451660156, 35.171875},
    { -2313.9113769531, -190.70227050781, 35.171875},
    { -2255.82421875, -185.68449401855, 35.171875},
    { -2250.3234863281, -72.290222167969, 35.171875},
    { -2249.0180664063, 47.747428894043, 35.179672241211},
    { -2258.3930664063, 166.20565795898, 35.171875},
    { -2266.7568359375, 188.54379272461, 35.1640625}
}


Podpis
Something is coming..
Postaw piwo autorowi tego posta
 

 
Tagi: skrypt :: smieciarke
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA Ten temat jest zablokowany bez możliwości zmiany postów lub pisania odpowiedzi

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku