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

Wysłany: 2018-03-15, 18:03


TheTren







Wiek: 35
Na forum: 3516 dni
Posty: 17
Nick w MP: TheTren

Piwa: 1604

Respekt: 55,3

Ostrzeżeń: 100%
Witam, mam ma?y problem mam sobie skrypt na gz chcia?bym ?eby po wjechaniu w marker i po wpisaniu "/zamontuj" odje?o graczowi 1000 PLN i da?o mu gz (rh1)
Da rade kto? mi to zwyk?y kod pod gz tak przerobi? xd ? lub wys?a? inny skrypt tak zrobiony xd ?

Kod:

function getVehicleHandlingProperty ( element, property )
if isElement ( element ) and getElementType ( element ) == "vehicle" and type ( property ) == "string" then
local handlingTable = getVehicleHandling ( element )
local value = handlingTable[property]

if value then
return value
end
end

return false
end

function o(c)
if c then
local gora = getElementData(c, "rh:up") or 0
local s=getVehicleHandlingProperty(c,"suspensionForceLevel")
if tonumber(gora) == 4 then outputChatBox("Osi?gn??e? limit regulacji zawieszenia!", getVehicleController(c), 255, 255, 255) cancelEvent() return end
setVehicleHandling(c,"suspensionForceLevel",tonumber(s) - 0.19)
setElementData(c, "rh:up", gora+1)
outputChatBox("Obni?y?e? auto k****",getVehicleController(c),255,255,255,true)
end
end
addEvent("rh:o", true)
addEventHandler("rh:o", root, o)
function p(c)
if c then
local gora = getElementData(c, "rh:up") or 0
local s=getVehicleHandlingProperty(c,"suspensionForceLevel")
if tonumber(gora) == -8 then outputChatBox("Osi?gn??e? limit regulacji zawieszenia!", getVehicleController(c), 255, 255, 255) cancelEvent() return end
setVehicleHandling(c,"suspensionForceLevel",tonumber(s) + 0.19)
setElementData(c, "rh:up", gora-1)
outputChatBox("Podwy?szy?e? auto gnojuwo",getVehicleController(c),255,255,255,true)
end
end
addEvent("rh:p", true)
addEventHandler("rh:p", root, p)

addEventHandler("onPlayerVehicleEnter", root,
function(car, seat)
if seat ~= 0 then return end
if getElementData(car, "auto:id") and getElementData(source, "player:kid") then
local qr = exports['ogrpg-db']:dbGet("SELECT * FROM ogrpg_vehicles WHERE id=? AND rh=?",getElementData(car, "vehicle:id"), "1")
if #qr == 1 then

end
end
end)


Postaw piwo autorowi tego posta
 

 
Tagi: rh1 :: montowanie :: pod :: komęde
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA » rh1 montowanie pod komęde 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