Witam.
Dlaczego po od?o?eniu skrzyni, nie usuwa animacji? Za pomoc daj? .
Kod:
[lua] addEventHandler("onClientMarkerHit", cel, function(el, md)
if not md or getElementType(el) ~= "player" then return end
if el ~= localPlayer then return end
if getPedOccupiedVehicle(el) then
outputChatBox("* Nie mo?esz tego od?o?y? b?d?c w poje?dzie !")
return
end
Witajcie, ot?? na serwerze lokalnym gdy mia?em dany gamemode wszystko dzia?a?o idealnie, jednak po wrzuceniu na serwer (mo?e co? ?le wrzuci?em?) wyrzuca errory po klikni?ciu TAB (gdy powinna si? pojawi? animacja podk?adania bomby jak na localu)
Error:
[code] WARNING: /weapon/backpack/server.lua:42: Bad argument @ 'setPedAnimation' [Expected number at argument 8, got boolean]
[/code]
Kod:
[code]
elementBackpack = {}
function playerBackPackToBack(dataName,oldValue)
if getElementType(source) == "player" or getElementType(source) == "ped" then
if (dataName == "MAX_Slots") then
local backpackSlots = getElementData(source,dataName)
if elementBackpack[source] and isElement(elementBackpack[source]) then
exports.bone_attach:detachElementFromBone(elementBackpack[source])
destroyElement(elementBackpack[source])
elementBackpack[source] = false
end
if (backpackSlots == 8) then return end
local x,y,z = getElementPosition(source)
if (backpackSlots == 12 or backpackSlots == 16) then
elementBackpack[source] = createObject(1866,x,y,z)
elseif (backpackSlots == 13 or backpackSlots == 17) then
elementBackpack[source] = createObject(1867,x,y,z)
elseif (backpackSlots == 20 or backpackSlots == 24) then
elementBackpack[source] = createObject(1868,x,y,z)
elseif (backpackSlots == 25 or backpackSlots == 29) then
elementBackpack[source] = createObject(1869,x,y,z)
elseif (backpackSlot...