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

Wysłany: 2017-01-07, 19:07


Boski1234567891

Młody Skrypter






Wiek: 31
Na forum: 3444 dni
Posty: 89
Nick w MP: Medyk312

Piwa: 1965

Respekt: 25,8

Witam mozna by by?o przerobic ten skrypt zeby auta jak sie wyciaga z przecho respi?y tam gdzie jest przecho?







--[[
    ResourceOURGame v2
    DevelopersSplit <split.programista@gmail.com>
    You have no right to use this code without my permission.
    (c2015 <split.programista@gmail.com>. All rights reserved.
]]

local mdestroy=createMarker(-228.02,1162.51,19.74-3"cylinder",6,200,25,25,75)
createBlipAttachedTo(mdestroy35)

local t=createElement("text")
setElementData(t,"scale",1)
setElementData(t,"name","Pozostawianie pojazd?w")
setElementPosition(t,-228.02,1162.51,19.74)


addEvent("onParkingGetRekords"true)
addEventHandler("onParkingGetRekords"root, function()
    local uid=getElementData(source,"player:uid")
    if not uid then return end
    local org getElementData(source,"player:organization")
    local result=exports["ogrpg-db"]:dbGet("SELECT * FROM ogrpg_vehicles WHERE (ownedPlayer=? OR ownedGroup=?) AND parking=1",uid,org or "Brak")
    if #result > 0 then
        triggerClientEvent(source"onParkingGetVehicles"sourceresult)
    end
end)

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)
        triggerClientEvent(el"dodaj:powiadomienie"root"* Pojazd wje?dza do przechowywalni...")
        toggleControl(el,"enter_exit",false)
        timeroddania=setTimer(function()
            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)
            triggerClientEvent(el"dodaj:powiadomienie"root"* Pojazd zosta? zapisany w przechowywalni.")
        end30001)
    end
end)

addEvent("onParkingVehicleSpawn"true)
addEventHandler("onParkingVehicleSpawn"root, function(id)
    if not id then return end
    local spawn=exports["ogrpg-vehicles"]:onRespawnVehicles(_,id,{-234.44,1154.45,19.45,359.5,0.0,2.7})
    if spawn then
    end
end)


Komentarz luki123luki123 dodany 2017-01-07, 20:08Dodano tag [.lua][/lua]
Ostatnio zmieniony przez luki123luki123 2017-01-07, 20:07, w całości zmieniany 1 raz  
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-07, 19:09


mis14







Wiek: 25
Na forum: 3924 dni
Posty: 185

Piwa: 73

Respekt: -149

local spawn=exports["ogrpg-vehicles"]:onRespawnVehicles(_,id,{-234.44,1154.45,19.45,359.5,0.0,2.7}) 
tu jest kod od respienia aut z przecho ustaw kordy respienia pojazdu

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-07, 19:48


_Haze

Peace Yo!






Wiek: 24
Na forum: 4184 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

kod dawaj w tagach [.lua][./lua] bez kropki

Postaw piwo autorowi tego posta
 

 
Tagi: przecho
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






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