Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.
GTAONLINE.PL
Tematy otagowane jako: jednoczesne
1. Jednoczesne chowanie i wyciąganie
Witam mam problem, ot?? gdy wpisuj? komend? na wyci?gni?cie noszy jednocze?nie si? chowaj?. Za pomoc R* i :piwo:

KOD
[lua]
--[[
Autor: IgorPL222
Nie zezwalam na usuwanie tej notatki :)
--]]

local objectnosze = {}
local nosze = {}
local mrk = {}
local cols = {}
local timer = {}
resourceRoot = getResourceRootElement(getThisResource())

function dnosze(plr)
local accName = getAccountName ( getPlayerAccount ( plr ) )
if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then
x,y,z = getElementPosition(plr)
x2,y2,z2 = getElementRotation(plr)
local veh = getPedOccupiedVehicle(plr)
if not veh then return end
mrk[veh] = createMarker(0, 0, 0, "cylinder", 2, 255, 0, 0, 50)
attachElements(mrk[veh], veh, 0, -4, -1)
objectnosze[veh] = createObject(1997, 0, 0, 0, 0, 0, 0)
setElementCollisionsEnabled(objectnosze[veh], false)
attachElements(objectnosze[veh], veh, 0, -1, -0.5)
outputChatBox("Dodano nosze do karetki!", plr, 255, 255, 255)
end
end
addCommandHandler("dnosze", dnosze)

function onMarker(plr)
local accName = getAccountName ( getPlayerAccount ( plr ) )
if isObjectInACLGroup ("user."..accName, aclGetGroup ( "PR" ) ) then
outputChatBox("Aby wzi???/schowa? nosze wpisz: /wez-nosze", plr, 255, 255, 255)
setElementData(plr, "able:to:nosze", true)
end
end
addEventHandler("onMarkerHit", resourceRoot, onMar...