Lachuks Posted May 15, 2015 Share Posted May 15, 2015 How do to Markers and text should be above the player? And how do everything to open with the command... local screenX, screenY = guiGetScreenSize () local marker = createMarker ( 645.57184, 874.22052, -36, "arrow", 3, 0, 255, 0, 170 ) function leaderText() local xm,ym,zm = getElementPosition(marker) local x,y = getScreenFromWorldPosition(xm,ym,zm-3.5) local camX,camY,camZ = getCameraMatrix() if (x and y and getDistanceBetweenPoints3D(camX, camY, camZ, xm,ym,zm) <= 80) then dxDrawText ("Hello!", x,y,x,y, tocolor (0, 255, 0, 180) , ( screenX / 1000 ) * 1.8 , "default-bold" , "center" , "center" , false , true , false ) end end addEventHandler ("onClientPreRender", root,leaderText) Link to comment
Mr.unpredictable. Posted May 15, 2015 Share Posted May 15, 2015 Use addCommandHandler for the command and Use attachElements to attach the marker to the head Link to comment
Lachuks Posted May 15, 2015 Author Share Posted May 15, 2015 Use addCommandHandler for the command and Use attachElements to attach the marker to the head can you put it in pzz I rly dont know ho to do it... I one time try and all script dont work Link to comment
Mr.unpredictable. Posted May 15, 2015 Share Posted May 15, 2015 Use addCommandHandler for the command and Use attachElements to attach the marker to the head can you put it in pzz I rly dont know ho to do it... I one time try and all script dont work Post what you made and we will fix it. Link to comment
Walid Posted May 15, 2015 Share Posted May 15, 2015 All what you need is isElementOnScreen() getElementPosition() getPedBonePosition() getDistanceBetweenPoints3D() getScreenFromWorldPosition() isLineOfSightClear() dxGetTextWidth() dxDrawText() 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