Drawing a Polygon in Canvas

I’m trying to draw a hexagon from code and I see it in the scene view perfectly matching the silhouette it’s supposed to fit, but I can’t figure out how to actually draw it on-screen in game. I attached a Canvas Renderer to it, but that didn’t seem to do anything.

Hi, you need to pass quads to the CanvasRenderer, and also have a texture / material set. It needs to live under a Canvas.

So I can’t draw my pretty little hexagonal graph? :frowning:

Not unless you can draw it with a quad.

its a current limitation of the canvas it only knows how to draw quads.

You can ‘mimic’ this by setting the last two verts to be the same point :wink:

Ooooooooh. :slight_smile: