MaterialLine3d Rotation

Recommended Posts

Hello, I would need your help again, I need to know how I can rotate a dxDrawMaterialLine3D in x,y,z

Sorry for the google translator and thank you for the attention

Share this post

Link to post
bool dxDrawMaterialLine3D ( float startX, float startY, float startZ, float endX, float endY, float endZ, element material, float width,
                          [ int color = white, [ bool postGUI = false, ] float faceTowardX, float faceTowardY, float faceTowardZ ] )

faceTowardX, faceTowardY, faceTowardZ

  • Thanks 1

Share this post

Link to post
11 hours ago, enzoDs said:

rotate a dxDrawMaterialLine3D in x,y,z


This information might also be useful for you:


local x, y, z = 0, 0, 10
local rx, ry, rz = 0, 0, 0

-- test
rx, ry, rz = (rx + math.random(3)) % 360, (ry + math.random(3)) % 360, (rz + math.random(3)) % 360

local m = createMatrix(x, y, z, rx, ry, rz )

local startX, startY, startZ = getPositionFromMatrixOffset(m, 0, 1, 0)
local endX, endY, endZ = getPositionFromMatrixOffset(m, 0, -1, 0)
local faceTowardX, faceTowardY, faceTowardZ = getPositionFromMatrixOffset(m, 1, 0, 0)

(functions are on that topic)



Edited by IIYAMA
  • Thanks 2

Share this post

Link to post

Oh, tanks for the helps!!! 😁😁😁

have a nice day!



Share this post

Link to post

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.