split trigger volume and use more triggers
How can I use one trigger volume and split it in to two, To use both sites of the trigger.
If i have a doorway and a camera on each sides of the doorway and I want to trigger the camera depending on with way I enter the trigger.
I can do this with two triggers but I don't want too. Can I use just one trigger for this. and how?
So to control this with a single trigger is going add a bit more logic to your blueprint, versus simply adding another trigger and having that control a specific camera as well. In your case, you are going to want to establish the two cameras within your scene to switch between, placed on either side of your door.
You will then want to introduce a /\/ FlipFlop so that upon Overlapping the Trigger volume, you switch to one camera, and upon the second overlap event, you switch to the second camera. Use the images below as an example on how to do this through the level blueprint.
Switching Between Cameras using Single Trigger Volume
I have also added the ability to return to the active player character controlled camera, when you end the overlap event.
Return to Player Camera
There is a small hitch with this logic, using a single trigger volume restricts your ability to enter the door from both sides out of order, unless you added additional logic. In other words, If I enter the door starting from the inside of the room, instead of the outside, the camera switch will be reversed. This can be avoided by simply adding another trigger tied solely to a single camera. This way, no matter which direction you approach, it will switch to that given camera.
Scene Set Up
Here is how I have my scene set-up, and as you can see I am approaching from outside of the room first, every time. Let me know if you have further questions or need additional assistance.
answered Dec 16 '15 at 07:43 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here