Hey everyone!
I have a world with World Composition and origin rebasing enabled, and I would like to be able to teleport my player from one place to another within this world. I have created a PlayerStart-derived class which I can find and teleport to in the persistent level via my Gamemode, and so far everything is good.
The problem is that when I do teleport to this PlayerStart, the level that the PlayerStart is closest to (i.e, placed as if it were inside it, only it's in the persistent level) doesn't load before the player gets there and promptly falls through the world.
I've tried to solve it by creating a C++ function that disabled physics, checks if the player is on solid ground and then enables physics again. Unfortunately, neither disabling physics nor my ground checking is working. I either get an infinite loop, or nothing useful happens.
I have considered just assigning the level the start is "in", for lack of a better word, however, this is an open world game and as such it'll be a world tile and not like a series of rooms - I believe it'll get tedious to link a level to the playerstart every time I want to place one. I'm also not sure if I can do it if it's a world composition level. Is there a way to get the closest world comp level?
In PIE, UE obviously has some sort of solution for this already, since it is not an issue if I use the default player starts. However, I've been unable to find this anywhere.
Any help in solving this would be greatly appreciated!
I have a world with World Composition and origin rebasing enabled, and I would like to be able to teleport my player from one place to another within this world. I have created a PlayerStart-derived class which I can find and teleport to in the persistent level via my Gamemode, and so far everything is good.
The problem is that when I do teleport to this PlayerStart, the level that the PlayerStart is closest to (i.e, placed as if it were inside it, only it's in the persistent level) doesn't load before the player gets there and promptly falls through the world.
I've tried to solve it by creating a C++ function that disabled physics, checks if the player is on solid ground and then enables physics again. Unfortunately, neither disabling physics nor my ground checking is working. I either get an infinite loop, or nothing useful happens.
I have considered just assigning the level the start is "in", for lack of a better word, however, this is an open world game and as such it'll be a world tile and not like a series of rooms - I believe it'll get tedious to link a level to the playerstart every time I want to place one. I'm also not sure if I can do it if it's a world composition level. Is there a way to get the closest world comp level?
In PIE, UE obviously has some sort of solution for this already, since it is not an issue if I use the default player starts. However, I've been unable to find this anywhere.
Any help in solving this would be greatly appreciated!
Comment