rotation command in dynamic block not behaving as intended

rotation command in dynamic block not behaving as intended

Anonymous
Not applicable
1,550 Views
9 Replies
Message 1 of 10

rotation command in dynamic block not behaving as intended

Anonymous
Not applicable

Hi guys,

 

I'm sure I posted this a while ago but I can't seem to find my post. Also, I am still trying to figure it out. I've attached the block as reference.


So what I am trying to do is have a dynamic block which automatically updates an attribute according to the length of a line (which is variable). This part is working fine.

Next I need the text to rotate separate from the line. Also working fine.

I have two visibility states, text on and text off. Working fine.

Lastly I need to be able to rotate the whole block. Here is the issue. When I include the stretch parameters the block rotates are an angel different from the mouse cursor. When I exclude the stretch parameters it rotates perfectly but of course doesn't rotate the parameters as well (meaning the stretch action become void).

 

I hope I explained that ok.

 

Please help.

0 Likes
Accepted solutions (3)
1,551 Views
9 Replies
Replies (9)
Message 2 of 10

ojuris
Advisor
Advisor
Accepted solution

hi!

 

For linear parameter Distance1 chain action switch to No

Add linear parameter Distance1 in rotation action Rotate2

Message 3 of 10

Libbya
Mentor
Mentor
Accepted solution

Change the distance1 parameter in properties so that it is chained = NO.  Add distance1 to the rotate action.  See screencast.

Message 4 of 10

Anonymous
Not applicable

Thanks so much!

 

Was driving me bonkers.

 

Can you explain why that fixes the problem? 

0 Likes
Message 5 of 10

ojuris
Advisor
Advisor

why do you use chain option to that linear parameter?

don't use chaining option if you really don't need it or you get that result 🙂

0 Likes
Message 6 of 10

Anonymous
Not applicable

I don't think I turned I turned it on, maybe it defaults like that. I will keep a closer eye in future.

Thank you

0 Likes
Message 7 of 10

ojuris
Advisor
Advisor

I have not seen that it is turned on by default

 

Sometimes it is very useful but sometimes cause big problems

 

Best Regards

0 Likes
Message 8 of 10

Libbya
Mentor
Mentor
Accepted solution

When a parameter is chained, then any time the parameter is altered, the actions that are associated with the parameter will be activated as well.  When that parameter is rotated, both endpoints move.  Because they both move, both of the stretch actions are activated and the result is that the object is both rotated AND stretched.  Interestingly enough, another solution if you NEED the chained parameter for some other reason, is to keep it chained and remove the line from the rotation parameter.  That way, when the linear parameter is rotated, the chained stretch actions stretch the line endpoints the same amount and the line is rotated.  Parameters are never chained by default.  The attached screencast shows the block working by rotating the chained linear parameter and removing the line from the rotate action. 

Message 9 of 10

Anonymous
Not applicable

Thank you so much for the detailed response. I really appreciated it.

 

I was thinking back to when I made it and yes I must've turned on the chaining. I think I thought that it needed to be on for both ends to stretch together.

 

Can I ask why one would use chain?

0 Likes
Message 10 of 10

Libbya
Mentor
Mentor

Being able to chain parameters can be very useful for a variety of functions.  Here's a common one:  https://forums.autodesk.com/t5/dynamic-blocks/keep-att-horizontal-while-rotating-block/m-p/6592891