Sprint Review 4 - 11/20/2024
What I mainly did this sprint is work on the flashlight and lantern on an and the pickup for the other objects. It was interesting to do it because I have never done something like this before where I am turning on and off the light attached to the object but, I am also grabbing the object's emissive if we decide to use that as another way to show light. The script was also in a way that we didn't need to use either emissive or the light if we didn't want one of them.
I also added the same pickup and drop to other objects. I did end up needing to make two different scripts for it as if I tried using the one used on the lights for the other objects it would break the game because the other objects did not have a light source attached to them so when you would pick it up the code would freak out. The easiest way that I found to get around it was to have a second script that did not have the light on it and put that on all other objects.
Every object needed the same thing in order to be picked up and dropped. They all needed to be a child to an empty game object and the empty needed the script while the child would have a rigid body, a collider with trigger on, and they needed a second child object with a sphere or capsule collider for the text UI.



Comments
Post a Comment