Making a 2D Paper Tile Map loop

Alright, so I figured it out.

I did a Blueprint of class ‘‘Paper Tile Map Actor’’. In this Blueprint, I added 2 tilemaps (A and B). Each map has 2 colliders (A1, A2 for map A, and B1 and B2 for map B). You must have a minimum of 2 tilemaps for this to work. If you only have 1, just split your tilemap in 2. You can make this work with more than 2, but it’s going to be more complicated.

The way it works is, before reaching the edge of each map (before your character would fall of the ledge), you have a collider. As soon as your character collides with it, it will detect where the second map is located, and if it is on the opposite side, it will relocate it to the area where your character is headed. Feel free to place your colliders closer to the center of your tile map, so you don’t see the edge of your tilemap before colliding. As long as they stay in the same order, you are going to be fine.

The only issue I have right now is, when a tilemap gets relocated, there is a big lag spike. If anyone knows how to fix this, please let me know.

I’m a new user, so I can’t put all my screenshots in one post. I will try to make different ones to post all the required screenshots.