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: sie!
1. Nie wiem oco chodzi - Kajdanki nie Zdejmują się!
Gdy nak?adam kajdanki, to potem jak jeszcze raz napisze kajdanki to nie zdejmuje tylko ponownie zak?ada kajdanki, jak si? RC zrobi to nie ma si? ju? wiecie jak to naprawi?, Prosze o pomoc bo nie wiem co robi?.

KOD:[code]
policeVehicles = { [598]=true,[596]=true,[597]=true,[432]=true,[433]=true,[528]=true,[490]=true,[599]=true }

function blokada ( player, seat, jacked )
local kategoria = getElementData(player, "kajdanki")
if kategoria ~= false then
if ( not policeVehicles[getElementModel(source)] ) then
cancelEvent()
outputChatBox("#FF0000Masz kajdanki i nie mo?esz wsi??? do tego pojazdu.",player,255, 0, 0, true)
end
end
end
addEventHandler ("onVehicleStartEnter", getRootElement(), blokada)

function kajdankii ( player, cmd, gracz )
if getElementData(player,'player:duty') and getElementData(player,'player:duty')=='SAPD' then
if not (gracz) then
outputChatBox("B??d! U?yj: /kajdanki <nick/ID> ",player)
return
end
local targetElement=exports['ogrpg-core']:findPlayer(player, gracz)
if targetElement then
local x, y, z = getElementPosition(player)
local tx, ty, tz = getElementPosition(targetElement)

local distance = getDistanceBetweenPoints3D(x, y, z, tx, ty, tz)

if (distance<=10) then
local dokogo=getElementData(targetElement,"kajdanki")
if (not dokogo or not isElement(dokogo)) then
toggleControl(targetElement, "sprin...