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: setelementparent
1. setElementParent
Witam, mam problem dotycz?cy blip-a, po zastosowaniu tego:
[lua]setElementParent(createBlip(e[1],e[2],e[3], 41 ),marker)[/lua]
wszystko ?adnie dzia?a tylko ?e blip pokazuje si? wszystkim. Po zmianie na to:
[lua]setElementParent(createBlip(e[1],e[2],e[3], 41, 0, 0, 0, 255, plr),marker)[/lua]
blip sie nie tworzy i wyskakuje b??d z
[img]https://i.imgur.com/tnsK0lV.png[/img]

kod
[lua]local function showNextCP(plr)
local idx=getElementData(plr,"egzaminL_postep")
local e=cp[idx]
if not e then
egzaminKoniec(plr,true)
return
end
local marker=createMarker(e[1],e[2],e[3],e.lotniczy and "ring" or "checkpoint", 2, 255,0,0,200,plr)
setElementData(plr,"egzaminL_marker", marker)
setElementParent(createBlip(e[1],e[2],e[3], 41, 0, 0, 0, 255, plr),marker)[/lua]

[ Dodano : 2021-02-06, 22:21 ]
[lua]addEventHandler("onMarkerHit", resourceRoot, function(el,md)

if not isElement(el) or not md or getElementType(el)~="player" then return end

if getMarkerType(source)=="cylinder" then
--[[if (getElementData(el,"player:license:pjC") or 0)>0 then
outputChatBox("Posiadasz ju? prawo jazdy kat.C", el)
return
end]]
egzaminStart(el)
return
end

if not isElementVisibleTo(source, el) then return end

local postep=getElementData(el, "egzaminL_postep")
if not postep then return end -- nie powinno sie wydarzyc

...