Author Topic: Add angle limits to attached routines.  (Read 1410 times)

0 Members and 1 Guest are viewing this topic.

jtm2020hyo

  • Newt
  • Posts: 198
Add angle limits to attached routines.
« on: November 18, 2018, 04:06:18 PM »

Is possible to add limiting options to allow code work just in a certain range of angles or ignore block between certain angles choice for the user?

I want to use lisp code to link just with blocks that are between an angle range of 0 grades (variable) and 180 grades ( variable) respect to block base point and their rotation (per each link between blocks), I need to ignore all block between 180 grades and 360 grades respect to block base point and their rotation(per each link between blocks).

kdub_nz

  • Mesozoic keyThumper
  • SuperMod
  • Water Moccasin
  • Posts: 2124
  • class keyThumper<T>:ILazy<T>
Re: Add angle limits to attached routines.
« Reply #1 on: November 18, 2018, 08:41:41 PM »
Perhaps incorperate something like this :-

Code - Auto/Visual Lisp: [Select]
  1. (setq vmin 0.0
  2.       vmax 180.0
  3.       testval2 0
  4.       testval3 22.4
  5.       testval4 180
  6.       testval5 180.1    
  7. )
  8.  
  9. (and (>= testval2 vmin) (<= testval2 vmax))
  10.  
  11. (and (>= testval3 vmin) (<= testval3 vmax))
  12.  
  13. (and (>= testval4 vmin) (<= testval4 vmax))
  14.  
  15. (and (>= testval5 vmin) (<= testval5 vmax))
  16.  
  17.  
  18.  
Called Kerry in my other life
Retired; but they dragged me back in !

I live at UTC + 13.00

---
some people complain about loading the dishwasher.
Sometimes the question is more important than the answer.