Wysłany: 2021-03-19, 22:41
HubertK
Wiek: 20 Na forum: 2451 dni Posty: 21
Nick w MP: Ave
Piwa : 73
Siema, potrzebuje pomocy. mam tutaj kod na wyci?ganie torby R1 ale chce te? aby osoby ze grupy ACL "SAMD" mogli k?a?? torb? na ziemi. Tak wiem jest funkcja DestroyElement oraz createObject lecz nie ogarniam tego.
prosi?bym o gotowy kodzik
KOD:
Kod:
function weztorba (plr)
local login = getAccountName(getPlayerAccount(plr))
if isObjectInACLGroup("user."..login,aclGetGroup("SAMD", plr)) then
local auto = getPedOccupiedVehicle(plr)
if isPedInVehicle(plr) then
if (getElementModel(auto) == 489) or (getElementModel(auto) == 407) or (getElementModel(auto) == 416) then
local torba = createObject(1248, 0, 0, 0, 0, 0, 0)
setElementData ( plr, "torba", torba)
exports.bone_attach:attachElementToBone(torba,plr,12,0,0.1,0.3,0,180,0)
outputChatBox("Bierzesz torb? r1 z karetki.", plr)
end
end
end
end
addCommandHandler("r1", weztorba)
-------------------------------------------------
function odloztorbe(plr)
local login = getAccountName(getPlayerAccount(plr))
if isObjectInACLGroup("user."..login,aclGetGroup("SAMD", plr)) then
local auto = getPedOccupiedVehicle(plr)
if isPedInVehicle(plr) then
if (getElementModel(auto) == 489) or (getElementModel(auto) == 416) then
local torba = getElementData ( plr, "torba")
destroyElement(torba)
outputChatBox("Chowasz torb? r1 do karetki.", plr)
end
end
end
end
addCommandHandler("or1", odloztorbe)
ZA POMOC STAWIAM PIWKO
Więcej szczegółów
Wystawiono 1 piw(a):borsuk
Wysłany: 2021-03-20, 12:52
Wilq
Wiek: 24 Na forum: 4428 dni Posty: 3410
Piwa : 739
Je?li chcesz zrobi? czynno?? pod ACL u?yj
Więcej szczegółów
Wystawiono 1 piw(a):borsuk
Wysłany: 2021-03-20, 13:19
HubertK
Wiek: 20 Na forum: 2451 dni Posty: 21
Nick w MP: Ave
Piwa : 73
Wilq ,
Wiem jak zrobi? to pod acl. Chce to zrobi? ?eby da?o si? t? torb? k?a?? na ziemie
Więcej szczegółów
Wystawiono 1 piw(a):borsuk
Tagi: torba
Anonymous
Na forum: 245 dni
Posty: 1
Anonymous Koniecznie zajrzyj na: