Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1.
- addEventHandler ( "onResourceStart", getResourceRootElement (getThisResource ()),
- 2.
- function()
- 3.
- object1 = createObject ( 6189, -2291.0466308594, 4963.0712890625, -12.259666442871, 0, 0, 0 )
- 4.
- object2 = createObject ( objectid, posX, posY, posZ, rotX, rotY, rotZ )
- 5.
- moveObjects()
- 6.
- moveLift()
- 7.
- end)
- 8.
- 9.
- function moveObjects()
- 10.
- moveObject ( object1, 10000 , -2291.0466308594, 4963.0712890625, -12.259666442871, 0.000000, 0.000000, 90.000000 )
- 11.
- setTimer ( moveBack, 10000 , 1 )
- 12.
- end
- 13.
- 14.
- function moveBack()
- 15.
- moveObject ( object1, 10000 , -2291.0466308594, 4963.0712890625, -12.259666442871, 0.000000, 0.000000, 90.000000 )
- 16.
- setTimer ( moveObjects, 10000 , 1 )
- 17.
- end
- 18.
- 19.
- function moveLift()
- 20.
- moveObject ( object2, 16000, newX, newY, newZ, 0, 0, 0)
- 21.
- setTimer ( liftBack, 18000, 1 ) -- the difference between 16000 and 18000 is 2000, so it waits 2 seconds before it moves back
- 22.
- end
- 23.
- 24.
- function moveLift()
- 25.
- moveObject ( object2, 16000, oldX, oldY, oldZ, 0, 0, 0)
- 26.
- setTimer ( moveLift, 18000, 1 ) -- the difference between 16000 and 18000 is 2000, so it waits 2 seconds before it moves back
- 27.
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement