Jump to content

Distance-angle mode in Python Scripting?


Recommended Posts

Hi David,

   You might use the vs.Ang2Vec() function to convert Polar coordinates to Cartesian coordinates.

 

import vs

P = vs.Ang2Vec(45, 1)    # return XY coordinates of 1 distance unit at 45°
vs.Message(P[0], '   ', P[1])
vs.SysBeep()

 

Depending on what you are trying to do, this may or may not make you happy.

 

Raymond
 

Link to comment

Hi David,

   I don't think there is. That  shorthand way was integrated into the VS Compiler way back in the Dark Ages before "Vectorworks", or "VectorWorks", yes, in the early MiniCAD years. It is definitely not a typical Pascal convention for number entry. It's not something I would expect to have been migrated to the Python engine.

 

Raymond 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...