function PlayerHitInMarkerLeaveBox(hitElement)
if (isElement(hitElement) and getElementType(hitElement) == "player") then
if TbPlEmp[hitElement] and source == TbPlEmp[hitElement]["marker"] then
if TbPlEmp[hitElement]["box"] and isElement(TbPlEmp[hitElement]["box"]) and isElementWithinMarker(TbPlEmp[hitElement]["box"],source) then
outputChatBox("#FFAA00||#00FF00 ✔ #FFAA00||#00FF00 ok !",hitElement,255,255,255,true)
else
outputChatBox("#FFAA00||#FF0000 ✘ #FFAA00||#FF0000 error !",hitElement,255,255,255,true)
end
end
end
end
addEventHandler("onMarkerHit",root,PlayerHitInMarkerLeaveBox)
My problem here is, everything works fine excerpt box check in marker does anyone have any idea why?
- Always returns false