did you know that you could use JavaScript in gdevelop the no code open- Source game engine JavaScript is the most popular programming language in the world and while there are several different languages used inside the engine for various components we can actually use JavaScript to build our games so here I have a little game scene and what I want to do is make the ambulance object move to the right simple enough so I can go to the event sheet and you can see I've already got it set up using the no Code system it's just as easy as if at the beginning of scene then add to the ambulance a permanent force of 150 pixels per second along the x- axis and that will get us to move along to the right so if I preview the game you'll see the ambulance coming along and going down the road now for transparency here's the camera controls adjusting the camera's position at the beginning of scene and then changing the camera's rotation to look at the ambulance based on where the camera is but we're going to focus on this event here I'm going to remake this event using a JavaScript block so first I rightclick go to add and then add JavaScript code this will give me this block and in here I can type out JavaScript and do whatever I want so I will disable this event so it's not triggering anymore and just use the JavaScript to do the same thing firstly I can select the object to pass through as the argument of this JavaScript block and in this case it'll be the ambulance and then I can write out this line of code to make the ambulance move to the right where the object is having a force applied to it 150 in the X zero in the Y with one as the multiplier and then we can preview the game and get a black screen because the event is wrong so you can turn on your developer tool just like you would in a Chrome browser and you can see the errors piling up so let's exit that and I actually already have this written down in my handy little notepad so I can see what's wrong with the event by checking my notes and it looks like I forgot to include the s for objects but we also want to add the at the beginning of scene so we'll take this entire piece of code here and paste it in so if runtime get time manager is first frame so at the beginning of scene then apply the force to the object and we'll preview the game and there we go the object is moving to the right the exact same way that it was with the no code actions and conditions and that's because under the hood the no Code system is really just a cleaner and more natural way to present JavaScript code these no code events are being translated into JavaScript when the game runs this though is not actually the best way to use JavaScript with G develop the best place to use JavaScript is inside of extensions extensions can be found here in the project manager you can either create your own or use one of the hundreds of extensions already created for the engine in this case I've installed the GamePad extension so I can go here to the extension click to edit and open it up in the editor and you can see right away here's the JavaScript for the extension now you don't necessarily need to use JavaScript inside of extensions you can also use the actions and conditions already in the engine but for this extension the actions and conditions required to use a Gamepad controller just didn't exist and so JavaScript was needed to make this work but you can create new actions and conditions and use them along alongside the no code event system so now that this extension is installed I can go back to the event sheet and under conditions look up Gamepad and there's a series of conditions here that weren't there before so now I'm able to check inputs from the controller whether it's connected the type of controller the buttons that are pressed and so on so writing with JavaScript inside of an extension is a good way to keep all of your code for specific feature neatly packed away in one place and allowing you to continue using the cleaner and more naturally red no code event format writing your JavaScript code inside of an extension also allows you to transfer that from Project to project or share it with other developers if you would like some more learning resources for using JavaScript in G develop the links to those are in the description but if you're new to gdevelop and want to learn more then check out this [Music] video