4 Create .me Mods
Shiny edited this page 2025-04-11 22:15:29 +02:00
This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Create a .me Mod (For Developers Only)

What .ME Mods Support:

  • Prefabs
  • 3D Models
  • Shaders
  • Any built-in Unity components
  • All existing MateEngine SDK components (e.g. AvatarMenuController.cs)

Limitations on C# Scripts

.me mods do not support custom C# scripts attached to prefabs that are compiled outside of MateEngine.
This is due to a Unity engine limitation: AssetBundles cannot deserialize MonoBehaviours from external assemblies at runtime.

If you want to develop a mod with your own C# logic:

  • You must compile your code into a separate .dll assembly
  • And dynamically inject logic into the prefab after loading
  • The .me system does not currently support automatic injection of external MonoBehaviours

If You Need Script Support

If your mod depends on custom C# logic (e.g. new MonoBehaviour classes), you will need to:

  • Develop your own mod loader
  • Or use reflection-based systems to manually attach components after runtime .dll load

Creating a .me mod is easy! Just follow these steps:

  1. Clone the full MateEngine Git repository.
  2. Open Unity Hub, click "Open project", and select the MateEngine folder.
  3. Once the project loads, navigate to the folder MATE ENGINE - Scenes and open the scene named DEV.
    This scene always contains the latest Bleeding Edge components, updates, and features.

You will now see a normal Unity project view of MateEngine itself. Youre ready to start developing your mod!

Important: In the Hierarchy window, create a new folder where all your mod content will be stored.


Example Project Structure:

Mate Engine InDev
├── Settings
│   └── Content
├── Menu
│   └── Content
├── Model
│   └── Content
├── APIs
│   └── Content
├── WIPs
│   └── Content
├── Debugging
│   └── Content
├── Steam Exclusives
│   └── Content
├── YOUR_MOD_FOLDER
│   └── YOUR_MOD_CONTENT

Exporting Your Mod

  1. Once your mod is complete, go to the top menu bar in Unity.
  2. Click on "MateEngine" > "AssetBundle Exporter".
  3. Drag and drop your YOUR_MOD_FOLDER into the "Prefab or Scene Object" field.
  4. Assign a Bundle Name.
  5. Click "Export".

This will generate a .me file that contains all your shaders, objects, and scripts.


Testing Your Mod

To try out your mod:

  • Open MateEngine.
  • Click the "VRM" button.
  • Select your exported .me file.

Note: Currently, mods and models are loaded using the same button. This means the VRM model will be disabled when you load a mod. A proper external mod loader is planned for version 1.5.0.