Wysłany: 2013-03-04, 18:26
monio
Wiek: 30 Na forum: 4887 dni Posty: 319
Nick w MP: Monio99
Piwa : 3565
Co tu jest ?le.Pomuszcie
function create()
local bramaPD = createObject ( 980, -1528.90002, 482.29999, 9 )
local myMarker1 = createMarker(-1530.09998, 484.89999, 1.4, 'cylinder', 5.0, 255, 0, 0, 255)
local myMarker2 = createMarker(-1530, 478.89999, 1.4, 'cylinder', 5.0, 255, 0, 0, 255)
setMarkerColor ( myMarker1, 0, 255, 0, 255 )
setMarkerColor ( myMarker2, 0, 255, 0, 255 )
end
addCommandHandler("create", create)
function markerHit(thePlayer)
if isObjectInACLGroup ( "user."..getAccountName(getPlayerAccount(thePlayer)), aclGetGroup("Pomoc Drogowa")) then
if getElementPosition(bramaPD) == -1528.90002 and 482.29999 and 9 then
moveObject ( bramaPD, 980, -1528.80005, 482.20001, 3.3 )
outputChatBox("Trwa otwieranie bramy PD", thePlayer, 0, 160, 0, true)
elseif getElementPosition(bramaPD) = -1528.80005, 482.20001, 3.3 then
moveObject ( brama21, 980, -1528.90002, 482.29999, 9 )
outputChatBox("Trwa zamykanie bramy PD", thePlayer, 0, 160, 0, true)
end
end
end
addEventHandler("onMarkerHit", myMarker1, markerHit)
addEventHandler("onMarkerHit", myMarker2, markerHit)
Wysłany: 2013-03-05, 13:42
pidbulxd
Wiek: 28 Na forum: 5230 dni Posty: 135
Nick w MP: Word
Piwa : 540
--- Brama
bramaPD = createObject ( 980 , - 1528.90002 , 482.29999 , 9 )
myMarker1 = createMarker (- 1530.09998 , 484.89999 , 1.4 , 'cylinder' , 8.0 , 255 , 0 , 0 , 255 )
function open ( hitElement )
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( hitElement )), aclGetGroup ( "Pomoc Drogowa" )) then
moveObject ( bramaPD , 980 , - 1528.80005 , 482.20001 , 3.3 )
outputChatBox ( "Trwa otwieranie bramy PD" , hitElement , 0 , 160 , 0 , true )
end
end
addEventHandler ( "onMarkerHit" , myMarker1 , open )
function close ( hitElement )
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( hitElement )), aclGetGroup ( "Pomoc Drogowa" )) then
moveObject ( bramaPD , 980 , - 1528.90002 , 482.29999 , 9 )
outputChatBox ( "Trwa zamykanie bramy PD" , hitElement , 0 , 160 , 0 , true )
end
end
addEventHandler ( "onMarkerLeave" , myMaker1 , close )
My?l? ?e powinno smiga?
Edit. Lekka poprawka z thePlayer na hitElement
Wysłany: 2013-03-05, 15:18
monio
Wiek: 30 Na forum: 4887 dni Posty: 319
Nick w MP: Monio99
Piwa : 3565
Sory ale nie dzia?a i mam do cb sprawe napisz domnie 32597981 lub skype jasiek11716 z g?ry dzi?ki
Tagi: brama :: marker.
Anonymous
Na forum: 245 dni
Posty: 1
Anonymous Koniecznie zajrzyj na: