Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

create line in unity

// you need the LineRenderer component in your object

var line = gameObject.AddComponent<LineRenderer>();

line.SetPosition(0, startingPoint);
line.SetPosition(1, middlePoint);
line.SetPosition(2, endPoint);
 
PREVIOUS NEXT
Tagged: #create #line #unity
ADD COMMENT
Topic
Name
5+2 =