Go to content

Main menu:

Creating the Level - Components of a Level Editor

Last Updated: March 20th, 2016
A level editor, at its most fundamental level, can be viewed as the integration of three engine mechanics: creating a level, saving a created level, and loading a saved level. This tutorial series is broken down into three sections with each section describing one of the engine mechanics listed above. Each section will describe the concept, goal, and several ways of achieving the section’s mechanic in Multimedia Fusion 2 and Clickteam Fusion.

Concept for Creating the Level Objects
Before you can load a level into a level editor, you need to save a level and before you can save a level, you need to create and design a level! This segment of the tutorial itself breaks down into three subsections; creating objects, moving objects, and changing variables of objects. This section of the tutorial covers a handful of different ways you can create objects for a level editor. 

You cannot create objects out of thin air during runtime. As such, all of these methods require the objects to exist during editime.

Method 1 - Using the Multimedia Fusion 2 and Clickteam Fusion Frame Editor
This method forgoes the idea of building extra level editor mechanics and takes advantage of the Multimedia Fusion 2 and Clickteam Fusion Frame Editor. The Frame Editor allows you to design and develop levels during edittime; meaning you can create as many objects as needed and customize these objects to suit your needs. As such, you use the MMFusion Frame Editor to create all the objects that might be used in the level editor. If you have a tool that already works, why spend time and effort building a clone of the tool?
Method 2 - Creating Objects Based on Variables and User Actions
If you are not using method 1, you will most likely use this method (method 2) to create objects in a level editor. This method involves building a system that creates objects at runtime based on variables and user actions (which shall be defined as any action the user explicitly initiates such as keypresses and mouse clicks). For now, let’s take a look at using just user actions to create objects.
By using user actions to create objects, you could effectively respond to actions initiated by the user. For example, suppose your level editor had three objects; Square, Triangle, and Circle. You may have it such that each object is created from a different user action, as listed below:
  • Square objects are created when the user presses “Spacebar”
  • Triangle objects are created when the user presses “Enter”
  • Circle objects are created when the user left-clicks
As it is now, this can cause problems with large number of objects. If the creation of an object depended only on a user action, you might find yourself quickly running out of user actions. If you had 200 objects, you would need 200 different user actions! We can resolve this problem by using user actions in tandem with variables; meaning we can extend the number of objects we can create from one user action by adding variables to our conditions. Check out the "Example" tab or to read an example of what we mean.
The real power in this method comes in how you let the user change these variables. You can make a quick and simple dropdown box, or you can build an interface that the user interacts with. Be creative as you want!

For clear examples of this method, check out the “Downloads” tab, located at the top of this page.
Rate This Tutorial
Vote: 3.8/5
If you have read this tutorial, rate it from poor (1) to average (3) to great (5)!
Back to content | Back to main menu