local entrarInterior = createMarker(2424,-1742,14, 'cylinder', 1.5, 255, 255, 0, 170 ) -- Local onde o marker de entrada ira ser criado.
local sairInterior = createMarker(-27,-31,1004, 'cylinder', 1.5, 255, 255, 0, 170 ) -- Local onde o marker de saida ira ser criado.
--/--
function entrarLocal ( hitElement, matchingDimension )
if getElementType( hitElement ) == "player" and not isPedInVehicle(hitElement) then -- Se o elemento que colidir for um player e não estiver em um veículo então:
setElementPosition(hitElement, -26.691598,-55.714897,1003.546875) -- Posição Do Interior
setElementInterior ( hitElement, 6 ) -- Interior ID
end
end
addEventHandler( "onMarkerHit", entrarInterior , entrarLocal )
--/--
function sairLocal ( hitElement, matchingDimension )
if getElementType( hitElement ) == "player" and not isPedInVehicle(hitElement) then -- Se o elemento que colidir for um player e não estiver em um veículo então:
setElementPosition(hitElement, -26.691598,-55.714897,1003.546875) -- Posição Do Interior
setElementInterior ( hitElement, 6 ) -- Interior ID
end
end
addEventHandler( "onMarkerHit", sairInterior , sairLocal )
Eu estou usando o codigo desta maneira mesmo assim ele teleportame para o céu estou a colocar alguma coisa de errado ?