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

Wysłany: 2020-05-19, 17:26


killercycDDS

Migacz






Wiek: 25
Na forum: 4512 dni
Posty: 629
Nick w MP: killer_cyc[DDS]

Piwa: 1659

Respekt: 22

Witam bawi? si? w przerobienie jednego skryptu i chc? zrobi? ?e gdy dana typ towaru ma jak?? tam klas? nikt inny pr?cz danej firmy nie mo?e jej bra?



data.order = {
    {"?mieci","dupa"100000000},
    {"?mieci","test"100000000},
}
for i,v in ipairs(data.marker) do
    local marker Marker(v[1], v[2], v[3]-.9"cylinder"data.sizedata.color[1], data.color[2], data.color[3], data.color[4])
    setBlipVisibleDistance(createBlipAttachedTo(marker51), 300)
    marker:setData("marker:loading"true)
end

data.window[1] = guiCreateWindow(460269446231"Praca Transportera - ilo?? score: 0"false)
guiWindowSetSizable(data.window[1], false)

data.gridlist[1] = guiCreateGridList(922427154falsedata.window[1])
guiGridListAddColumn(data.gridlist[1], "#"0.1)
guiGridListAddColumn(data.gridlist[1], "Nazwa towaru"0.2)
guiGridListAddColumn(data.gridlist[1], "Typ"0.2)
guiGridListAddColumn(data.gridlist[1], "Wynagrodzenie"0.2)
guiGridListAddColumn(data.gridlist[1], "Wymagany score"0.2)

data.button[1] = guiCreateButton(6218915532"Wybierz zaznaczony towar"falsedata.window[1])
data.button[2] = guiCreateButton(22718915532"Zamknij okno"falsedata.window[1])
guiSetVisible(data.window[1], falseaddEventHandler("onClientGUIClick"resourceRoot, function(buttonstate)
    if button == "left" and state == "up" then
        if source == data.button[1then
            local selected guiGridListGetSelectedItem(data.gridlist[1]) or -1
            if selected 0 then return falseoutputChatBox("Najpierw zaznacz towar!"25500trueend
            
            local id guiGridListGetItemText(data.gridlist[1], selected1)
            local name guiGridListGetItemText(data.gridlist[1], selected2)
            local typ guiGridListGetItemText(data.gridlist[1], selected3)
            local money guiGridListGetItemText(data.gridlist[1], selected4)
            local score guiGridListGetItemText(data.gridlist[1], selected5)
            local v getPedOccupiedVehicle (localPlayer)
            randomResult math.random(1#data.marker)
            local xydata.marker[randomResult][1], data.marker[randomResult][2], data.marker[randomResult][3]
            local location getZoneName xy)
            local miasto getZoneName (xyztrue)
            --then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end 

            if typ == "dupa" and getElementData(localPlayer,"player:firma") == "P" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500trueend


lecz niestety jak zrobi? tak jak ni?ej to ka?dy mo?e bra? towar z danego typu kt?ry niby zablokowa?em

if typ == "dupa" and getElementData(localPlayer,"player:firma") == "P" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500trueend


Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-19, 17:44


_jvneczek







Wiek: 22
Na forum: 4325 dni
Posty: 1513
Nick w MP: _jvneczek

Piwa: 3949

Respekt: 337,5
Respekt: 337,5Respekt: 337,5Respekt: 337,5


data.order = {
    {"?mieci","dupa"100000000},
    {"?mieci","test"100000000},
}
for i,v in ipairs(data.marker) do
    local marker Marker(v[1], v[2], v[3]-.9"cylinder"data.sizedata.color[1], data.color[2], data.color[3], data.color[4])
    setBlipVisibleDistance(createBlipAttachedTo(marker51), 300)
    marker:setData("marker:loading"true)
end

data.window[1] = guiCreateWindow(460269446231"Praca Transportera - ilo?? score: 0"false)
guiWindowSetSizable(data.window[1], false)

data.gridlist[1] = guiCreateGridList(922427154falsedata.window[1])
guiGridListAddColumn(data.gridlist[1], "#"0.1)
guiGridListAddColumn(data.gridlist[1], "Nazwa towaru"0.2)
guiGridListAddColumn(data.gridlist[1], "Typ"0.2)
guiGridListAddColumn(data.gridlist[1], "Wynagrodzenie"0.2)
guiGridListAddColumn(data.gridlist[1], "Wymagany score"0.2)

data.button[1] = guiCreateButton(6218915532"Wybierz zaznaczony towar"falsedata.window[1])
data.button[2] = guiCreateButton(22718915532"Zamknij okno"falsedata.window[1])
guiSetVisible(data.window[1], falseaddEventHandler("onClientGUIClick"resourceRoot, function(buttonstate)
    if button == "left" and state == "up" then
        if source == data.button[1then
            local selected guiGridListGetSelectedItem(data.gridlist[1]) or -1
            if selected 0 then return falseoutputChatBox("Najpierw zaznacz towar!"25500trueend
            
            local id guiGridListGetItemText(data.gridlist[1], selected1)
            local name guiGridListGetItemText(data.gridlist[1], selected2)
            local typ guiGridListGetItemText(data.gridlist[1], selected3)
            local money guiGridListGetItemText(data.gridlist[1], selected4)
            local score guiGridListGetItemText(data.gridlist[1], selected5)
            local v getPedOccupiedVehicle (localPlayer)
            randomResult math.random(1#data.marker)
            local xydata.marker[randomResult][1], data.marker[randomResult][2], data.marker[randomResult][3]
            local location getZoneName xy)
            local miasto getZoneName (xyztrue)
            --then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end 

            if typ == "dupa" and getElementData(localPlayer,"player:firma") == "P" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500truethen return end


Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-19, 18:06


killercycDDS

Migacz






Wiek: 25
Na forum: 4512 dni
Posty: 629
Nick w MP: killer_cyc[DDS]

Piwa: 1659

Respekt: 22

"SataN." napisał/a:


data.order = {
    {"?mieci","dupa"100000000},
    {"?mieci","test"100000000},
}
for i,v in ipairs(data.marker) do
    local marker Marker(v[1], v[2], v[3]-.9"cylinder"data.sizedata.color[1], data.color[2], data.color[3], data.color[4])
    setBlipVisibleDistance(createBlipAttachedTo(marker51), 300)
    marker:setData("marker:loading"true)
end

data.window[1] = guiCreateWindow(460269446231"Praca Transportera - ilo?? score: 0"false)
guiWindowSetSizable(data.window[1], false)

data.gridlist[1] = guiCreateGridList(922427154falsedata.window[1])
guiGridListAddColumn(data.gridlist[1], "#"0.1)
guiGridListAddColumn(data.gridlist[1], "Nazwa towaru"0.2)
guiGridListAddColumn(data.gridlist[1], "Typ"0.2)
guiGridListAddColumn(data.gridlist[1], "Wynagrodzenie"0.2)
guiGridListAddColumn(data.gridlist[1], "Wymagany score"0.2)

data.button[1] = guiCreateButton(6218915532"Wybierz zaznaczony towar"falsedata.window[1])
data.button[2] = guiCreateButton(22718915532"Zamknij okno"falsedata.window[1])
guiSetVisible(data.window[1], falseaddEventHandler("onClientGUIClick"resourceRoot, function(buttonstate)
    if button == "left" and state == "up" then
        if source == data.button[1then
            local selected guiGridListGetSelectedItem(data.gridlist[1]) or -1
            if selected 0 then return falseoutputChatBox("Najpierw zaznacz towar!"25500trueend
            
            local id guiGridListGetItemText(data.gridlist[1], selected1)
            local name guiGridListGetItemText(data.gridlist[1], selected2)
            local typ guiGridListGetItemText(data.gridlist[1], selected3)
            local money guiGridListGetItemText(data.gridlist[1], selected4)
            local score guiGridListGetItemText(data.gridlist[1], selected5)
            local v getPedOccupiedVehicle (localPlayer)
            randomResult math.random(1#data.marker)
            local xydata.marker[randomResult][1], data.marker[randomResult][2], data.marker[randomResult][3]
            local location getZoneName xy)
            local miasto getZoneName (xyztrue)
            --then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end 

            if typ == "dupa" and getElementData(localPlayer,"player:firma") == "P" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500truethen return end


Wyt?umacz mi jedno czemu jak zrobi? tak to dzia?a

if typ == "dupa" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end

A jak ju? tak to ka?dy mo?e bra?

if typ == "dupa" and getElementData(localPlayer,"player:faction"then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end


Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-19, 18:43


Maniekxx

Amator






Wiek: 24
Na forum: 2894 dni
Posty: 232
Nick w MP: Maniekxx

Piwa: 225

Respekt: 110
Respekt: 110

Ostrzeżeń: 20%
Spr?buj jeszcze tak, nie sprawdza?em wi?c nie wiem czy b?dzie dzia?a?:

if typ == "dupa" and getElementData(localPlayer,"player:faction") == "SAPD" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end


Albo wklej tu b??dy z /db3

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-19, 21:32


killercycDDS

Migacz






Wiek: 25
Na forum: 4512 dni
Posty: 629
Nick w MP: killer_cyc[DDS]

Piwa: 1659

Respekt: 22

"Maniekxx" napisał/a:

Spr?buj jeszcze tak, nie sprawdza?em wi?c nie wiem czy b?dzie dzia?a?:

if typ == "dupa" and getElementData(localPlayer,"player:faction") == "SAPD" then outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end


Albo wklej tu b??dy z /db3


i nie b?dzie dzia?a?. Gdyby by?y db3 to bym wcze?niej poda?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-19, 23:23


Qwertick

Coming soon...






Wiek: 23
Na forum: 3577 dni
Posty: 472
Nick w MP: Qwertick

Piwa: 2726

Respekt: 215,8
Respekt: 215,8Respekt: 215,8

if typ == "dupa" then
     if getElementData(localPlayer"player:faction") == "P" then  outputChatBox("Ten towar jest przeznaczony tylko i wy??cznie dla danej firmy"25500true) return end
      ---Reszta... 
end


Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
killercycDDS
Wysłany: 2020-05-20, 00:27


killercycDDS

Migacz






Wiek: 25
Na forum: 4512 dni
Posty: 629
Nick w MP: killer_cyc[DDS]

Piwa: 1659

Respekt: 22

do zamkni?cia

Postaw piwo autorowi tego posta
 

 
Tagi: zlecenia :: dla :: firm
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA » Zlecenia dla firm 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