I am doing a basic teleport system. The ideal case is that when the pawn overlaps with one of the portals, it would re-appear in the location of the other one.
I am using a Pawn blueprint derived from DefaultPawn. The issue is that when the pawn goes into either portal, it gets teleported to the other one but it is then launched into the air (a.k.a gains an immense amount of velocity). happens even if the destination location is any arbitrary location.
I tried different scenarios trying to isolate the problem. I noticed that the Pawn would teleport fine to any arbitrary location if I triggered it to teleport out of the OnComponentBeginOverlap execution.
I have been playing with the physics settings of all the objects involved and nothing seems to be solving my issue.
Any thoughts you may have on would be greatly appreciated.
So I managed to temporarily fix issue by using a different approach:
Teleportation is now handled by the Pawn instead of the portal. When OnComponentBeginOverlap is hit, I set a flag of the Pawn that would execute the teleportation code in the next tick. It is a workaround but works as intended.
My guess is that there is some sort of code or setting in the default pawn that is causing problem. I tried creating a new pawn and it worked perfectly with the blueprint I posted before. I may add a screenshot of the solution in a near future.