Joel Sherman Assignment 5
- by jwsherma
- March 21
- in
I had a lot of trouble with this scene. My original plan was to take my scene from Assignment 4 and make a couple of the objects interactive. This was incredibly difficult. Theoretically, when I entered the collider for a sphere in the ground, a robot was supposed to approach a soldier, causing the soldier to run away. The soldier’s action would be triggered by the robot entering its collider. When I exited the cube collider, the robot would return to its original position.
In practice, when the robot entered the soldier’s collider, nothing would happen. I couldn’t figure out what was going on. I had a collider attached to the soldier. The robot and the soldier were both prefabricated assets I downloaded from the Unity Store, so I figured maybe the collider wouldn’t work on those. I put in a cube beneath the soldier that would trigger the soldier to move once the robot came up to it.
Once again, nothing happened.
I then thought that maybe the number of assets in the scene (of which there were many) was causing problems with Playmaker. I created a new scene with only the robot and a couple of soldiers. The same problems kept happening.
When I put a collider on a cube beneath the soldier, only I could trigger it; the robot couldn’t. Colliders could only be triggered by the player. It turned out that I didn’t have the logic right. Theoretically, there’s a way to structure the sequence of events in Playmaker so all of the events would happen. I ended restructuring the logic so that more than two objects would be affected by the trigger. It’s not an ideal sequence, as you’ll see below, but it gets the job done.
COMMENTS