samfred2 commited on
Commit
49ad6d5
·
verified ·
1 Parent(s): bc158da

[flow_default] Transcription: 001 Moving between levels.json

Browse files
transcriptions/001 Moving between levels.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "audio_file": "001 Moving between levels.wav",
3
+ "text": "Hi everyone, welcome to a brand new tutorial about levels. So today we're going to be learning how we can switch between different maps in Unreal Engine. And this is really useful whenever you're creating a game or you're creating a scene and you want to switch levels in between, so switch your own maps. And to do that, so let's first go to the third person default map that we have here. To do just go to your content drawer, you can press Ctrl Space, go to your third person blueprint, go to Maps, and it should be there, the third person example map. So I'm just going to open it up. It's the same map here. And here we have, this is the default level that comes with Unreal. Perfect. Once you're here, what we're going to do is we're going to go and press on our third person character, and we're going to go all the way to the top right here and click Edit Third Person. So here we're going to have our third person character blueprint. So it's going to open up on a new tab. You can always like dock the tab on top there. And you have your third person character right here. So you have their viewport, you have a construction script and an event graph. So what we're going to be looking over right now is the event graph. Here you can see all of the programming that has made to make this third person moveable and to actually react to inputs. So as you can see, you have the movement here, you can add input. Here's all the programming that goes in it. And we're going to be working on this event graph here. So what we're going to do is actually pretty simple. We're going to go to an empty space, you can be around here, and we're going to right click it, and we're going to search for level. And then you can, you're going to see that you have a lot of like level functions here, and we're looking for the open level by names, you're gonna click that. Perfect. Cool. And what this function does is just it takes in a level name, and opens a new level. Pretty simple. That's what we're trying to do here. So let's go back real quick to a third person example map, let's open our content browser and let's search for the map that we want the person to travel to. So I have, so if we, you have been creating your folders the same way as I've been, we have levels here and we also have our landscapes. So actually I'm working with landscape too. So I want my player to spawn on landscape tool whenever I take an action. So let's go back there and let's set the level name to level two simply by just typing in perfect. So we still have we still have to trigger this open level with an action. And the way I'm going to choose here is I'm just going to simply use the tab key on my keyboard to actually transition levels. In order to do that, just right click on the blueprint and let's search for the tab key tab. There you go. It's going to be under input under keyboard events. Just press it here. Perfect. Now, whenever we press the key, we want to open the level. So just drag it to this top one here, which is just saying it's a continuous flow on the programming, which means that it's going to execute this function right here. And that's it. That's how you actually open a new level. So let's go and compile, make sure it compiles perfectly get the green checkmark. Let's save to the third person example map. Actually, before we execute that, let's press Ctrl Space and let's go to our landscape to save selected. Let's go to this empty space right here. And let's drag the player start. So let's hit the top left. Let's hit create. And let's go all the way down to player start. So this just indicates that the player is going to start here whenever it spawns. So for you to drag it to the bottom and actually starts on the ground, you can just lift it up or just click on it and just press the and key. This is going to snap it to the ground. So if I hit play now, I should be spawned right here on the ground at this area that we put the player spawn. Perfect. So let's press ask. Let's save this level with control S and let's press control space and let's go back to our third person example map. Another easy way of doing that is going to content or wherever you want, yeah, going to content and adding a level feature, a level filter, as you can see, mine's already here. And then you can click on your third person example map super quickly. Perfect. Let's deselect the feature. And there we have it here. So let's try to press play. And now what I'm going to do is I'm going to press my tab key. And this should actually open the landscape to level and spawn me there. So let's see. Tap. Oh, we got an error. Of course we get an error. So what is going on? So to debug this, we're going to go to the third person character, and we're going to check. Oh, my level name is level two. That's not where I wanted to be spawned at. I want to be spawned at landscape to perfect. There you go. So it's a quick debugging. Let's compile again, save third person example. Let's save this again. Let's press play. And if I now press tab, it's going to go to my landscape too. Perfect. As you can see, I typed in level two as a mistake. So we actually got an error. So you can see what the error is like whenever you type something different there, you type a different level name. That's what it's going to happen. But as you can see, I press my tab key and I actually spawn in this world. And if I press my tab key again, it's actually going to bring me back to that spawn because that tab keys hooked on to the player's blueprint, which is shared between the maps. So it's always going to spawn me here because it's going to open this level and it's going to assign the player start to the third person. And that's how you do basic level triggering. On the next episode, we're going to see how to actually walk into a box and spawn a new level. It's super simple and I hope to see you there. Thank you.",
4
+ "language": "en",
5
+ "confidence": null,
6
+ "duration": 371.88
7
+ }