Shape Bender and SU2019

I can see where the error is arising !
In almost all of the API methods passing an argument as a vertex instead of a point is acceptable.
There seems to have been a ‘reversion’ in v2019.
The entities.add_text method expects a ‘string’ and a ‘point’ [there is a 3rd optional ‘vector’].
In @ChrisFullmer 's code he passes the ‘vertices’ of the selected line and arc to some temporary text entities - as if they were ‘points’.
This has always worked in earlier versions !

There is a fix…
If the file …/Plugins/clf_shape_bender/clf_shape_bender_data.rb is edited with a plain text editor there are four lines to tweak…
Lines# 290, 291 and 302, 303
At the end of those lines add .position [so that the vertex position [i.e. a point] is used instead of the vertex itself]
So for example:
start_label = Sketchup.active_model.entities.add_text “Start”, @line_endverts[0]
becomes
start_label = Sketchup.active_model.entities.add_text “Start”, @line_endverts[0].position
Then it should work as before.
Perhaps @ChrisFullmer can publish an updated RBZ.
Under its quoted: Smustard - the Companion to Sketchup(TM)
Modifying it yourself, even for your own use, is disallowed ?
I think… so obviously I have not been able to check if my fix works :wink:

8 Likes