Skip to content

Camera, selection and shortcuts ​

How to move around the editor's scene, pick things, arrange the panels, and find any command. Every key is in the shortcuts table at the bottom.

Move the camera ​

  1. Hold the right mouse button and move to look around. While it is held, W A S D fly and Q/E go down and up.
  2. Alt + left drag turns about where the view looks; Alt + right drag comes closer or goes back.
  3. The wheel zooms, out to 300 cells; past the game's own limit the mist and distance culling move back so you see the whole map.
  4. F frames what is selected (the whole map with nothing selected). Home resets the view.
  5. Numpad 7 looks straight down, Numpad 1 goes back to the usual slant, Numpad 5 switches perspective off (and on again).
  6. Click a face of the view cube (top right of the scene) to look from that side.

Settings › Editing › Camera speed makes the keys, the screen edges and turning half to twice as fast.

Save a view and jump back to it ​

  1. Frame the view you want.
  2. Press Ctrl+1 to Ctrl+9 to keep it on that number.
  3. Press 1 to 9 to go back to it.

View › Views kept on keys lists them. They are saved with the map, in its editor-only data.

Select things ​

  1. Pick the select tool (Q).
  2. Click a thing to select it; Shift+click adds or removes.
  3. Drag a box to select many. Trees and doodads join a box only when the tool bar says so.
  4. Alt+Shift+drag draws a lasso round what to select.
  5. Ctrl+A selects everything, Alt+I inverts the selection, Escape selects nothing.

A click picks the first thing drawn under the pointer, by its triangles: a tree by its crown, a house by its roof. Alt+click picks through a locked thing, or picks one part of a prefab instance.

Find things by owner, type or name ​

  1. Open the Hierarchy (left rail).
  2. Type in its search, for example owner:2 type:footman big.
  3. Click the button beside the field to select everything found.

Fields you can use are in the search fields table. uses:footman shows everything that names the footman type.

Keep a selection on a key ​

  1. Select the things.
  2. Press Ctrl+Alt+1 to Ctrl+Alt+9.
  3. Press Alt and the number to select them again.

Edit › Selections kept and the row under the Hierarchy's search list them; the pin there keeps the selection on the next free key.

Move, turn and resize ​

  1. Select what you want to change.
  2. Press W (move), E (turn) or R (resize), then drag the handles.
  3. Or use the keys: the arrows move a cell (Shift a quarter, Alt ten), [ and ] turn, - and = shrink and grow.
  4. Tick Snap on the tool bar to snap to the grid, angle and size steps; hold Ctrl (⌘ on a Mac) to do the opposite while dragging.
  5. Tick Along the object to give the handles a single object's own axes.

Doodads (scenery) get the full transform: an up arrow lifts them, the rings tip them forward and sideways, and the cubes size each axis. Units, camps and markers keep the flat handles. Settings › Editing sets the snap steps.

Line things up ​

  1. Select two or more things.
  2. Open Edit › Arrange (or the Inspector's Arrange part).
  3. Pick an operation: line up or spread along x or z, Spread on a line, Spread on a circle, Face toward a point you click (Shift: away), Face along a path, Snap to ground, Mirror, Flip in place or Randomise.

Each is one step to undo. See the arrange table for what each does.

Edit many things at once ​

  1. Select several things of one kind.
  2. The Inspector shows the fields they share, and mixed where they differ.
  3. Set a value: it applies to all of them, as one step.

To copy fields from one thing to others, select it and press Ctrl+Shift+C (Copy values), then select the others and press Ctrl+Shift+V (Paste values). Position, id, name and type are never copied. A dot beside a field means it differs from its default: click the dot to reset it.

Hide, lock, group and isolate ​

  1. Open the Hierarchy. It lists everything on the map by kind, and your groups.
  2. Click the eye on a row to hide it (not drawn, not picked), or the lock to lock it (drawn, not picked).
  3. Press Ctrl+G to group the selection; drag rows onto a group to add them. Groups nest one level.
  4. Press Shift+I to isolate the selection (hide everything else) until Escape.
  5. Press F2 to rename the focused row. A thing's name is what your rules find it by.

Sort, beside the search, lists things as placed, by name, by type or by owner. Hidden, locked and grouped state is saved with the map but never given to the game.

Find where something is used, and replace it ​

  1. Select the thing (a placed unit, a doodad, a region, a point, a path).
  2. The Inspector says Used by n: click it to select every use. A path is used by the units whose first orders follow it; a region by the mist, weather, cloud and picture zones over it and the detail levels that name it.
  3. To swap it, use Change type… (a unit), Replace the model… (a doodad) or Replace with… (a prefab instance). Each keeps place, owner, facing and name.

In the search of everything, type ? to list the uses of every type, model, prefab and marker.

Search everything ​

  1. Press Ctrl+K (⌘K), from anywhere, even while typing in a field.
  2. Type what you want: a command, a tool, a unit to put down, a thing on the map, a file, a setting ("fog" opens Look at Sky and mist), a key ("ctrl d").
  3. Start with > for commands only, @ for things on the map, # for files.

Ctrl+Shift+P opens the commands alone. Opened from inside a panel, that panel's commands come first.

Arrange the panels ​

  1. Click a rail icon to open its panel docked; click the pin in its corner to have it float over the scene instead.
  2. Drag a panel's tab to another side or into another panel's tabs, or drag a rail icon to another rail.
  3. Right-click a rail icon for more: float it, move it to the other side.
  4. Pick a layout in Window: Scene (the scene alone), Terrain, Objects (Hierarchy, Inspector and Content pinned), or one you saved.
  5. Press \ to hide every panel and back, Alt+Enter to fill the screen, Shift+M to hide the minimap.

The layout is kept for next time.

Open several maps as tabs ​

  1. Click the pin beside the map's name (or File › Pin this map as a tab).
  2. Open another map: the pinned one keeps its undo history and unsaved changes in its tab.
  3. Click a tab to switch back. Its pin closes it (you are asked first if it has unsaved changes).

File › Open Recent lists the last ten maps; Ctrl+Alt+O reopens the one before this.

Type a sum in a number field ​

Type = in any number field to start a sum: =10*3, = (64 - 8) / 2. Press Enter to work it out, Escape to cancel.

Change a key ​

  1. Press ? (or Help › Every key).
  2. Find the action by name or by its key.
  3. Press a new key to add it, or remove one. Clashes are shown.

Your keys are saved in the browser for every map and game.

Change the editor's settings ​

Open File › The editor's settings (Ctrl+,). You can set the theme (Dark, Light, Classic, Orange, or one of the game's), Size of the interface (80% to 140%), whether the Inspector opens when you select something, how many undo steps to keep (200), how often a draft is kept, snapping steps and camera speed. Graphics settings are on Metrics and debug views.

In code ​

ts
// the camera
editor.framing.topView() // straight down; topView(false) for the slant
editor.framing.orthoView(true)
editor.framing.lookFrom('south')
editor.framing.keepView(1)
editor.framing.goToView(1)

// the selection
editor.selection.selectWhere('owner:2 type:footman')
editor.selection.invert()
editor.selection.keepSet({ name: 'Front line', key: 3 })
editor.nudgeSelection({ x: 1, z: 0 }, { run: false })

// arranging
editor.spreadAlong('circle')
editor.faceToward(point, false)
editor.mirrorSelection()

// the Hierarchy
editor.hideTargets(targets)
editor.groupSelection()
editor.isolateSelection()

// the dock
editor.dock.open('inspector')
editor.dock.move('look', 'left')
editor.dock.layouts.use('objects')

Every key is an action in one table (EDITOR_ACTIONS), on editor.keys. Add your own on the editor scene, or in code:

ts
export const editorActions: GameActions<EditorClient> = {
	// asked before the editor's own
	add: [{ id: 'td.road.look', label: 'Look at where the road starts', group: 'The tower defense', default: ['Shift+KeyR'], run: (editor) => lookAtRoad(editor) }],
	// leave out some of the editor's, or change them
	hide: ['sandbox'],
	change: { frame: { default: ['KeyJ'] } }
}

editor.keys.define({ id: 'mine', label: 'Mine', group: 'Mine', default: ['F6'], run: (editor) => mine(editor) }, { before: 'undo' })
editor.keys.bind('frame', ['KeyJ']) // the user's own keys, kept
editor.keys.press('save') // run it as its key would
editor.keys.key('save') // 'Ctrl + S', as a menu shows it

A menu line that names an action ({ id: 'td.road', action: 'td.road.look' }) shows its name and current key. KeysList of @v12-engine/client/app, given editor.keys, draws the list of every key in a panel of your own.

Reference ​

Keyboard shortcuts ​

Keys are places on the keyboard (KeyZ is the key right of the left Shift on QWERTY). Ctrl is ⌘ on a Mac. The editor's keys work wherever the focus is in the editor, except while typing in a field.

KeyWhat it does
The map
Ctrl+Z / Ctrl+Y, Ctrl+Shift+ZUndo / redo
Ctrl+SSave the map
Ctrl+EnterSave the map and play it
Ctrl+OOpen a map
Alt+NNew map (Ctrl+N is the browser's)
Ctrl+Alt+OOpen the map before this one
Ctrl+Shift+SExport the map (while playing: save a test point)
Ctrl+Shift+OImport a map
Ctrl+IImport files
Ctrl+,The editor's settings
Ctrl+PPlay here, or stop
Ctrl+Shift+PThe commands (while playing: pause)
Ctrl+Alt+PStep the game played here by a tick
Ctrl+Shift+EEdit the map while it plays, and back
The view
Right dragLook around (W A S D, Q, E fly while held)
Alt+left drag / Alt+right dragTurn about the view / come closer
Arrows (nothing selected)Scroll the view
Alt+Q / Alt+ETurn the camera
FLook at what is selected
Shift+ZLook closely, and back
HomeReset the view
Numpad 7 / 1 / 5Straight down / usual slant / no perspective
1–9, Ctrl+1–9Go to a kept view / keep the view
What is selected
Ctrl+A, Alt+I, EscapeSelect all, invert, select nothing
Alt+Shift+dragLasso
Alt+1–9, Ctrl+Alt+1–9Select a kept selection / keep the selection
Arrows (Shift, Alt)Move a cell (a quarter, ten)
[ / ]Turn left / right (also the point picked, and what is put down)
- / =Smaller / bigger
Ctrl+C, Ctrl+X, Ctrl+VCopy, cut, paste (between maps too)
Ctrl+DA copy to the side
Ctrl+Shift+C / Ctrl+Shift+VCopy values / paste values
Delete, BackspaceDelete
Ctrl+GGroup
Shift+IIsolate, or show everything again
F2Rename
Tools
Q W E RSelect / move / turn / resize handles
H, C, V, T, BHeight, cliffs, water, things, paint brushes (again: the next of the family)
G, P, L, MRegions, point, path, measure
ILight tool; with a brush, the eyedropper (also Ctrl+click)
XEffect tool
[ / ], Alt+wheelBrush smaller / bigger
; / ', Alt+Shift+wheelBrush weaker / stronger
Shift (while stroking)The opposite: lower for raise, cliff down for cliff up
R (placing a prefab)Turn it a quarter
What is shown
Ctrl+KSearch everything
Ctrl+SpaceContent drawer
\Hide every panel, and back
Alt+EnterFull screen
Shift+MMinimap
Shift+P, B, K, LOverlays: walkable, buildable, slow ground, cliff levels
Shift+Y, J, G, T, VOverlays: cell layers, grass styles, grid, triangles, detail
Shift+U, HOverlays: grass state, hiding patches
Shift+F, C, NOverlays: footprints, camps' notice, names
?Every key
F1The docs of the panel the keyboard is in
Panels (keyboard in the panel)
Ctrl+F or /The panel's search
F8 / Shift+F8Data panel: next / previous problem
Space, I, O, L, K, MCinematic panel: play, in, out, loop, key the camera, marker
Space, P, I, O, M, DeleteAnimation panel: play, gizmo, loop in, loop out, mark, remove keys
← → , Home, End, 0Animation panel: step a frame, ends, fit

The cheats' keys (Alt+Shift and a letter, while playing) are on Play here.

Hierarchy search fields ​

FieldExampleMatches
ownerowner:2A player by id or name (no spaces), neutral, creeps
typetype:footmanA unit type by id or name: objects of it, camps with it
kindkind:regionA row of the Hierarchy: building, doodad, a game's kind
tagtag:rangedThe type's tags (ranged, melee, hitsAir, the game's)
namename:gateWords in its name
usesuses:footmanWhat names a type, model, prefab, region or name

Words with no field match what the row says.

Arrange operations ​

OperationWhat it doesIn code
Spread on a lineEvenly between the two farthest aparteditor.spreadAlong('line')
Spread on a circleRound their average middleeditor.spreadAlong('circle')
Face towardToward a point you click (Shift: away)editor.faceToward(point, away)
Face along a pathThe way the nearest stretch of a path goeseditor.faceAlong(pathId)
Snap to groundLifted doodads back downeditor.snapToGround()
MirrorCopies where the map's symmetry mirrors themeditor.mirrorSelection()
Flip in placeEach moved to its mirror place, the whole kept centrededitor.flipSelection()
RandomiseA random turn and a size within the Place panel's rangeeditor.randomiseSelection({ turn, size })

On a MapEditor without a screen these are batch.faceToward, faceAlong, spreadAlong, snapToGround, mirrorSelection, flipInPlace and randomise(ids, range, random).

More in code ​

WhatAPI
Kept viewseditor.framing.keepView(n), goToView(n), keptViews(), forgetViews(n?)
Selectioneditor.selection.where(query), selectWhere, invert, keepSet, selectSet, keptSets, forgetSet
Hide, lock, groupeditor.hideTargets, lockTargets, isHidden, isLocked, groupSelection, groupTargets, addToGroup, ungroup
Copy valueseditor.clipboard.copyValues(), pasteValues(text?); editor.resetSelectionField(field)
Referenceseditor.find(ref), editor.showReferences(ref), editor.replaceWith(ref, to, where)
Tabs and recent mapseditor.tabs.pin(), switchTo(index), list; editor.recent.list(), openPrevious()
The searcheditor.shellState.openPalette(query)
Settingseditor.setPrefs({ theme, minimap, minimapCorner, viewCube }); EditorPrefs
Undo toasteditor.toast(text, { undo: true })
Number sumsevaluateNumber of the kit (no eval)

The history keeps about 64 MB of the map (editor.historyBytes); past that, the oldest steps go first.