 Welcome to our presentation Thanks for showing up to see what we've been up to with Minecraft and open shift and children What what could you start today when you were? So when I when I was young about 12 a friend of mine bought the computer an MSX computer like this one okay, and my first so that it booted up and it was basically Basic environment, so you you could type your own program in there and the first program I did was just a little print my name Right away, I was I was really caught by this I got a book in the library and started programming I got hooked That sounds very familiar that sounds very familiar. I had a almost identical experience on this environment here that some of you might remember What you're doing this environment here for those of you who remember very very similar right and those days It was different. There was no There's no I can here to double click on to get onto YouTube exactly no apps to tap it was really simple and That's a bit of a problem right now with kids if you want to learn how learn them to program and you say okay This little program can print your name on the screen. They're not really caught by that anymore That's a little boring right print hello world is not getting them anymore, right? I wonder if you have any idea what we could do about that Well, I will I my son went to this devox for kids once okay, and they had Minecraft there Oh, that's a cool game because playing that as well Yeah, because that's really cats that gets them because they they know this game and they played with it and and in devox for kids They show them how to extend this game So what he could do is build a little plug-in that could he could change arrows into cats All right to throw cats through the air. Exactly. That's cool. That's really cool But then we came back and I said okay, let's do this more because it was really cool I thought hey that that's cool. I would like to see how that how it's done And then he said yeah, I don't know how to because you have to install these things. I had this Eclipse workspace and all that stuff because my craft has a java API Right to set up everything you have to set up java. You have to set up an editor server The server the plug-in the workspace. I need to compile these things and copy these jar files And that's all a bit much I guess a little bit much for kids right compared to our print Our super environment here. It was just turn it on and go I wonder if we could somehow get back to have an experience like that What would we need for that you think we need something like a server running somewhere Yeah, that would be an easy way to set it up. That would be in one of the elements right some way to run This is in this case the game server, right to just sort of fire it up and get on it Luckily I've been working on Developer the developer experience and we have this project called the launch And it's basically you know show the website. It's basically A website where you can get going on Open shift real simple and easy, right? I like I like where this is going open shift like this runtime environment We can get free accounts to alter applications and run them on And perhaps we could just run our server there right let our kids connect to that The way we made it is that we have like supported runtimes here like swarm vertex and Node and spring boot. This all looks very serious. This is for work This is for work But it's made in a way that you can also extend it and add your own add your own examples to it Oh So while monday to friday at work, we can create new projects with wildfly Vertex and spring boot and in the weekend we could make micro servers for our kids That sounds cool. Can you show us show us so we have this server set up on our local open shift So we have a local local open shift running on this on this laptop. That's just because we didn't trust the wi-fi here Right, right. So next we have an open shift running locally So we can think about mini shift if you can use that right so here We can say just want to build and deploy and run on on this local machine local open machine cluster And then you can you can choose what you want to check this out Node jbos, snow vertex, but minecraft, sponge There's like a different kind of the apis where you can build stuff on a minecraft servers and sponge is one of them The best one, okay, that's why we have it here And you can choose here A simple plugin example, okay, that will show you how to do how to do How to do some extend minecraft extend minecraft and then do some basic things Okay, and then you you choose your a github account So it will create a github repo for you with this example code Okay, right And it sounds really handy to get started right and then when you press here set up application it will Create a github account add some webhooks So that when your code changes the server gets restarted and and and loaded with your new changes And it will Set this all up an open shift Wow, so you can sort of with one click set up application You can get started with an example have it running in the cloud let your friends connect to it Yeah, um, and this is pretty fast or Yeah, so, uh, we could it's just a couple of minutes, but we don't mean it's but like a good chef We here's one. I prepared earlier We're gonna save three minutes here of our 30 that we have with you Yeah, so Let's see. Oh, this is the this is the the github repo that it created And it has webhooks. So if I would go here, yeah, wait, hang on. Hang on. I lost you lost me here So what are we looking at here? This is this is the demo plugin set up. Okay. So here is an example of a Example code minecraft extension. So this is what a kid would Could be shown how to extend minecraft. Yeah, so and you could you could you could go and play now this Oh, I'd love to I'd love to go and play in this time for some fun. It's time for some. All right. All right. Let's try this So This is the server that's also booted up and run set up for you. So this one's on this laptop inside our OpenShift is already Local single node cluster that we have here in a in a container and Those of you who know minecraft. It's a standard minecraft world Walk around here And look at that. Well, what's happening here? That's the extension That's the plugin That's changed the change the behavior of minecraft and whenever you collide. So whenever you Jump it will print this boing in the boing in the chat. Yeah, great Okay, so and that's you're saying this is coming from here It's just coming here. Look at this. It's an event listener and it has a collide event handler and then When it finds the player and says boing, okay So what we do is again, so we have on github an example project how to extend minecraft, right? Which the open shift launcher created for us, right? And this is running because how did this actually get sort of So There's an s2i source to image kind of a thing All right, so it's just this thing. They have an open shift from source to containers Right. So it builds your builds this code and boots up a server running this running this plugin adding So all I have to do is change this. So if I'm Wanted to change this I could just go here go to edit And change boing into something else like right on github right on get up check it in and it will fire the web webhook and reboot my server with build the plugin and Start it up again. It'll do the Java compilation to build the plugin It will create a new container image with this s2i stuff It will stop the previous container to a Deployment that replaces the previous server and gets the new one on it. So can I just keep playing or how? You will be disconnected because server restarts. All right. The entire process is wiped killed um, I mean this is interesting and and sort of um to learn about open shift It's it's okay, but I have a 10 year old daughter and she's like way you gone back to youtube meanwhile Yeah, I'm afraid. I'm afraid you're right. It's not gonna fly. If only we had some way to hot reload code That would be nice so that we could actually change it live or something Yeah, then we could change it and then build something and then hot replace it. So there's a couple of things at least two Sites to this right you would need a way to change the code somewhere more direct because this whole Github committing a rebuilding so one to address that we could we could we have something like Eclipse chain Okay, which is that which is an IDE that runs in your browser So instead of installing Eclipse on your local machine We could run this also on our on our open shift instance and now Instead of having just a little bit of a fancy text editor Here I have now the same project see the same project the same code Oh, yeah, this is the same thing that was just up on github. Yeah, yeah, so instead of and instead of in github It's just in text editor. It's just next area. Yeah with some syntax highlighting. Okay, but here I have like co-completions Oh, this is a real editor So so that will help kids to find the right api to call and write things to do Hey, this Eclipse chain thing is pretty cool. And this runs on open shift And this runs on the same instance on our same Locally That's pretty cool So that's one of those problems and the other problem we have to solve is hot replacing this code If only someone built something on top of osgi Right because a minecraft being java based. And so if you want to hot code replace things in java There's a couple of options there that these java Jvm agents that you can use to replace code Yeah, the java debugger can do it. Yeah, that was nice. It has limitations. There's limitations. Yeah This osgi thing isn't used that much in the industry for for sort of production isn't applications You might not want to replace your running code in production. You know But in this case we totally want to do that in this case, this is what would be quite handy. Yeah. So so let's check so minecraft osgi Oh, you you did that actually did that last year. Yeah, I got this All right, what are your incidents? So you're saying hang on. So you're saying that from che In here you could make a change Yeah, I could make a chance. So let's let's do that. Let's say. Hey, uh, hello, uh death cough That'll be some that would be really cool Nobody does that I If I could die they've come for years, right? So, yeah, and then save it. Okay. So now we've changed the source code inside the che container in the development side I mean you just don't get it. So somehow we have to get it there. So there's a little maven plugin in this project already installed That will make a diff of your code. Okay, send that over over a web socket to the running Minecraft server, right? Wow got it. Wow. Okay. It will apply the diff. No, yeah Then it will compile the code Into an osgi bundle and hot replace this code. You don't say this actually works. This will work I'll show you It's a demo gods allow it, right? So I just run this maybe Maven build inside open shift on our development Inside a separate container, right? So we can just get our kids to extend and add some things in here just by going on this website Yes, nothing needs to be installed locally, right? So here's the plugin running now. Okay, and it will send the diff so the things I changed, okay, right and then it will fire off and build and Do osgi magic. Okay to get this code running. So right now. It takes takes a right now. It's still boing So without restarting of this minecraft server, we can keep playing here. We can sort of be in the world live Yeah And keep on keep on jumping and you think this message will change it will If not You can't Boing boing boing This is oh So now we have the node node gs experience right in java Without all of this over way restarting person. Yeah, we just reload. This is handy. This is handy. This is this case is going, right? Right, right, right. So I think this works really well if we go back over here This works really well if this makes some sense to you or you can sit together with your What would you say? I would say like he has to be like 12 12 13 14. Yeah, maybe even a little bit older depending on what they've done before Right because you have to know the apis. You have to know all these java constructs There's a little bit of still right all of these different apis classes here And then you have to know how to put the semicolon and braces and whatnot in the right places and all of the All the syntax stuff follows becomes red like this and Yeah, that's I mean, it's cool, right? It's cool. It's really cool, but I'm just wondering if we could do better for the batch before Sort of eight nine 10 12 year olds. Maybe we could do better. This is the home of MIT. You're right. We're in Boston Right, so they have this scratch developed here. Anybody here does not know scratch Raise your hand if you don't know scratch everybody knows scratch, right? Everybody knows scratch Okay, scratch is a visual development environment for children up on scratch at MIT.edu very well known. It's been around for 12 13 something like this years Oh, right. Yeah, it's available on the raspberry pi. It's very widely very widely used And the cool thing with this is it's visual development. So instead of writing this code that we have over here And the point here isn't really the java code. I mean, if this was fighting code, it would be the same thing The point is that for younger children to just be able to assemble blocks. It's a really much easier experience. I can do that at an age of two Do something with blocks, but here yeah with eight they could they could get this I think a minimum may be reading recognizing the blocks and you can get them started Yeah, right So hang on what we're saying here is that would be interesting to be able to mod minecraft With scratch with scratch instead of job So how would that work because we are in a we're in a container over here in open shift And okay, we have to do with GI stuff. Yeah, but we would we would have to have some sort of uh, so we can extend it with javascript So the scratch can be extended with javascript. It's it's built in flash But you can extend it with javascript. That's the current version. It's built in flash, right There's a new version coming up scratch free which is completely written in javascript Pure javascript. Yeah, because then and then you can also do it on your ipad or in mobile. Okay, and and uh flash is So that would let us get some additional blocks in here, right? That will get some additional blocks. So if we would have something that would be javascript and java That would be really cool. So yeah, because the problem we still have is that we're running Even if we had custom blocks like if you had a custom block to maybe I don't know show something in here or something like that We still need to bridge from what we're running in the browser to back in the back end where the micro servers are So something that allows us maybe a sort of a distributed message plus or something go from the Plowser back into the something reactive something like vertex vertex. Why are you good about that? Vertex is this um other red hat thing. We're just talking about lots of these red hats things here We get we eat our own dark food. Yeah So that's a reactive um java framework that has um An event pass that you can also use from javascript, right because it's uh, yeah, it's a distributed so um Let's see We could actually we actually have something that was running right right. Let's show let's go there So, um, this is on another server. So I just need to quickly go out here It's also running locally on our own open shift instance actually should we we have the time maybe to jump into open shift Yeah, let's show show how how we set that up. We're good on time. Yeah So what we could maybe just show here is how on this local open shift instance here, which just timed me out Really secured set up right developer develop We have here like we have the the the launcher as showed earlier in a separate project Okay, so this is the container that runs this thing. Yeah, right Then mini j if the j instance we have shown that's a container actually several containers that runs this Online environment because every every like build you do here is in separate container. Okay. Yeah, and then we've got um Test 38, which is our microsoft server, right? That's the launcher created this project and set it up to do The osgi stuff. So let's have a look into this one just sort of drill in here a little bit So what it's showing us here is that we have an application minecraft server, right? um And that application is running for click on this Has a deployment it's the first deployment because we just set it up And we can check out the logs here, right? Okay, there's a logs of the running the running minecraft server if they come out It's demo where are you logs? Yeah It's loading logs. So this is the yeah, here we go. Oh, here we go So this is actually the the logs of the minecraft server inside the container that we can consult from the mine from the open shift console here you see the the The maybe this is when you made the change for my point. This is the maven build right right right when the hello The point blank became the hello dev comp. Yeah, okay, and um, what's over here? What is this too? So here it builds and they they create they create the image that runs Okay, so the point of going from here initially. Yeah going from our um, our source code here initially to Uh container It's done by the build that happens that happened here. Yeah over here. We have like a build Yeah, there's also you can show maybe also there's an image This is gone. Yeah, this is gone into the images the images. There's an image here that's To it. See is this like um docker hub? It's like Basically, it's like registry registry the image container image registry that's built into it. Okay. Okay, cool. Yeah Well With that we could look at our other project The story is one here very similar very similar project I'm going to use this opportunity as a plug to show where we actually have this running In case anybody wants to continue checking this out at home. We actually have what we're showing you here Um running on a public server on a public open shift instance So if you want to go to www.learn.study, you can actually see what we're about to show now the scratch integration um, and if you want to Run it at home or god forbid help us make it better You can go check out the sources here where everything we've done is linked Make it better or add some youtube videos. Yeah, every contribution is welcome And there are different ways to contribute to open source, right? It's not just code No, you don't have to code maybe improve the documentation or make the site better Get make a video that shows what you've done with this. Yeah, get your children to do it or get some issues like What else do you want? Right? Right? What we maybe forgot or yeah, or what doesn't work. Let's jump into this So how does this work? I have to um connect To oasis.learn.study. Yeah, that's the public one, but we also have it running locally. We're running locally as well Yeah, we don't want to trust the conference So we're going to use this instance here the mini shift one. Yeah, but you get the same thing when you connect to the public one here, right? Ah, it became dark while we were talking here dark alone. Yeah So these minecraft worlds have a weather cycle and a daytime cycle. Hey, who is this? That's uh, benny Oh, right. Benny our favorite favorite donkey Okay, so this is a standard minecraft server. Where's the boing boing? Let's go. Hey, it's not on this one. This one is a different one. This is the one where we have the scratch integration, right? Okay, so um, let's go back to this www.line.study. What are we saying here? Yes Start by typing slash make type slash make in the micro chat and you get a link to the scratch So you can do slash make Then you get a link click here to open scratch and make actions Do this do this And you see we can go in here So basically we're doing the same thing that What like what we did before okay, we're creating a plug-in or we're extending minecraft But not by code, but by uh by adding scratch blocks using this vertex event bus from client to to server So here we have like a normal, uh, uh, scratch GUI you can do stuff like Uh Have events and have control blocks So everything other than the more blocks is the standard scratch environment some children already familiar with right and we have the minecraft blocks Extra minecraft blocks on the more blocks. So what what do we have here? Maybe we can make this a little bigger? Is anyway to control plus We'll put this up a little bit. Yeah So the blocks that we have here there's one that says a title Does that work? So if we get this one here Put it in here and um, let's use a scratch uh Launch thing So when space keys press so this is the space key in scratch not in minecraft. Yeah, just stand the scratch. So if I press space here It's be fast. I get a welcome over there. You get my basically you get my first Because this is something that kids can get excited about right right and this is really easy You don't need to set up servers and what you just connect to this minecraft server type slash make and then use these blocks Right And then you're extending minecraft and you're extending minecraft. Do you think we can do more here? Yes, sure Yeah, go ahead. What what do we I think you should do something of our favorite donkey here I think that's a good idea. Let's let's um Try to do something creative more like storytelling not like slaying zombies and counting points. That's stupid, right? Yeah, that's stupid. Let's do something a bit nice with um For example, we have a what am I holding here? You're holding a carrot carrot Tell you what we'll make a custom command instead of pressing space in scratch. We'll build a custom command slash demo And we have this entity speak block here Why don't I try to make benny Say something. Yeah Say it's a free over here No, we can't do that. That's a demo too So if you look at benny and we do slash demo two How did that come? And and because we have um all of scratch available here, we could do more we go crazy Add some logic to this. Okay. Let's do some if else. What do we have in here? Oh, maybe do it even better do if else if then or if if then else if then else. Let's go crazy if else, okay This is a huge logic So um So we could make a story. I won't be like a fun story with the carrot and uh feed me feed feed the donkey kind of thing That'd be fun. Very fun. So why don't we say if The item that's held Yeah Is equal to the visual of this I don't know this is equal to An apple No, do a carrot donkeys love carrots. Donkeys eat carrots. Okay, so we'll do carrot And let's change the how they've come to say Is it is the donkey polite don't donkeys are always Please feed me a carrot No, this is this is when you have a carrot I I'm sure kids would have gotten this right when I'm totally confused here If it's a carrot if then else we say please feed me a carrot if we are holding a carrot so you say, yeah Thanks for that Like yummy So benny will say we can have different characters also So we can have a dialogue here like we could have benny and his friend and they could exchange Comments or something others We could hear thanks Thanks for the carrot Thanks for the carrots because he's he's A lot like that right So with this if we're here when we say slash demo two Please feed me a carrot that's because we're not holding the carrot and if we Use this minecraft thing here to take the carrot into our hand. Yeah And if we do demo two now You'll say, yeah, thanks for the carrot. Nice Cool, all right So now we could build Our kids could build a whole adventure in adventure inside minecraft With a goal in the end and it's just the beginning it gives you some puzzles to solve puzzles riddles real stories or something Yeah, to like find something if you hold that you can use the variables and scratch scratch is this data blocks This is basically variables where you could say if you've done this before you could set something to true Yeah, I'll just do that first complete the quest complete the quest or something right so the sky's the limit Yeah, yeah, we probably can't figure all the things that kids can yeah The kids can think of right so With that we're sort of almost up on time And half basically covered what we want to show you guys If you have any questions, we're happy to answer them and most importantly try this out You can join our server here www.learn.study and you wanted to show the Other and we have some more links. We even have this chat server here. Our kids told us that the gamers are all on discord We didn't know much about it, but If you want to be cool, you have to be on discord Discord channels over here that you can like join us and say hi And again the sources are linked down here Um, we also have got a link down here for more cool sites This has nothing much to do with minecraft But we're just using the opportunity of having you all here to showing you that the last link on www.learn.study is a link to this little site for educational youtube channels and Cardware things for robots and micro bits and all these things that some of you i'm guessing are familiar with And we have over over the last two years or so. I think we've collected some recommended links here that are Great for children. Yeah, and if you can think of think of some things that we forgot about on this page And you can make a couple requests for this one. So because of course this page is just uh Read me on markdown on github. It's linked down here. You can just click here and edit it send us pull requests for how you Other things that you might be aware of That are very useful. Yeah Yeah, that's it. That's pretty much it. Yeah, are there any questions? Thanks for your interest Just just pick out and we'll repeat it That's a great question That's a great question. So the question is Are these commands for everybody on the server? right And that's actually very much what we were working on like half an hour ago before the presentation. We look at it Currently, um, this project is in the browser and you can save it locally. So this save basically opens a File chooser and he puts a zip file on your local thing And we've just started chatting together how we're actually going to save the project that you have here Which is a jason file in in scratch and we're going to push it to the server So save the scripts together with the worlds because that's where they belong This goes very much together with what you've created in Minecraft, right? Yeah, this donkey and you have a First to just links technically things that are in the world. So I'm going to save these projects on the server We're not quite there having finished that yet, but we pretty much have a good so help us if you like for Right now it's for every user as long as you have this open So if you were to join the server right now, this would work for you But it's running in the browser So if we close this tab, it won't be active for you anymore Yeah, yeah And so something we wanted to do as a follow-up to when we have this push to the server when we have this Saved in on the server basically another actually So in scratch 3 the whole logic has kind of changed and then this is like a separate thing where you can parse the the scratch File and and save it also as a jason file. So it went when we can run it on the server so this whole parsing and Logic on the server and then we can save it easily. So the cunning plan is to move this to scratch 3 Which has the javascript based very modular architecture where they have a what do they call it the scratch? It's based on blocky. It's from block please for the front end. Blockly for google That's for for how it looks but that number plays this part Yeah, that will replace this book part and it's how it looks like the scratch vm That's basically the whole parsing running the running the scratch the scratch vm is the non-gooey The non-gooey part that we will then also run in node on the server right and then There's a gooey a separate gooey part that will do this and we'll change it a bit because here There's this preview window or there. There's this preview window there. That doesn't make that much sense We need that so we could change that that that does that goes and we have more space to Push the project to the server and then in scratch 3 use the scratch vm project and run it in some node container or something And have it constantly Thank you. Thank you so much Cool. Cool. Just go for it. Try it out and Thanks for interesting Yeah So this one here and this is easy to find just Yeah, that's right here. It is here A couple of things it's easy to find don't don't write down the url of this just go to um the Minecraft page learn.study and then down here you get to this from here Maybe a point users on our big page All right, any other questions otherwise I know we're between you and the break We're around you can talk to us afterwards as well. We'd love to see many of you on our discord server chat with you All right, thanks