Incremental Rotation - parameter? constraint?

Incremental Rotation - parameter? constraint?

oiverson
Enthusiast Enthusiast
973 Views
10 Replies
Message 1 of 11

Incremental Rotation - parameter? constraint?

oiverson
Enthusiast
Enthusiast

I have a block that's a tag and a leader - currently I have 4 visibility states and a constraint on the leader angle to 60 degrees. The user can drag the tag anywhere they want (via a polar parameter with a move action) and the angle of the leader stays consistent.

I was curious if I could let the currently constrained leader rotate in 15 degree (or 30 degree, whatever) increments as I drag that polar paramter around. The point being that I would rather not introduce a new grip for the rotation - I'd like the leader to adjust as needed through the set increments.

For the life of me I can't figure it out. I've been playing all day with rotation parameters chained to the polar, rotation dimensional constraints... and all sorts of combinations trying to figure out how this might work (if at all).

attached is my current block.

Any help in understanding how (or if) I can tie these things together would be appreciated!

0 Likes
974 Views
10 Replies
Replies (10)
Message 2 of 11

Libbya
Mentor
Mentor

See attached.  Is that what you're after?

0 Likes
Message 3 of 11

oiverson
Enthusiast
Enthusiast

😳

AND you added the flip??

 

on seeing it, I was envisioning a slightly different behavior, but yes, this is exactly what I was trying to do. In my head I was thinking the horizontal leg would lengthen and stretch as it does in my block with my fixed angle.

Thank you so much! 

Message 4 of 11

Libbya
Mentor
Mentor

I don't see how you can have a single grip that both changes the angle and causes the lengthening of the leg at the tag.  You could certainly add a linear parameter and stretch for that leg length, though.  

0 Likes
Message 5 of 11

oiverson
Enthusiast
Enthusiast

Yeah I think this was my hangup, which your block made immediately clear! But thank you so much for the help 🙂

0 Likes
Message 6 of 11

oiverson
Enthusiast
Enthusiast

Does the order of the actions matter? I'm having trouble replicating your block - would you mind doing a simple recap of how you built this?

0 Likes
Message 7 of 11

Libbya
Mentor
Mentor

If you post your current version then I'll diagnose it.  

0 Likes
Message 8 of 11

oiverson
Enthusiast
Enthusiast

thanks - I'm trying to learn how to use lookup tables for the flip. I think I have the other stuff working tho

 

EDIT: just saw your double lookup post that's pinned... I KNEW I was missing something!

oiverson_0-1725564179774.png

 

Now that I'm seeing this double-lookup concept, is it that a single lookup parameter won't allow you to directly use one parameter to set another, so you have to do a "2-step" thing, "this parameter sets this value, then have a reverse lookup of that value to set a separate parameter".

 

My brain def is grinding on this, but I think I get it. Just need to digest some more. But thank you for unlocking this new potential of double lookups.

0 Likes
Message 9 of 11

oiverson
Enthusiast
Enthusiast

What is the syntax or language behind this??
(,90d0'],(270d0',)  Base State

(90d0',270d0']       Flipped State 

0 Likes
Message 10 of 11

Libbya
Mentor
Mentor

@oiverson wrote:

What is the syntax or language behind this??
(,90d0'],(270d0',)  Base State

(90d0',270d0']       Flipped State 


Those are range values.  Range values are typically lower number, comma, then upper number with both numbers and comma surrounded by either parentheses or brackets.  It's funny to me that only one of the three of the above range values actually fits that description, but I'll explain further.  If the number to the left of the comma is missing then the range continues down for all values below the number to the right of the comma.  If the number to the right of the comma is missing then the range value includes all values above the number to the left of the comma.  A bracket beside a number means that the number is included in the range.  A parenthesis next to a number means that the value does not include the number.  
(,90d0'],(270d0',)  is two range values separated by a comma.  The first range value (,90d0'] includes all angles less than 90 degrees AND includes 90°.  The second range value (270d0',) includes all angles greater than 270 degrees and does not include 270°.

(90d0',270d0'] is a range value of all angles between 90 degrees and 270 degrees and includes 270° but does not include 90°.

Hope that helps.

Message 11 of 11

oiverson
Enthusiast
Enthusiast

It's exactly what I was curious about. I couldn't figure out the logic of the parens and brackets, so assumed there must be some coded function to them. The commas were just melting my brain.

 

Thanks again!

0 Likes