Closed
Description
hi
i am have problem with markers
the problem is if i am set marker size for example 100 and if i am used isElementWithinMarker or "onMarkerHit" or "onMarkerLeave"
will isElementWithinMarker return true and i am not in it
or events will run if i am not in it
and i m made function for solved the problem and Which it
https://wiki.multitheftauto.com/wiki/IsElementInMarker
and this function
https://wiki.multitheftauto.com/wiki/GetElementsInMarker
and i'm putting this functions in https://wiki.multitheftauto.com/wiki/Useful_Functions Someone delete pages
and this pic explain what i'm talking about
the code :
testMarker = createMarker ( 2492 , -1666 , 12.5 , "cylinder" , 100 , 255 , 255 , 255 , 120 )
setTimer( function( )
outputChatBox ( tostring ( isElementWithinMarker ( getElementsByType ( "player" ) [ 1 ] , testMarker ) ) )
end , 100 , 1 )
but if you used my function will the result is
the code :
local testMarker = createMarker ( 2492 , -1666 , 12.5 , "cylinder" , 100 , 255 , 255 , 255 , 120 )
setTimer( function( )
outputChatBox ( tostring ( isElementInMarker ( getElementsByType ( "player" ) [ 1 ] , testMarker ) ) )
end , 100 , 1 )
i hope approval my functions