Creates a linear gradient that transitions between the specified color
stops along the line from ‘from’ to ‘to’.Example:
Copy
Ask AI
local g = Gradient.linear(Vec2D.xy(0, 0), Vec2D.xy(100, 0), {{ position = 0, color = Color.rgb(255, 0, 0) },{ position = 1, color = Color.rgb(0, 0, 255) },})