Friday, March 19, 2021

No country for Old Men Sprint #5

 For this Sprint I was working a lot with troubleshooting physics going into the ground.  Recently we updated the collisions so many of our props began to break into our scene with the new update.  The asset I worked on the most was the phone.  I iterated this asset about 5 times and came up with a solution for the cord physics.  Originally the phone was all one geometry and this caused multiple issues in the physics editor.  

Gif of Broken Phone Chord Physics When Dropped

The geometry would go into the ground and when interacting with different objects the physics would break and freak out.  Often times it would freak out infinitely and I had to close the physics editor in order to stop the simulation.  To solve this issue I had to break apart the rig and separate the geometry into pieces.  I did this in Maya and then exported just the cord geometry and the cord skeleton. We already had the phone base and ear piece separated and in engine.  To organize it apart from two previous iterations I created a new folder and kept anything that has to do with the cord physics in that folder.  

Separate Ear Piece Geometry

Separate Phone Base Geometry

For the cord physics I used the skeletal structure and created a capsule on each joint which is for the collision and then a constraint which is what keeps the joints moving based one what another joint is doing.  Having the ear piece and the phone base disconnected from the cord has made a major difference in how the cord interacts with the world.  The cord is simulating and is not based on calculations from the ear piece and the base.  To connect those two pieces to the cord physics I need to add a physics constraint on both ends of the cord and line up the geometry.  Unlike the previous versions, the ear piece and the phone base do not have a skeleton in them so they will just be a static mesh.  Currently the ear piece and the phone base are checked out and disconnected because were one of the assets that was effected by the update we did.  For more information on Physics Constraints this is some documentation for Unreal Engine: Unreal Engine Physics Constraint Documentation  

Phone Chord Physics Constraint

This is the cord in the physics editor with it's capsules and the constraints.

Phone Chord Physics Hierarchy

This is what the hierarchy looks like in the physics editor. 

Before bringing it into our level this asset has been tested several times in our dummy level.  You can see the difference on how it's reacting to the ground or when interacting with another object in the scene.  I really wanted to think about how the player is going to react in the situation.  Some players will interact with it and may throw it so having the cord react to the environment in a more expected way was a big feat.  It is a lot bouncier then I thought it would be!

Gif of Phone Chord Physics When Dropped

So besides testing it out in our dummy file this asset has been tested with our other tech artist to see how it will react when it is picked up.  In the past this asset would disappear out of the scene if you tried to pick it up or it would disappear if you brought it into the scene.  Currently it interacts with the scene as expected however it will not allow the user to pick it up.  If the user interacts with it, it will just lay where it was dropped or placed.  We do have a blueprint that should be taking care of the user pick up situation, however both the other tech artist and I are at a slight lost as to why it won't let the user pick it up and interact with it.  

Blueprint For Phone Chord Pick Up  

The other asset I have begun to work on is the shot gun rig.  This asset is very early as this one was just recently given to me to work on.  I've never worked on a gun rig before, this rig will really be the first prop-rig I've worked on besides the phone.  The phone has a very different pipeline then the gun rig will have.  Since I've never seen what a gun rig looks like I took some time to see what they look like.  

Gun Rig References

After seeing what rigs look like for guns and having the modeler bring me through where it's suppose to move I set up a maya file and exported the shot-gun proxy from UE4 and placed it in my special folder for my prop exports and created my project folder for this asset. When I first brought it into maya I was surprised to see what it looked like as it came in as a block but then I figured out how to get the shot-gun to appear. 

Shotgun Geometry when Brought into Maya from Unreal Engine 4

Fixed Shotgun Geometry in Maya

Friday, March 5, 2021

No Country for Old Men Sprint #4

 For this sprint I worked a lot with the phone in the scene.  As I have never worked with physics before in UE4 most of the time I am doing research to try and figure out how physics works in UE4.  I have never even opened this window in UE4 before. The hardest part to get correct on the phone is the cord as when it interacts with the world, it tends to get a bit crazy and go all over the place.  I have actually iterated the physics for this asset three times as it is difficult to determine how it is acting in the VR.  I test this asset out on a basic level just to see how it interacts with the ground and get an idea for the weight and to see how the cord is reacting between the phone and the base.  

Gif of  Phone Chord Reacting to Being Dropped 

This is how the phone is acting currently.  I put a cylinder in the scene to see how the cord is reacting when the phone and the base are going in different directions.  Typically to have any idea as to how it is working on the VR end, the other tech artist on the team will let me know during common art class.  This current set up includes bones, constraints and containers and from there it's a lot of working with the settings and seeing how the phone is effected. 

Phone Chord Hierarchy

  This is part of the hierarchy to get the phone working currently.  I actually created the joint hierarchy in Maya and brought it over to UE4.

Phone Chord Physics Test in Physics Editor

This is one of the tests I did to try and understand how the physics is working.  In one of my other iterations the geometry does not go into the ground but after I added the constraints it seemed to be able to go into the ground again.  If you select the joint you can see it moving all over the place. 

Phone Chord in Physics Editor

This is what the colliders looked like when they didn't go into the ground and I'm thinking of bringing this back and seeing a difference between the two and which one gives a better solution. 

Phone Pick Up Blueprint

As this asset is going into the VR I did create some blueprints to allow it to be picked up.  This needs to be tested again to my knowledge as when he tried to pick up the phone it was running away and was completely out of the scene room.  We found this problem to be because of the collisions on the floor and walls of the room. 

Broken Phone Physics in Physics Editor

While working within the physics interface for the first time, this is one of the problems I came across.  Physics can be finicky and tends to break easily.  I found this to be fun but I also had no idea what caused the problem to occur.  This is the phone rotating around and catching speed but also never ending going around the environment like this.

Crazy Joint Movement in Physics Editor

 This was another problem I came across where the joints began to grow and also move around a lot and never end.  This one was caused when I adjusted one of the constrains.  Originally I turned on and off simulation to see if it would reset but it actually made it worse. 

Zenko Rig Reel

Zenko Rig Reel Zenko was my capstone character that I rigged and animated for Zenko: A Fox's Tale.  He is built to have a very reactive ...