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

Wysłany: 2020-05-25, 12:19


ZyCzU







Wiek: 20
Na forum: 3204 dni
Posty: 12
Nick w MP: gnd



Respekt: 50

Witam posiadam gamemode paczki PSSM. Niestety suszarki administracyjnej na niej nie by?o wi?c musia?em doda? z innego serwera. Wszystko pi?knie dzia?a (naprawianie itp) tylko nie dzia?a opcja oddawania aut na przecho. Za pomoc daje piwo.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-25, 15:02


szymsoon







Wiek: 31
Na forum: 2370 dni
Posty: 54

Piwa: 1

Respekt: 50

z jakiego gm jest suszarka ?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-25, 15:45


ZyCzU







Wiek: 20
Na forum: 3204 dni
Posty: 12
Nick w MP: gnd



Respekt: 50

"szymsoon" napisał/a:

z jakiego gm jest suszarka ?

PYS 3.0

[ Dodano: 2020-05-25, 15:45 ]
"szymsoon" napisał/a:

z jakiego gm jest suszarka ?

Przerobiony PYS 3.0 z tego co wiem. Wzi??em j? z gm PL RPG,

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-25, 17:07


szymsoon







Wiek: 31
Na forum: 2370 dni
Posty: 54

Piwa: 1

Respekt: 50

daj fragment kodu suszarki kt?ry odpowiada za teleportowanie do przecho , i daj kod przecho .

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-05-25, 18:30


ZyCzU







Wiek: 20
Na forum: 3204 dni
Posty: 12
Nick w MP: gnd



Respekt: 50

Fragment kodu suszarki:

if selected == 2 then
if getElementData(el,"vehicle:spawn") then
exports["pystories-vehicles"]:onSaveVehicle(el)
local query=exports["pystories-db"]:dbSet("UPDATE pystories_vehicles SET parking=1,tp_to_parking=? WHERE id=?", getPlayerName(source),getElementData(el,"vehicle:id"))
if query then
destroyElement(el)
outputChatBox("* Pomy?lnie oddano pojazd na parking.", source)
end
else
outputChatBox("* Ten pojazd nie jest prywatny, u?yj opcji 'Usu? pojazd'", source, 255, 0, 0)
end


Fragment kodu przecho:

addEventHandler("onMarkerHit", mdestroy, function(el,md)
if getElementType(el) == "player" then
local veh=getPedOccupiedVehicle(el)
if not veh then return end
if getVehicleController(veh) ~= el then return end
local id=getElementData(veh,"vehicle:id")
if not id then return end
if isTimer(timeroddania) then return end
setElementFrozen(veh,true)
outputChatBox("* Trwa oddawanie pojazdu do przechowalni...", el,255,255,255,true)
toggleControl(el,"enter_exit",false)
timeroddania=setTimer(function()
setElementFrozen(veh,false)
local id=getElementData(veh,"vehicle:id")
if not id then return end
exports["ogrpg-vehicles"]:onSaveVehicle(veh)
destroyElement(veh)
exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1 WHERE id=?", id)
toggleControl(el,"enter_exit",true)
outputChatBox("* Pomy?lnie zapisano pojazd.", el, 255, 255 ,255 ,true)
end, 3000, 1)
elseif getElementType(el) == "vehicle" then
local peds= getVehicleOccupants(el)
if #peds > 0 then return end
local id=getElementData(el,"vehicle:id")
if not id then return end
if isTimer(timeroddania) then return end
timeroddania=setTimer(function()
setElementFrozen(el,false)
local id=getElementData(el,"vehicle:id")
if not id then return end
exports["ogrpg-vehicles"]:onSaveVehicle(el)
destroyElement(el)
exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1 WHERE id=?", id)
end, 3000, 1)
setElementFrozen(el,true)
setVehicleLocked(el,true)
end
end)

Postaw piwo autorowi tego posta
 

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


Bombelv1

Grzybcio






Wiek: 21
Na forum: 2309 dni
Posty: 24
Nick w MP: Grzybeks

Piwa: 42

Respekt: 50

Witam,

ty masz tak? linijke

local query=exports["pystories-db"]:dbSet("UPDATE pystories_vehicles SET parking=1,tp_to_parking=? WHERE id=?",

a powinna by? taka

local query=exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1,tp_to_parking=? WHERE id=?",

Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
ZyCzU
Wysłany: 2020-05-26, 00:54


PatryKK.

Emeryt LUA






Wiek: 26
Na forum: 3061 dni
Posty: 1060
Nick w MP: PatryKK.

Piwa: 2322

Respekt: 331,5
Respekt: 331,5Respekt: 331,5Respekt: 331,5

Suszarka
if selected == 2 then
if getElementData(el,"vehicle:spawn"then
exports["ogrpg-vehicles"]:onSaveVehicle(el)
local query=exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1,tp_to_parking=? WHERE id=?"getPlayerName(source),getElementData(el,"vehicle:id"))
if query then
destroyElement(el)
outputChatBox("* Pomy?lnie oddano pojazd na parking."source)
end
else
outputChatBox("* Ten pojazd nie jest prywatny, u?yj opcji 'Usu? pojazd'"source25500)
end


Przecho
addEventHandler("onMarkerHit"mdestroy, function(el,md)
if getElementType(el) == "player" then
local veh=getPedOccupiedVehicle(el)
if not veh then return end
if getVehicleController(veh) ~= el then return end
local id=getElementData(veh,"vehicle:id")
if not id then return end
if isTimer(timeroddaniathen return end
setElementFrozen(veh,true)
outputChatBox("* Trwa oddawanie pojazdu do przechowalni..."el,255,255,255,true)
toggleControl(el,"enter_exit",false)
timeroddania=setTimer(function()
setElementFrozen(veh,false)
local id=getElementData(veh,"vehicle:id")
if not id then return end
exports["ogrpg-vehicles"]:onSaveVehicle(veh)
destroyElement(veh)
exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1 WHERE id=?"id)
toggleControl(el,"enter_exit",true)
outputChatBox("* Pomy?lnie zapisano pojazd."el255255 ,255 ,true)
end30001)
elseif getElementType(el) == "vehicle" then
local pedsgetVehicleOccupants(el)
if #peds > 0 then return end
local id=getElementData(el,"vehicle:id")
if not id then return end
if isTimer(timeroddaniathen return end
timeroddania=setTimer(function()
setElementFrozen(el,false)
local id=getElementData(el,"vehicle:id")
if not id then return end
exports["ogrpg-vehicles"]:onSaveVehicle(el)
destroyElement(el)
exports["ogrpg-db"]:dbSet("UPDATE ogrpg_vehicles SET parking=1 WHERE id=?"id)
end30001)
setElementFrozen(el,true)
setVehicleLocked(el,true)
end
end)


Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
ZyCzU
Wysłany: 2020-05-26, 11:04


ZyCzU







Wiek: 20
Na forum: 3204 dni
Posty: 12
Nick w MP: gnd



Respekt: 50

Okej dzi?kuj?. Nie zauwa?y?em tego fragmentu. Dla obu pan?w leci piwko. TEMAT DO ZAMKNI?CIA.

Postaw piwo autorowi tego posta
 

 
Tagi: suszarka :: administracyjna.
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






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