Tete omar Posted June 27, 2012 Share Posted June 27, 2012 server side addEvent ("myCustomEvent", true ) function myCustomEvent() fadeCamera ( source, false ) setElementPosition ( source, -2416.0766601563, -604.67163085938, 132.5625 ) setCameraTarget ( source ) setTimer ( fadeCamera, 1000, 1, source, true, 9 ) end addEventHandler("myCustomEvent", getRootElement(), myCustomEvent) client side local Jarker = createMarker ( -2388.5144042969, -579.02172851563, 131.1171875, "cylinder", 4, 255, 0, 0, 255 ) addEventHandler('onClientMarkerHit', Jarker,function(hitPlayer,thePlayer) if (hitPlayer == localPlayer) then triggerServerEvent("myCustomEvent", localPlayer) end end) here's the result https://www.youtube.com/watch?v=fcew-tnj ... ature=plcp it fadeCamera after spawn, i want it while the spawn not after Link to comment
Guest Guest4401 Posted June 28, 2012 Share Posted June 28, 2012 addEvent ("myCustomEvent", true ) function myCustomEvent() fadeCamera ( source, false ) setTimer( function() setElementPosition ( source, -2416.0766601563, -604.67163085938, 132.5625 ) setCameraTarget ( source ) fadeCamera( source, true ) end, 1000, 1 ) end addEventHandler("myCustomEvent", getRootElement(), myCustomEvent) Link to comment
Tete omar Posted June 28, 2012 Author Share Posted June 28, 2012 addEvent ("myCustomEvent", true ) function myCustomEvent() fadeCamera ( source, false ) setTimer( function() setElementPosition ( source, -2416.0766601563, -604.67163085938, 132.5625 ) setCameraTarget ( source ) fadeCamera( source, true ) end, 1000, 1 ) end addEventHandler("myCustomEvent", getRootElement(), myCustomEvent) bad argument at 'setElementPosition' & 'fadeCamera' & 'setCameraTarget' and only black screen Link to comment
Guest Guest4401 Posted June 28, 2012 Share Posted June 28, 2012 addEvent ("myCustomEvent", true ) function myCustomEvent() local player = source fadeCamera ( source, false ) setTimer( function() setElementPosition ( player, -2416.0766601563, -604.67163085938, 132.5625 ) setCameraTarget ( player ) fadeCamera( player, true ) end, 1000, 1 ) end addEventHandler("myCustomEvent", getRootElement(), myCustomEvent) Link to comment
Guest Guest4401 Posted June 28, 2012 Share Posted June 28, 2012 Thanks ! it worked You're welcome. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now