Teleports using channels

Hello,

So I want to create teleporter relays. Both 1-way and 2-way. How I want it to be set up is when placing down the blueprint component and I can input a channel number. The teleporters with the same channel numbers will connect with eachother.

I also want to have the teleporter show the other side. I think that can work with a SceneCapture2D but again, I don’t know how to make it work with channels.

Any ideas?

My solution is that you should build a blueprint that include a camera, a SceneCapture2D, a plane/ mesh to display captured scene, and a trigger volume. Also a variable to hold the channel number. So when you player get near one of your teleporter, their skeletal mesh will overlap with the trigger volume. Then either you let user enter the channel number, or you use the current channel number to search for the first instance that hold the same channel number. Save that instance down to a local variable for ease of reference, then you get that instance SceneCapture2D, active it and set it to send data to a Render Target Texture (remember to set it’s solution first), then create some material from that texture, then assign that material to your display plane/ mesh, The other function is simple, just get the instance world location, add in some offset when your player want to teleport. And when your player teleport to other side, just repeat the above actions, but this time from the newly teleported side.

Note: you can create Render Target Texture and the material before hand and then assign it as above. Remember to turn off SceneCapture2D when you don’t really need them because those component take a lot of resource and decrease your fps a lot.

Or you use the current channel number
to search for the first instance that
hold the same channel number. Save
that instance down to a local variable
for ease of reference,

This is where I get stuck. How to reference an instance of the same blueprint component allong with checking if that instance has the same channel number as the current instance? And is it possible to have a trigger within the blueprint?

Sorry but I am totally lost

Use Get all actor of class, then select the class of the teleporter, for each instance of that class, check for the channel number and the instance itself, if channel number equal AND it is not the same teleporter with the current one, then stop the looping and set instance to a variable.

And yes, you can have a trigger within a blueprint, for detail how to set up a trigger volume inside a blueprint and other neccessary events, check this one out, : A new, community-hosted Unreal Engine Wiki - Announcements - Unreal Engine Forums

Thanks! But I’m running into trouble with the “Get all actor of class” node. It outputs an array, how can I filter the current instance and the instance with the same channel?

I also need to get the scenecapture2D from the other instance with the same channel to be shown at one side.