dxDrawMaterialLine3D
Client-side
Server-side
Shared
Manual Review Required
Please finish this page using the corresponding Old Wiki article. Go to Contribution guidelines for more information.
This function draws a textured 3D line between two points in the 3D world - rendered for one frame. This should be used in conjunction with onClientPreRender in order to display continuously.
Syntax
bool dxDrawMaterialLine3D ( float startX, float startY, float startZ, float endX, float endY, float endZ, element material, float width, float faceTowardY, float faceTowardZ, [ bool flipUV = false, int color = white, [ string stage = "postfx", ] float faceTowardX ] )Required Arguments
- startX: MISSING_PARAM_DESC
- startY: MISSING_PARAM_DESC
- startZ: MISSING_PARAM_DESC
- endX: MISSING_PARAM_DESC
- endY: MISSING_PARAM_DESC
- endZ: MISSING_PARAM_DESC
- material: A material to draw the line with.
- width: The width/thickness of the line in GTA world units. (This is 1/75th of the width used in dxDrawLine3D)
- faceTowardY: MISSING_PARAM_DESC
- faceTowardZ: MISSING_PARAM_DESC
Optional Arguments
NOTE: When using optional arguments, you might need to supply all arguments before the one you wish to use.
- flipUV (default: false): MISSING_PARAM_DESC
- color (default: white): MISSING_PARAM_DESC
- string stage (default: "postfx", ] float faceTowardX): MISSING_PARAM_DESC
Returns
- bool: value
Returns a true if the operation was successful, false otherwise.
Code Examples
shared
Drawsan imagein coordiantes -2422.68555, -608.78986, 132.56250:
local redcircle = dxCreateTexture("red.png")
x,y,z = -2422.68555, -608.78986, 132.56250
size = 1
addEventHandler("onClientRender", root, function() dxDrawMaterialLine3D(x+size, y+size, z-0.95, x-size, y-size, z-0.95, redcircle, size*2,tocolor(255, 255, 255, 255), false, x, y, z)end)See Also
Drawing Functions
- dxConvertPixels
- dxCreateFont
- dxCreateRenderTarget
- dxCreateScreenSource
- dxCreateShader
- dxCreateTexture
- dxDrawCircle
- dxDrawImage
- dxDrawImageSection
- dxDrawLine
- dxDrawLine3D
- dxDrawMaterialLine3D
- dxDrawMaterialPrimitive
- dxDrawMaterialPrimitive3D
- dxDrawMaterialSectionLine3D
- dxDrawModel3D
- dxDrawPrimitive
- dxDrawPrimitive3D
- dxDrawRectangle
- dxDrawText
- dxDrawWiredSphere
- dxGetBlendMode
- dxGetFontHeight
- dxGetMaterialSize
- dxGetPixelColor
- dxGetPixelsFormat
- dxGetPixelsSize
- dxGetStatus
- dxGetTextSize
- dxGetTexturePixels
- dxGetTextWidth
- dxIsAspectRatioAdjustmentEnabled
- dxSetAspectRatioAdjustmentEnabled
- dxSetBlendMode
- dxSetPixelColor
- dxSetRenderTarget
- dxSetShaderTessellation
- dxSetShaderTransform
- dxSetShaderValue
- dxSetTestMode
- dxSetTextureEdge
- dxSetTexturePixels
- dxUpdateScreenSource