You are on page 1of 18

LEVEL EDITOR TUTORIAL

TABLE OF CONTENTS
Introduction ..................................................................................................... 2 Checkpoints ..................................................................................................14 Secret Panels .................................................................................................14 Level Editor Basics .......................................................................................... 3 Creating a New Level ........................................................................... 3 The Context Menu: Main Menu and Object Menus ....................... 3 Setting up the Level ....................................................................................... 4 Collision Blocks ................................................................................................ 4 Start Point and Exit Point ............................................................................... 6 Moving Platforms ........................................................................................... 6 Toggle Switches.............................................................................................. 7 Lights, Security Cameras and Lasers .......................................................... 8 Pressure Switches ........................................................................................... 9 Lasers and Invisible Moving Platforms Revisited ..................................... 12 Robots, Portals and Containment Fields ................................................. 13 Objects Not Covered in the Tutorial .........................................................18 Trigger Areas ..........................................................................................18 Camera Triggers ....................................................................................18 NOT Gates ..............................................................................................18 AND Gates .............................................................................................18 Sunlight ....................................................................................................18 Tiling.................................................................................................................15 Background Tiles ...................................................................................15 Overlay Tiles ...........................................................................................17

Stealth Bastard: Level Editor Tutorial

Page 1

INTRODUCTION
Welcome to the Stealth Bastard Level Editor Tutorial! By now, youve probably played through a few levels of Stealth Bastard (but if you havent, you should go and do that right now!) and want to create some fiendish, addictive levels of your own. This tutorial will introduce you to all the editor features youll need to recreate a simple example level and hopefully start your creative juices flowing!

Level Overview

The above screenshot shows an overview of the completed tutorial level you may find it useful to refer back to this as you work.

Stealth Bastard: Level Editor Tutorial

Page 2

LEVEL EDITOR BASICS


Creating a New Level
Start by opening up the game and clicking Make Levels from the main menu.

The Context Menu: Main Menu and Object Menus


When you right-click somewhere on the screen in the level editor, a menu will appear. This menu is context-sensitive (meaning that it changes based on what you have selected), and takes two basic forms: the main menu and object menus. When you right-click in a blank space in the editor, youll bring up the main menu, which applies to the level as a whole. From here you can set the properties for the level, create new objects and access the save/load features of the editor. To set properties for individual objects, youll need to first select them with a left-click, then right-click over them to bring up their object menu.

Youll open up the Level Editor and be presented with a new, blank level. To keep your workspace clutter-free, all the game objects, tiles and menu options are contained in a context-sensitive menu, which you can bring up with a right-click.

Main Menu / Object Menu (for a Switch object)

Stealth Bastard: Level Editor Tutorial

Page 3

SETTING UP THE LEVEL


Well kick things off by setting the room width and height. The level we want to make will be 800px wide by 360px high, so right-click to bring up the main menu, then point to Set and click on Room Width. Type 800 in the dialog box that appears and hit Enter. Open up the global menu a second time, then go to Set Room Height and set the height to 360px.

COLLISION BLOCKS
The simplest object in the editor, and the one well create first, is the Collision Block. Collision Blocks are the black rectangles that make up the floor, walls and moving platforms in the game. Bring up the main menu and click on New Collision Block to create your first block.

Lets save our level before we go any further. From the main menu, go to File Save Level (or just press Ctrl + S) and the editor will request that you give your level a name. Lets call this level Tutorial (you can always change this name later via Set Level Name).

There are a few things worth noting here. Firstly, you might notice that the Help panel, in the top-right corner, has changed to reflect that you have an object selected. The keyboard shortcuts listed here will come in handy for manipulating your object! (If the Help panel gets in your way, you can hide it by pressing H on your keyboard.) Secondly, youll see that in addition to the Help panel, an Info panel has appeared. This Info panel summarises the various properties of your selected object useful as a quick reference. (You can hide the Info panel with I).

Stealth Bastard: Level Editor Tutorial

Page 4

Lastly, the Complexity meter up the top of the screen is no longer completely empty a little bar of orange has appeared within it. This meter gives an indication of how many objects you have in your level if the bar gets close to filling up, your level probably has too many objects in it (meaning your framerate or the framerate of other players using slow computers is likely to drop), so keep an eye on it. Yellow in the bar represents non-shadow-casting lights, orange represents collision blocks, red represents shadow-casting lights and cyan represents tiles.

Create the rest of the collision blocks as shown above, resizing them with the mouse wheel (note the shortcuts listed in the Help panel) or by rightclicking on them and selecting Set Width and Height. You may find it useful to switch the grid on, which you can do by pressing G, and you can also switch white outlines on by pressing O. Youll need to pan across your level to place all these blocks, which you can do by holding down the spacebar and click-and-dragging with the left mouse button, or just by click-and-dragging with the middle mouse button. Note that the gap between the 128 x 48 block and the 560 x 16 block is 3 grid squares wide (48px) this will be important later.

Make sure your first collision block is selected (it should be highlighted in red if it isnt, left-click on it to select it), then set its width by right-clicking on it and selecting Set Width. Type in 288 and hit enter. Similarly, set the height to 144 through Set Height. Click and drag your resized block into the lower left-hand corner of the level as shown in the picture below (note that it protrudes beyond the bottom of the level a little bit, but the top, left and right sides align with the grid).

Stealth Bastard: Level Editor Tutorial

Page 5

START POINT AND EXIT POINT


Create a start point for your level by bringing up the global menu, then selecting New Logic Object Start Point. Drag it into position as shown below. Here, Ive also set the light colour to blue, which you can do by opening the start points object menu and selecting Set Light Colour.

MOVING PLATFORMS
Lets create a moving platform for the player to ride down. Create a new 48 x 16 collision block in the area shown and choose Make Moving Platform from its object menu.

Youll see two yellow squares appear: these are the platforms nodes. Similarly, create the end point for the level through New Logic Object End Point and set the colour to blue.

IMPORTANT TIP: Note that this is the first time weve encountered an instance of multiple objects (the platform and its nodes) overlapping each other in the editor. If you find youre not selecting the object you intend when you try to click on it, you can hold down the Alt key on your keyboard to select through objects. The Alt key also has the effect of pausing moving platforms when pressed and held.

Stealth Bastard: Level Editor Tutorial

Page 6

If you click on the leftmost node youll see that the info panel lists its Position in Path as 1, indicating that this is the moving platforms 1st node, where the platform will start. (The right node has a Position in Path of 2, indicating that it is the 2nd node.) We want the platform to start where it is now, so well grab the right (second) node and drag it down to the bottom of the drop, making sure the platform has enough space to fit in this gap (remember that both the gap and the platform should be 48px wide go back to the Collision Blocks section and adjust your collision block placement if it doesnt fit). Pull the first node across a little to the right so the platforms path is a perfectly straight line, and you should see the platform moving smoothly up and down the path youve created.

TOGGLE SWITCHES
Next well set the platform up to respond to a switch. Right-click on the first (top) node and select Set Off. This means that when the platform reaches this node in its path, it will stop moving. Since this is the first node in the path, the platform will start motionless. Create a new switch via New Level Object Switch, and place it up near your start point. Switches, by default, start off as toggles meaning that they will turn ON objects that are currently off, and turn OFF objects that are currently on. In this case for making a platform that moves up and down in response to the switch this is exactly what we want. Right-click on your new switch and go to Link Object 1 to link it to the first node. Youll see a yellow link line appear, terminating in a yellow circle over the linked object. The 1 in the circle indicates that the node is now linked to the switchs Object 1 property. Then, go to Link Object 2 and link the switch to the second node.

At this point you may want to test your level out save it by pressing Ctrl + S (you should be doing this regularly!) and test the level by pressing F1. Your moving platform should start off at the top node, and move down to the bottom node on the first flip of the switch. The second flip of the switch should move it from the bottom node back to the first, and so on. Press F1 again to return to the editor.

Stealth Bastard: Level Editor Tutorial

Page 7

LIGHTS, SECURITY CAMERAS AND LASERS


Now well set up a security camera, and a light to make the player visible. Create a new camera (New Level Object Security Camera) and place it on the wall (refer to the overview screenshot for a broader view of where Ive positioned objects in the level). You can adjust the rotation through Set Rotation (or by pressing R on your keyboard), and the range through Set Range (or by using the mouse wheel). Here Ive set the range to 152.

The light used here is an area light (New Light Area Light), with a radius of 128 (Set Radius). Ive also made the light green through Set Colour. When placing lights in the editor, it can be useful to check how effective they are by right-clicking in an area and selecting Tools Check Player Visibility. We want to make sure the player cant sneak past this area unseen, so ensure that the player is FULLY visible when they pass below the light.

Security cameras on their own arent much of a threat to the player they need an object to trigger. Create a laser beam above the light (New Hazard Laser Beam), Set its Rotation to point straight down (270) and make it Start Off. Then right-click on the camera and choose Set Target Object to set its target object as the new laser beam. The camera will now trigger the laser if it sees the player.

Stealth Bastard: Level Editor Tutorial

Page 8

PRESSURE SWITCHES
If the area light we created before always remains on, the player will never be able to get past the camera without being killed by the laser. So, well set up a pressure switch to control the light. Create a pressure switch using New Level Object Pressure Switch, and Link its Object 1 as the light. Now, as long as something (the player, a moveable block or an enemy) is pressing the switch, the light will remain off. Ive also added a green decorative light (New Light Decorative Light) below the pressure switch to make it stand out, and to hint to the player that the switch affects the green area light. The easiest way to choose a style for your decorative light is to first select it, then browse through the different available styles using the scroll wheel.

MOVEABLE BLOCKS, DOORS AND ABSOLUTE SWITCHES


Unfortunately for the player, he wont be able to stand on the pressure switch and walk past the camera at the same time so lets help him out with a moveable block to hold the switch down. Create a New Level Object Moveable Block and a New Level Object Door, placing both above the pressure switch as shown below.

Set the door to Horizontal so the moveable block can sit neatly on top of it. (You should create some new collision blocks around the moveable block, too, to get your level to look like the overview screenshot these are to prevent the player from bypassing your moving platform.)

Stealth Bastard: Level Editor Tutorial

Page 9

Create a new Switch and Link its Object 1 as the door. We want an absolute switch here, rather than a toggle, so right-click on the switch and choose Change to Absolute Switch. Note that Set Target Objects to is set to on by default, which is what we want here doors are considered on when open and off when closed. Now, when the player uses the switch, the door will open and the moveable block will drop straight onto the pressure switch, turning off the light and allowing him to pass the security camera unseen.

PATROLLERS AND INVISIBLE MOVING PLATFORMS


Next were going to add a patroller enemy, starting by setting up a path for it to move along.

(remember to refer to the overview screenshot if youre not sure where to place things) In Stealth Bastard, every object that moves along a path is linked to an invisible moving platform so well set up one of those now. Create a new 16x16 collision block and change it to a Moving Platform. Add two more nodes to the path by selecting an existing node, then right-clicking on it and choosing Add Node to Path. Drag the nodes into a rectangular shape as illustrated in the screenshot below.

Stealth Bastard: Level Editor Tutorial

Page 10

By default, the moving platform will follow this path linearly and backtrack when it reaches the final node in the path. Since we want our patroller to follow his path in a continuous loop, right-click on the moving platform and select Set Looping. (Remember you can hold Alt to make the platform stay still if youre having trouble clicking on it.) We also dont want the platform itself to be visible, so go ahead and Set it to Invisible. Now we can create our patroller (New Enemy Patroller). Attach him to the moving platform (Link Moving Platform Position) and your patroller should be looping around the path!

TERMINALS AND MOVING PLATFORMS REVISITED


Just below this patroller enemy, were going to place our first terminal for the player to hack. Go to New Level Object Terminal and place some lights around it so the patroller has a chance of spotting the player. Here Ive used both an Area Light and a Spotlight (pointing up). I turned shadow casting off (Toggle Shadows) on the spotlight, since there are no collision blocks in its path to cast shadows (so the player will see no difference) and I want to keep my complexity bar as low as possible.

Terminals can do more than just open the level exit they can trigger objects, too. Create a Moving Platform as shown below (the top node needs to be the first one ensure that its Position in path is 1) and Set both nodes to Off. Then, from the terminals object menu, choose Set Target Object and select the first node. This means that when this terminal is hacked, the linked platform will move from the first node to the second (where it will stop).

Stealth Bastard: Level Editor Tutorial

Page 11

LASERS AND INVISIBLE MOVING PLATFORMS REVISITED


Now were going to create a laser attached to a moving platform similar to what we did for the patroller enemy but instead of moving the laser with the platform, we will simply have it point to the platform. Create a new Laser Beam and set up an Invisible Moving Platform as shown below, ensuring the node on the left is the first node (so the laser starts pointing straight down). Leave both nodes on, but set the platform itself to Start Off, and set the Pause Time on both nodes to 10 frames so that when the platform is turned on, the laser beam will pause briefly at each node. Next, set the laser to point in the direction of the invisible platform (Link Moving Platform Direction). Ive also added some pink decorative lights to indicate to the player where the laser will be pointing when it pauses. (This is an easy thing to check in the editor once the lasers direction is linked to the platform just click on a node and the laser will swing to point at it.)

INVISIBLE SWITCHES
In addition to triggering the moving platform, we want our terminal to start the laser beam swinging (so the player can slip past), but we have a problem: terminals can only have one target object! This is where invisible switches come into play since switches can be linked to up to four objects, we can use them to trigger multiple events in response to a single player action (such as hacking a terminal). You can even chain switches together for particularly complex designs. Create a new Switch, then Set it to Invisible. Link it to the object the terminal is currently linked to: the first node of the visible moving platform. Next, link it to the invisible moving platform guiding the laser (be careful to link to the invisible platform itself, and not to its nodes take note of the floating tooltip that appears when youre placing the link).

Then, change the terminals Target Object to this new invisible switch.

Stealth Bastard: Level Editor Tutorial

Page 12

ROBOTS, PORTALS AND CONTAINMENT FIELDS


At this stage of the level, our player has almost reached the exit point! Lets create a robot enemy for him to get past.

TIMERS AND BUZZSAWS


A buzzsaw will be the final obstacle for the player to pass before reaching the exit point. Create one using New Hazard Buzzsaw and Set its Radius to the smallest possible size (16). Create a new Invisible Moving Platform, with the top (first) node Off and the bottom (second) node On, and Set the platforms Speed to 2. Attach your saw to this platform via Link Moving Platform.

Insert a robot by going to New Enemy Robot. I started off by placing some 16x16 collision blocks for him to patrol between, and an Area Light to give him a chance to spot the player. Next well create some portals, which are available from New Level Object Portal. Set the Target Portal of the left-hand portal to the right-hand portal, so the robot will be teleported back to the right when he reaches the left portal. Close off the portals to the player by creating some New Level Object Containment Fields. These are similar to collision blocks, except that they only affect the player; the robot will be able to walk through them without a problem. We want to turn the first node on and off again at regular intervals, so well create a timer object via New Logic Object Timer. Set the timer to Repeating, and Set its Timer Period to 160 frames. Then, Link it to the first node of your moving platform. The buzzsaw should now bounce quickly between the nodes a few times (five times, if youve left a gap of one grid space between the nodes as I have), then pause at the top node for an interval. Place another terminal just below the second node for the player to quickly(!) hack during the buzzsaws pause interval.

Stealth Bastard: Level Editor Tutorial

Page 13

CHECKPOINTS
Weve filled our level with some fairly threatening obstacles, so it seems only fair to provide the player with a few checkpoints along the way (New Logic Object Checkpoint).You can resize checkpoints with the mouse wheel (like collision blocks), or through their object menus (Set Width and Set Height). Be careful when placing checkpoints try not to put them in dangerous areas, or the player may respawn at a point where death is unavoidable!

SECRET PANELS
To add a little mystery to our level as well as to make it less visually overwhelming when the player first loads it up lets put a New Logic Object Secret Panel over the robot section of the level.

Ive also Linked my invisible switch to the panel, so that when the first terminal is hacked, the panel will disappear, clearly indicating to the player where to go next in the level.

Stealth Bastard: Level Editor Tutorial

Page 14

TILING
The level itself is now complete! Once youve tested it a few times and feel happy that the gameplay is working solidly, you can get on to putting down some background tiles to make the level a bit more visually appealing. Switch to Tile Mode by pressing Tab. There are two tilesets available to you: background tiles, which you can use to create the levels backdrop, in various styles, and overlay tiles, which you can place more sparingly to add atmosphere in the form of pipes, wires, vents, blood splatters and more. Overlay tiles are designed to be layered on top of background tiles, so well look at those in a moment and start off by placing some background tiles.

Background Tiles
Once youre in Tile Mode, you can press and hold T, or the right mouse button, to bring up your currently selected tileset. (Background tiles should be selected by default; you can switch between the two tilesets by pressing A or Enter.) Select individual 16x16 tiles by left-clicking on them, or multiple tiles by leftclicking and dragging. You can then place these tiles on the background of your level by left-clicking.

Stealth Bastard: Level Editor Tutorial

Page 15

Youll probably also find it helpful to switch off some of your level layers while you tile (particularly the collision blocks). Press L to see the shortcuts for toggling various layers.

Left-click to place the corner tile.

Ive made some simple background panels by using the tiles shown below. (Refer to the overview screenshot to see an overview of the style Ive gone for.)

A finished panel should look something like this. Left-click and drag to place the top edge tiles.

Stealth Bastard: Level Editor Tutorial

Page 16

If you make a mistake, you can delete individual tiles from your level by hovering over them and pressing Delete on your keyboard. Similarly, you can move tiles by clicking and dragging them with the Ctrl key held down, and pick up / eyedrop tiles for duplication by clicking on them with the Shift key held down.

Overlay Tiles
After filling the level with background tiles, I then switched to the overlay tileset (switch by pressing A or Enter, or by scrolling the mouse wheel) and added a few overlays around the moving platforms to give the appearance of runners.

Once your tiling is done thats it! Youve completed the Stealth Bastard Level Editor Tutorial. Now that youre familiar with the tools in the editor, you can create some levels of your own design and upload them to the Stealth Bastard level repository via File Upload Level, so that others can play and rate them.

Stealth Bastard: Level Editor Tutorial

Page 17

OBJECTS NOT COVERED IN THE TUTORIAL


There are a few logic objects and one light object not included in this tutorial level that you may find useful in your own levels:

AND Gates

Trigger Areas
AND Gates are used to trigger a single target object when a number of conditions are fulfilled. For example, you might want to create a door that only opens after two separate switches have been triggered. To do this, you would need to create an AND Gate, set its Target Object to the door, then Link the two switches to the gate. Once both switches are pulled, the door will open.

Trigger Areas can trigger a target object when the player steps into them. Unlike Checkpoint Triggers, which are always One Shot (meaning they can only activate once: the first time the player steps into them), trigger areas can be Set to One Shot or Persistent (the latter meaning they will trigger their target object every time the player steps into them, not just the first time).

Camera Triggers

Sunlight

Camera Triggers are used to draw the players attention to areas by moving the camera. Like trigger areas, they can be Set to One Shot or Persistent, and will need to be given an X Offset and / or a Y Offset. When the player enters a camera trigger area, the camera will move to centre around the offset point youve specified for it.

Sunlight is a shadow-casting light that affects an entire level. If you place a sunlight object in your level, be warned that the game wont cull any offscreen collision blocks to aid framerate. This is because in levels with sunlight, collision objects can cast their shadows infinitely across the screen, and so turning them off when they are offscreen would potentially turn off their onscreen shadows. Best practice is to only use the Sunlight object in smaller levels, or to use collision objects sparingly in sunlit levels. Note: If you experience framerate drops in your sunlit levels, you can force a collision object to always be culled when offscreen by selecting OffscreenAlways Deactivate from its context menu. However, for the reasons described above, it is best to be cautious with this setting.

NOT Gates

NOT Gates reverse the signal of a switch, effectively changing an ON signal to an OFF signal and vice versa. For example, you might want an absolute switch to switch two laser beams OFF, but also to switch a third one ON. The simplest way to achieve this would be to Link the switch to the first two lasers and to a NOT Gate, then set the Target Object of the NOT Gate to the third laser.
Stealth Bastard: Level Editor Tutorial

Page 18

You might also like