 Hello, my name is Diego Lissarazzo from the OpenShift online team and in this video We're going to use OpenShift to host your Construct2 video game. So this game basically assumes that you already checked some of the videos that I created on how to create your first video game I have several of those that I created too in particular for this series and also that you have installed All the tools in your Windows machine to work with OpenShift If you haven't done those things I recommend you to check the links that I'm going to put on the description of the video and please Follow the steps that I'm mentioning there. Now let's host our game We're going to go to OpenShift.com to start this process Quite likely if you follow the previous video You already have an account if not, this is the moment to sign up for free for your OpenShift online account And after that, well, we're going to be logged in and if not, just go here to OpenShift web console We sign in and we're going to be logged into the dashboard that we see here And we're going to be able to see the applications that we have already created So here you see that I have already two games that I have hosted in OpenShift And at some point I'm going to create a couple of videos just to show you what I did But at the moment, let's just create a new one now since we used Construct2 to Create our first game and If you go and check the tutorials and check a little bit the documentation that you have with Construct2 Let's say features I think Well, you can see it over here These games are going to be HTML5 and JavaScript So the first thing that you're going to notice when you are in OpenShift online is that you have several instant apps several templates that you can just use to start well creating your app really easy and The first thing that came to mind the first experiment that I did to today's was We need something with JavaScript So I say like okay mean JavaScript. That's something that could work. I also look for Node.js really those were much more complicated than what I expected for this example and Afterwards, I figure out that the best way to do so was to just go for a PHP template So in this case, I am just going to pick the latest one PHP 5.4 Then obviously is going to ask you for a name for your project You see that the URL that is going to be picked is going to include the Domain that you picked for all your projects So this is something that you can change in any given time But you're always going to have a our hcloud.com so redhead cloud and whatever name you are going to have here So let's say that this one is I'm going to just call it Falcon since that's one of the assets that we use for our Constructive game So if you are not using the template If you are just going to Bring code from a git repository you also could do you could also pick something here But in this case, we are not going to do that We're going to just use everything that we have on our Machine so that's it No scaling. Yeah, let's just create obviously depending on your location. You could just pick one or Just say that you don't have any preference. Let's create application This could take a couple of minutes while everything is set up running and I am going to jump just to that part After a couple of minutes, we're going to get a pinch like this, but it's basically telling us that the entire project was created and Also is going to give us this information these Instructions on how to use to get to work with our project So one of the first things that we will have to do is to plan our project That is going to create a folder in our computer that will have all the code and we're going to modify that to well put our own game and Then we're going to Also have the git instructions that you are going to need to commit and push your changes So if you are familiar with git, this is not going to be really much of a surprise for you But let's try to work with this and see how that goes so let's copy this and We're going to use The common prompt here on Windows going to paste and then We're going to try to Clone the folder that we are going to need here So it's going to ask me do you want to continue to connect say yes And it's telling me that is done and right after that is telling me like hey You just have to say CD Falcon. I'm going to copy basically just like that and And We see that we have some directories and that we have an index PHP. This is basically What if we are going to modify to get our game there and Now we have to actually export our game. So let's do that For our next step, we have to open our construct to project the one that we work in some of the previous videos that you have in my account and We're going to export this project and create an HTML 5 JavaScript game If you are not using construct to you if you were using something like Unity on real GameMaker cuckoos 2d.js and well almost any other Java script or modern gaming platform You're going to have similar steps quite likely. I'm going to create a few videos Covering some of these other engines and you're going to see that most of the steps are exactly the same So I am not going to repeat some of the videos like how to install your How to install all the tools in your Windows machine but this part in particular is Going to be useful for anyone that is just creating new games and is using construct to So if you don't remember this Basically with construct to we create the small game that we have to tap on different enemies to try to protect our Centennial Eagle or Centennial Falcon in this case. Obviously, this is for educational purposes. That's why I am Using this small game. So nothing really complicated and That's pretty much it So this is what we're able to test on our computer using browser But now we really want to export this so the option is simply just go here to file Export project and then you pick the option for HTML5 website You see that there are many other ones, but this is the one that we need So let's say next Let's create a New folder here that we're going to call Falcon Export or whatever you want at this moment say next Normal style this is in case that you want to add some sort of like advertisement in your game But since we're just creating our first game just go for export It's going to take perhaps one two minutes This case is telling me that I don't have set up Java correctly to do the minify of the JavaScript and Well, that's fine. This particular case is just more an example. So let's open the destination folder and This is what we're going to have and you see that everything starts with an index HTML, right? So this is where your game is going to start This particular case if you try to open this In a normal browser, it's not really going to run quite likely your operating system is going to stop it from running and Like a local network for security reasons But you still can use a preview that you have with Construct 2 that is over here and you have this kind of like the same result Now we're going to have basically two different folders the export that we just did with Construct 2 or let's suppose that you did something similar with a Unity Unity 3d and also You're going to have the folder that we just created that should be called Falcon So we have it here So this is where the third trick goes and you're going to see that it's incredibly Incredibly simple a little bit of a hack, but it works perfectly So we're just going to copy all the files that we have here in the folder That we need that we created for OpenShift, right? Now we have a little bit of a problem. This is where the hack comes I guess that you could set it up manually, but I'm assuming that you have no previous experience with OpenShift and This is going to be great because the only thing that we will have to do is make certain that the code that is in our index That is index HTML is In our index PHP that is the one that the project is really looking for So let's open this let's say with Well, so open with Adam Could use basically notepad if you want you just need some sort of editor where you can modify the code So that's the first one and let's open the next one also with Adam. So we're just going to do a Dirty copy paste from one to the other. So we have the HTML here. We're going to control C Control a over here control V and then we have all the code that we needed from our Construct two game here. So let's save it Certain that that's the case and that's pretty much it now Everything that we had in this file now is copied here on our index PHP But obviously all the changes that we just did are not Set in Our open shift online account right now if we visit that it's not really going to show us our game So what do we have to do? So right now here you have basically the next steps that you that you need to do So we already did this we already enter our folder now. We just do this Obviously, we still need the prompt and we still have to be in the folder that we are going to modify But if we're right here, we just can do paste. We're going to add every change Then I am just going to do a comment. So look, I'm just copy pasting. I'm not even like doing anything Incredibly original you can change Name or put any comments that you want here to this comment that we are going to do with git in this case Well, let's let's make it a little bit more interesting So, I don't know My Construct to game, okay And of course, I think Okay, that work you see sometimes copy pasting is not great and The last thing that we're going to need is not we just did the comment now we need to push all these changes and paste and Then everything for your little application Should Automatically get ready and you see it's remote waiting for it to stop finish It's going to take one two minutes at most. It's done. So that should be pretty much it and now Well, I don't have it here But I'm going to just open in a new tap So we're going to see the overview of our application This is something that could have done at any given time and really what I want is the URL to check my Application so this is the name that you gave in a couple of steps away and Let's say that I'm going to open it. Let's see how that works And now we have our little game running on up and shift And of course well is here If you're running this in a Touch screen enabled device you're going to literally touch the screen instead of just clicking like how I'm doing right now and You should be able to play your little game and share it with everyone else So what do you do if you're going to make more changes on your project? so you go back to construct 2 or again some other engines and Then you're going to Modify, let's say the assets or you're going to change. I don't know the game over You don't want it to be red anymore. You just want it to be blue or whatever Afterwards, you just export your game. You're going to end up with a folder similar to what we had here So you end up adding images. You could try to modify the code manually, but in the case of construct 2, I don't recommend it and afterwards you just like Overwrite what you have in your open shift project that is Set up with gate and everything is already ready and you only have to repeat the last three The last three steps that we did that is the gate add commit and push and With that you should be able to Get your game running on open shifted. We see it here in this particular case my falcon project So I am going to leave this project there. You can check it is quite simple Perhaps I am going to modify a few things. I am going to start adding I don't know like a splash screen like menu or a couple more things But at the moment since the project was created to help the people that are going to work and the global game jam this weekend I think this is pretty much it. This is something that you can do in let's say half an hour and Now you have a space where you can share your game with anyone around the world Regardless if it's on the game jam or not and afterwards you can start sharing with this with all your family and friends At this point you should be able to create Different video games at least with construct 2 and to host them using open shift We would love to hear some feedback from you and see if you create any cool projects during this weekend. Let us know and game on