Wednesday, September 18, 2019

Rube Goldberg project in Unity with only 3D objects

This is my first time using Unity and it was an interesting experience! In this assignment, we had to use 3D objects to create a Rube Goldberg like event. At first, I wanted to create a swinging cup that held the starting ball, but I had major issues trying to get the hinge to work and even though I created an empty object in which to place the swing the objects inside did not act as one whole unit. As you can see from this blooper video.



So I scrapped that idea for the finished project!

For the final version, I used a sphere with a mass set to 3 that dropped down from the sky, which landed and rolled onto 2 ramps which I added a physics material of friction dynamic of .1 to really get the ball rolling ;)  The subsequent platforms did not have this physics material added. That sphere would then collide with a grouping of cube shapes set into a row that would start the domino effect. With these cubes, I also increased the mass to 3 so when the final domino fell onto the next seesaw stage it would create a nice lift in the flying object. 

The seesaw was created using a cylinder that I place with all the axis points frozen. For the long cube that I used as the seesaw itself, I froze it on the X-axis and gave it a mass of .75.  For the pink cube that would be flung I altered both the mass and the angular drag to .05 as I wanted to see it get some nice height once triggered. 

Originally I wanted to use 2 more cylinders one as the object that would be flung from the seesaw and as the final end platform. When I created the 2 objects as flat coin-like shapes I would see them collide together as if they were spherical objects with the sphere existing where the rotate tool area showed. So for both objects, I opted to use more cubes. With pink cube and the final platform, I created a friction physics material so they would collide together and the pink cube would immediately stop in place. For a bit of fun, I added a metallic asset with checkmarks to the final platform.

All 3D objects have ridgebodies attached except for the platform because when I originally did add them I found that when the scene was played the objects would all sink into each other.
 

1 comment: