Help fixing my teleportation

So im making this portal system which detects what side the portal is facing to decide which way the offset will be set to and detects the portals positions, The issue is after the first teleport or 2 it randomly makes you disappear and i cant seem to fix it. The portal testing room is found level called “Testing Room” controls are AWSD and E to interact and R and F to use the portal gun. I need someone to help find and eliminated the issue, because IVE SEARCHED FOR HOURS AND IM GOING INSANE.


I don’t see any issues, perhaps this is a bug?

reboot pc/reopen the site

Did that been there, Something happens after Swapping around portals between the floor and wall areas and then on second teleport just Poof your gone