Hey,
ich habe 6 Teleporter, Nummer 1-4 funktionieren Ohne probleme, 5&6 nicht, dass verstehe ich nicht, der Code ist gleich, die Koordinaten 3x überprüft.
Hier mal der Code, hoffe Ihr könnt mir weiterhelfen.
//Edit: Die Marker 5&6 werden erst garnicht angezeigt
Lua
-- TUER INNEN > AUSSEN --
local marker1 = createMarker( -1729.8, 1009.8, -5.2, "corona", 2, 255, 0, 0, 255 )
function swattel1(thePlayer)
if isswat ( player ) then
setElementPosition ( thePlayer, -1757.8, 959, 24.6)
end
addEventHandler("onMarkerHit", marker1, swattel1)
-- TUER AUSSEN > INNEN --
local marker2 = createMarker( -1754.09, 962.7, 24.1, "corona", 2, 255, 0, 0, 255 )
function swattel2(thePlayer)
setElementPosition ( thePlayer, -1728.5, 1013.59, -4.5)
end
addEventHandler("onMarkerHit", marker2, swattel2)
-- DRINNEN > PARKHAUS --
local marker3 = createMarker( -1736.9, 1039.9, -5.2, "corona", 2, 255, 0, 0, 255 )
function swattel3(thePlayer)
if isswat ( player ) then
setElementPosition ( thePlayer, -1723, 1019.7, 16.8)
else
outputChatBox ( "Du bist nicht befugt!", thePlayer, 125, 0, 0 )
end
end
addEventHandler("onMarkerHit", marker3, swattel3)
-- PARKHAUS > DRINNEN --
local marker4 = createMarker( -1717.6, 1018.099, 17.1, "corona", 2, 255, 0, 0, 255 )
function swattel4(thePlayer)
if isswat ( player ) then
setElementPosition ( thePlayer, -1735, 1038.4, -5.15)
else
outputChatBox ( "Du bist nicht befugt!", thePlayer, 125, 0, 0 )
end
end
addEventHandler("onMarkerHit", marker4, swattel4)
-- DRINNEN > DACH --
local marker5 = createMarker( -1739.2, 1032.2, -5, "corona", 2, 255, 0, 0, 255 )
function swattel5(thePlayer)
--if isswat ( player ) then
setElementPosition ( thePlayer, -1771.6, 981.7, 82)
--else
-- outputChatBox ( "Du bist nicht befugt!", thePlayer, 125, 0, 0 )
--end
end
addEventHandler("onMarkerHit", marker5, swattel5)
-- DACH > DRINNEN --
local marker6 = createMarker( -1770.9, 975.9, 82, "corona", 2, 255, 0, 0, 255 )
function swattel6(thePlayer)
--if isswat ( player ) then
setElementPosition ( thePlayer, -1736.8, 1030.5, -5.09)
--else
-- outputChatBox ( "Du bist nicht befugt!", thePlayer, 125, 0, 0 )
--end
end
addEventHandler("onMarkerHit", marker6, swattel6)
Alles anzeigen