Visual Novel Maker provides a powerful extension system which allows to develop new functions for the Editor or Game Engine and share them with others. To develop extensions, open the Extension Editor through View > Extension or click on the Extension Editor tab.

 

 

Extension Documents

On the left side you can see all so called "Extension Documents" of your project. You can freely organize your extension documents using folders. Whenever you save your project, all edited extension documents are compiled to an internal JavaScript Object and you get informed about syntax errors. If there is a syntax error, just fix it and save your project again.

 

The Script / Code Editor

On the right side you can see the Code Editor showing you the content of your current selected extension document.. Visual Novel Maker uses ACE Code Editor, see www.ace.c9.io for more information about ACE itself. You can use CTRL+,(COMMA) or CMD+,(Comma) to open ACE settings where you can change things like font size, etc.

 

Creating an Extension

If you are a developer and like to add new features to Visual Novel Maker you can use this guide as a starting point. If you need more help just check the Plugin API Reference and take a look into our forums.

 

To create an extension, just open the Extension Composer through the Menu under Tools > Developer Tools > Create Extension…

 

However, before you can create an extension you first need to develop it by making some changes to the editor or the game engine.

 

Modifying the Game Engine

To modify the game engine, just open the Script Editor through the menu under View > Script. Here you can see all game scripts which you can modify or even delete. If you want to extend a script/class it is recommended to create a new script instead of modifying a certain script directly. Otherwise collisions between extensions would happen.

 

Modifying the Game Editor

To modify the editor, just open the Extension Editor through the Menu under View > Extension.

 

In Extension Editor you can create/modify the following elements of the editor.

 

A Data Record View describes a category in the database. It contains the name, backend fields and the whole UI for a single category data record. You can see all existing categories like characters, etc. and can modify or even delete them. However, it is not recommended to delete "System " DataRecordView because that view must be always present for internal technical reasons.

 

A scene command describes a single command in scene view the user can use to define the logic of a scene. So you can add new commands here or even modify or delete existing ones.

 

A custom view is an independent view which can be used by other views or scene commands in many different ways. For example, a custom view can be used as a popup-dialog for a popup-control or can be embedded into another view as a partial-view.

 

A JavaScript file can be used by views or scene commands to define constants, calculating texts or other kind of logic at runtime or to compose JSON during design time.

 

An Objective-J File can be used to create custom UI controls, resource pipeline processors, more powerful script agents and other things where more control is needed. It is important that the file name matches the Objective-J class name.

 

A language bundle can be used to translate the UI of your views and scene commands into different languages.

 

Using JSON to Design a View

A view is defined using JSON. So no real programming is necessary except for calculating texts or other small logics at runtime. You just need to define the sections and UI controls and describe how they should handle the data and into which backend fields the data should be written.

 

A view is separated into sections and each section can have a border + title and a list of items to display. An item is a UI control to let the user interact with the view. There are many different types of items like text fields, check boxes, radio buttons, etc. You can find a detailed list in the Plugin API Reference.

 

Case Examples

Please check out the examples below to learn more about how to make your own extensions.

 

Example 1: Adding a new Database category

This tutorial teaches you how to add a new category to the editor’s database.

 

Example 2: Adding a new Scene command

Visual Novel Maker comes with a lot of useful built-in commands to easily create own visual novels. However, in special situations depending on the complexity of the visual novel the built-in commands are maybe not enough or it is necessary to modify them.

 

Example 3: Implementing a new command on script-side

In our last example we added a new scene command to the editor. However, if we use that scene command now it has no in-game effect because didn’t implement the logic for that command yet. To do that, we have to open the Script Editor under View > Script.

 

Example 4: Create a Language Bundle

In this example we will create a language bundle to translate our extension into another language.

 

Example 5: Create an Extension

Now we can finally create our card extension using Extension Composer and share it with other people.