Search Unity

Question Tile object between two other objects

Discussion in 'Editor & General Support' started by melodycatt, Feb 27, 2024.

  1. melodycatt

    melodycatt

    Joined:
    Feb 20, 2023
    Posts:
    2
    Basically, I want to draw a cylindrical line between two objects, and what I thought I could do is have a basic 1 unit long cylinder and then tile it between the two objects. Its easiest to demonstrate this in blender so i have uploaded a screenshot. If there is a better method to achieve this effect let me know and explain how to do it.

    Oh also how do I change my forum name? It has the name from my old google account I created when I was, like, 9 and I've changed my unity name since then
     

    Attached Files:

  2. spiney199

    spiney199

    Joined:
    Feb 11, 2021
    Posts:
    7,827
    You could just use the one cylinder and scale it on it's local axis. If your cylinder is one unit long, then you only need scale it by half the distance between the two cubes. Would need to rotate it of course, so you might have issues with non-uniform scaling in the end.

    Does it need to be 3d? Could you use a line-renderer?
     
  3. melodycatt

    melodycatt

    Joined:
    Feb 20, 2023
    Posts:
    2
    Firstly, I cant just scale it because I want arrows on the line so stretching it won't work, and I cant use line renderer for similar reasons and I'd prefer if the line was 3D @spiney199