Draw line in billoard mode aligned with xz plane instead of facing camera

Avatar
  • updated
  • Answered
Hi, I'm trying to draw a line on the xz plane in billboard mode. The default behavior appears to rotate the billboard to face the camera (see red arrow in image). Instead, I want the line caps to lie flat on the xz plane so that the billboard is always facing up along the y axis (in line with the green arrow).

I'm happy to modify the code to achieve this if you could give me some pointers? Great asset btw :)

Image 400


Reporting a bug? please specify Unity version:
2019.4.17f1
Reporting a bug? please specify Shapes version:
3.2.3
Reporting a bug? please specify Render Pipeline:
Built-in render pipeline
Pinned replies
Avatar
Freya Holmér creator
  • Answer
  • Answered

Hey! set the geometry to flat2D and rotate the gameobject. The points are in local space of the transform it sits on, so you can make it align with your xz plane, or any other plane :)

Avatar
chris gregan
Quote from Freya Holmér

Hey! set the geometry to flat2D and rotate the gameobject. The points are in local space of the transform it sits on, so you can make it align with your xz plane, or any other plane :)

Worked a treat - thanks!

Avatar
Freya Holmér creator
  • Answer
  • Answered

Hey! set the geometry to flat2D and rotate the gameobject. The points are in local space of the transform it sits on, so you can make it align with your xz plane, or any other plane :)