Back once again with a toplogy issue.
I’d like to scale a polygon inwards towards its centre. Initially I tried the normal:
local v1 = Vector3.new(point.x, 0, point.y)
local v2 = v1 - centroid
v2 = v2 * scale + centroid
where ‘centroid’ is the centre of the polygon, and ‘scale’ is the scaling factor. Unfortunately, this does not produce optimal results.
I am now achieving this through offsetting the polygon and doing boolean polygon operations but obviously this isn’t ideal for a game, esp. as I would like to use it in runtime for user-created polygons.
Any ideas on how to achieve this in a less computationally expensive manner?