<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Dummy lifting one side of a solid object in 3ds Max Animation and Rigging Forum</title>
    <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11393035#M1237</link>
    <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1837903"&gt;@giuseppetonello&lt;/a&gt;&amp;nbsp;do you have an acceptable solution to your rigging question?&amp;nbsp; If so, great!&amp;nbsp; If not, I think I have an approach that might work.&amp;nbsp; Rather than having separate dummies that determine the behavior of the object I'd like to explore having one "lifting" dummy whose location&amp;nbsp; would determine which corner(s) of a box would act as pivots.&amp;nbsp; Is it fair to assume that the object will be a box?&amp;nbsp; In the physical world the point(s) of pivot for an object would be a function of the location of the lifting force, the center of gravity of the object and where the object touches the base plane.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 31 Aug 2022 14:01:33 GMT</pubDate>
    <dc:creator>leeminardi</dc:creator>
    <dc:date>2022-08-31T14:01:33Z</dc:date>
    <item>
      <title>Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373605#M1232</link>
      <description>&lt;P&gt;What I'm trying to achieve is to control a dummy by moving it along its z axis. This dummy, then, should lift one corner of my rigged object (a box, for simplicity). See this image for the setup&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="a1 copy.jpg" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1106615iFC94A1891272A611/image-size/medium?v=v2&amp;amp;px=400" role="button" title="a1 copy.jpg" alt="a1 copy.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Once the linked dummy goes up, the object goes up partially (a corner goes up, two corners come up a bit and the remaining one acts as a pivot)&lt;/P&gt;&lt;P&gt;To give an example, imagine to lift with your fingers only one corner of your smartphone: that angle comes up, while the opposite one (diagonally) stays down.&lt;/P&gt;&lt;P&gt;See this other image&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="a2 copy.jpg" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1106623i18863B821CEBD261/image-size/medium?v=v2&amp;amp;px=400" role="button" title="a2 copy.jpg" alt="a2 copy.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;This concept should work, ideally, for each dummy.&lt;/P&gt;&lt;P&gt;Any idea on how should I rig this?&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 15:36:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373605#M1232</guid>
      <dc:creator>giuseppetonello</dc:creator>
      <dc:date>2022-08-22T15:36:26Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373932#M1233</link>
      <description>&lt;P&gt;For each Dummy create some obj. in opposite corner and set it as its "Look at" target...&lt;/P&gt;&lt;P&gt;That objects will go up-down.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Supposing you know how to set up first part?&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 18:18:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373932#M1233</guid>
      <dc:creator>domo.spaji</dc:creator>
      <dc:date>2022-08-22T18:18:35Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373994#M1234</link>
      <description>&lt;P&gt;Edit:&lt;/P&gt;&lt;P&gt;No - it won't work that way...&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 18:51:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11373994#M1234</guid>
      <dc:creator>domo.spaji</dc:creator>
      <dc:date>2022-08-22T18:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11375747#M1235</link>
      <description>&lt;P&gt;I think I might use some kind of ik solver, but when I do, only one dummy works as intended. The other three don't move at all.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Aug 2022 13:26:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11375747#M1235</guid>
      <dc:creator>giuseppetonello</dc:creator>
      <dc:date>2022-08-23T13:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11388888#M1236</link>
      <description>&lt;P&gt;Forgot about this one...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This can be rigged by using 4 pairs of bones...&lt;/P&gt;&lt;P&gt;Linking all &lt;STRONG&gt;parent&lt;/STRONG&gt; bones in hierarchy and Box obj. as a last in that hierarchy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Although for this kind of situations&amp;nbsp; there is "Link Constraint" controller for changing links in time.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Aug 2022 21:37:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11388888#M1236</guid>
      <dc:creator>domo.spaji</dc:creator>
      <dc:date>2022-08-29T21:37:10Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11393035#M1237</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1837903"&gt;@giuseppetonello&lt;/a&gt;&amp;nbsp;do you have an acceptable solution to your rigging question?&amp;nbsp; If so, great!&amp;nbsp; If not, I think I have an approach that might work.&amp;nbsp; Rather than having separate dummies that determine the behavior of the object I'd like to explore having one "lifting" dummy whose location&amp;nbsp; would determine which corner(s) of a box would act as pivots.&amp;nbsp; Is it fair to assume that the object will be a box?&amp;nbsp; In the physical world the point(s) of pivot for an object would be a function of the location of the lifting force, the center of gravity of the object and where the object touches the base plane.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Aug 2022 14:01:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11393035#M1237</guid>
      <dc:creator>leeminardi</dc:creator>
      <dc:date>2022-08-31T14:01:33Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11393166#M1238</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/822616"&gt;@leeminardi&lt;/a&gt;&amp;nbsp;I still haven't found a solution. And yes, it's safe to assume that I'd like to apply this rig on a box.&lt;/P&gt;</description>
      <pubDate>Wed, 31 Aug 2022 14:56:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11393166#M1238</guid>
      <dc:creator>giuseppetonello</dc:creator>
      <dc:date>2022-08-31T14:56:35Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11395971#M1239</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1837903"&gt;@giuseppetonello&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I do not have a full solution yet but thought I would give you a progress report.&amp;nbsp; The attached file allows you to lift one corner of a box (move point object &lt;STRONG&gt;ptF&lt;/STRONG&gt; vertically) and the opposing corner of the box will drag along a plane as ptF rises.&amp;nbsp; &lt;STRONG&gt;ptC&lt;/STRONG&gt;&amp;nbsp;uses a script controller to locate it on the plane a distance "S" from ptF where S is the length of the diagonal of the top of the box.&lt;/P&gt;&lt;P&gt;The Script Controller for ptC is:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;s = (boxWidth^2 + boxLength^2)^0.5
format "\ns = %" s
v = s * normalize([boxWidth,boxLength,0])
p = ptF + [boxWidth, boxLength,0]
g = [p.x, p.y,0] -- initial guess
for i = 1 to 10 do
(
g = ptF + normalize(g - ptF) * s 
g = [g.x, g.y,0]
d = distance ptF g 
format "\ni = %,   d = %" i d
i = i + 1
)
g&lt;/LI-CODE&gt;&lt;P&gt;An initial guess "g" is made for the location of ptC that is a distance &lt;STRONG&gt;s&lt;/STRONG&gt; from &lt;STRONG&gt;ptF&lt;/STRONG&gt;.&amp;nbsp; 10 successive guesses are then made to get a good approximation for the location of the opposing corner.&amp;nbsp; I might modify this to stop guessing once sufficient precision is achieved.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The transform script for the box is:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;alpha = -atan( boxLength/boxwidth)
vx =  normalize(ptC - ptF)
vy = normalize(cross [0,0,1] vx)
vz = normalize(cross vx vy)
m = (matrix3 vx vy vz ptF)
axisPt =  ptF
vv = normalize(cross (ptC - ptF) [0,0,1])
vectorAxis = normalize(cross (ptC - ptF) vv)
translate m -ptF
rotate m (quat alpha vectorAxis)
translate m ptF
m&lt;/LI-CODE&gt;&lt;P&gt;It uses the location of ptC to define a vector from ptF to the opposing corner location. This vector is used to determine the rotation of the box to align it appropriately.&lt;/P&gt;&lt;P&gt;From here I hope to define an if statement to determine which corner of the box ptF is located and then determine the corresponding location for ptC.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="leeminardi_0-1662056614796.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1110777i7D62E29166211C6E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="leeminardi_0-1662056614796.png" alt="leeminardi_0-1662056614796.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The math for this was a challenge for me and I learned a lot (quats are not my friends).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Sep 2022 18:28:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11395971#M1239</guid>
      <dc:creator>leeminardi</dc:creator>
      <dc:date>2022-09-01T18:28:01Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11396208#M1240</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/822616"&gt;@leeminardi&lt;/a&gt;&amp;nbsp;thanks a lot, I need to go through each step to understand everything . Let me get back as soon as I have other ideas. Really really nice progress.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Sep 2022 20:15:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11396208#M1240</guid>
      <dc:creator>giuseppetonello</dc:creator>
      <dc:date>2022-09-01T20:15:55Z</dc:date>
    </item>
    <item>
      <title>Re: Dummy lifting one side of a solid object</title>
      <link>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11406300#M1241</link>
      <description>&lt;P&gt;I've cleaned up the rigging scripts a bit and experimented with enabling the choice of which corner to lift. The code has also been modified to assume that the box's pivot is located at the center of the bottom face.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Moving point ptF lifts a corner of the box and drags the opposing corner on the XY plane.&amp;nbsp; The Z coordinate of DummyMode determines which of 2 corners ptF will affect.&amp;nbsp; &amp;nbsp;If the z coordinate of dummyMode is greater than or equal to 1 then one corner is used. If less than 1 then the other corner is used.&amp;nbsp; I have not implemented the ability to select any of the four corners.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Point ptC, the location of the box corner that lies on the plane, has the following position script:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;s = (boxWidth^2 + boxLength^2)^0.5  -- box bottom side diagonal length
g = ptF + [boxWidth, (boxLength),0]  -- initial guess for location
g = [g.x, g.y,0] -- initial guess  -- move to XY plane
for i = 1 to 10 do  -- make 10 succesive guesses for the location
-- by numerically finding the intersection of a circle and line
(
  -- revise the guess at a distance s from ptF
  g = ptF + normalize(g - ptF) * s  
  -- project g to XY plane
  g = [g.x, g.y,0]
  i = i + 1
)
g&lt;/LI-CODE&gt;&lt;P&gt;After an initial guess is made for where ptC should be located, ten successive guesses are made&amp;nbsp; to determine the intersection of a line and circle (of radius s centered at ptF).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The transform script for the box is:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;-- assumes pivot of box is at the center of the bottom side. 
if (dumMode &amp;gt;= 1) then a = 1. else a = -1.
s = ( boxWidth^2 + boxLength^2)^0.5  -- box side diagonal length
alpha = a * atan( boxLength/boxwidth)  -- angle of diagonal with side
vx =  normalize(ptC - ptF)  -- unit vector in direction of F to C
vy = normalize(cross [0,0,1] vx)  -- unit vector parallel to XY plane and perpendiculat to vx
vz = normalize(cross vx vy)       -- unit vector perpendicular to vx and vy
m = (matrix3 vx vy vz ptF)
translate m -ptF  -- move matrix to origin to do rotation
rotate m (quat alpha vz) -- rotate matrix about box z axis
translate m ptF  -- move matrix back
translate m (vx * s/2) -- move by half the diagonal distance
m&lt;/LI-CODE&gt;&lt;P&gt;The z coordinate of dummyMode is first checked to determine which box corner to use.&amp;nbsp; Using the position of a dummy was easy to implement but another technique could be used&amp;nbsp; &amp;nbsp;(e.g., a custom controller). Since the orientation of the box uses its diagonal, it is necessary to rotate the box about its z axis to set the final orientation.&amp;nbsp; Using a quaternion is the most effective way to rotate about an axis skewed in 3D.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The box will jump to a new position when dummyMode is moved above/below a z coordinate of 1. This is because a corner of the box is aligned with ptF and not vice versa.&amp;nbsp; &amp;nbsp;I was not sure what you required in the process of choosing a different corner to lift.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I realize that this is not the most straightforward rigging so please let me know if you have any questions.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="leeminardi_0-1662560232541.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1112712i010D8656A12EB17F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="leeminardi_0-1662560232541.png" alt="leeminardi_0-1662560232541.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 07 Sep 2022 14:21:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-animation-and-rigging/dummy-lifting-one-side-of-a-solid-object/m-p/11406300#M1241</guid>
      <dc:creator>leeminardi</dc:creator>
      <dc:date>2022-09-07T14:21:38Z</dc:date>
    </item>
  </channel>
</rss>

