Skip to content

Developer Quick Start

Arthur Pacaud edited this page Jun 12, 2020 · 2 revisions

Mod structure

A GDMod mod is basically a zip file. It contains three folder:

  • data:

    This folder contains json files used by the mod loader to understand how your mod should be imported. There are 3 files:
    • GDMod.json - Describes basic mod data (Unique ID, Name, Version, Dependencies etc)
    • includes.json - contains a single array of the code files to include and their order. This is very important as if you declare a namespace in one and fill it in another, the mod will break if the on that defines the namespace is defined after it got filled in.
    • resources.json - contains an array of resources with their loading parameters.
  • resources

    This folder contains all resources used by the mod - Images, Fonts, Audio, etc.
  • code

    This folder contains all your JS files.

Hello World

Let's create a Hello World mod. Clone this repository and copy the Hello World mod from the Template Mods folder to any place you want. Now open code/main.js, and in the mod definition, replace MyAwesomeMod.message with a string of your choice. Zip the 3 folders, and load the mod. Open the console and there you go! You made your first GDevelop Mod! Your message should get spammed in the console. Now if you open the debugger and replace the value of MyAwesomeMod.message with something else, it will get spammed instead.

Home

Player Documentation:

Developer Documentation:

Clone this wiki locally