File: editing.html

package info (click to toggle)
sauerbraten-data 0.0.20100728+repack-1
  • links: PTS, VCS
  • area: non-free
  • in suites: wheezy
  • size: 525,044 kB
  • sloc: sh: 21; makefile: 2
file content (164 lines) | stat: -rw-r--r-- 8,380 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
<title>Cube 2: Sauerbraten - Map Editing</title>
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="shortcut icon" href="favicon.ico" />
</head>
<body>

<h1>Cube 2: Sauerbraten - Map Editing</h1>

<div class="contents">
<ul class="contents">
<li>
<a href="#editing_in_cube2"><b>Editing In Cube 2</b></a>
</li>
<li>
<a href="#the_basics"><b>The Basics</b></a>
</li>
<li>
<a href="#entities"><b>Entities</b></a>
</li>
<li>
<a href="#lighting"><b>Lighting</b></a>
</li>
<li>
<a href="#materials"><b>Materials</b></a>
</li>
<li>
<a href="#cheat_sheet"><b>Cheat Sheet</b></a>
</li>
</ul>
</div>

<h2 id="editing_in_cube2">Editing In Cube 2</h2>

<p>
Editing isn't like editing in any other game/engine; it is done within the program itself, and the
structure of the map is comprised of octrees. Octree may sound confusing but it's actually a pretty simple idea.
Imagine a cube you can do two things to: push the corners at any angle inwards, or split the cube into 8 smaller cubes
(4 cubes in the top half, 4 cubes in the bottom half) which you can do the same things to. That's all there is to it!
Below is an example cube where it is split and one cube is removed, and then again for a smaller cube.
</p>

<p>
<img src="dev/editing1.jpg" alt="Editing Example 1" />
<img src="dev/editing2.jpg" alt="Editing Example 2" />
<img src="dev/editing3.jpg" alt="Editing Example 2" />
</p> 	 
	 
<p>
With that out of the way: fire up the game and press E. This is edit mode. The first thing you'll notice is a faded
outline of the face of the cube pointed to by your cross hair. If you click on this face it will be selected, and will
be outlined by a solid outline. You can click and drag to select multiple faces of cubes. Press space to deselect all cubes.
When you have cubes selected, all editing commands will go to those cubes, otherwise it will go to the cube face you are pointing at.
Also notice the blue sparklies in the map. These are entities. They control things such as ammo, player spawns, lights, etc.
In the bottom left above your health you'll find text stating what the closest entity is and what properties it has.
The effect properties have depend upon the type of entity.
</p>

<p>
<img src="dev/editing4.jpg" alt="Editing Example 4" />
</p>

<h2 id="the_basics">The Basics</h2>

<p>
Go into edit mode (E) and press ` to open a console (pressing T then / has the same effect) and run the command <i>/newmap 7</i>.
This command creates a blank map, where smaller numbers create smaller maps and larger numbers create larger maps.
Editing commands are performed on the cube you selected by clicking and dragging, or the face you are pointing at if none are selected.
Press space to deselect. Point at the ground near you and roll the mouse wheel towards you. This creates a new cube towards you.
New cubes can only be created by "pulling them out of" adjacent cubes. So if you want a cube floating in the middle of the air,
you're going to need some temporary cubes going from the ground or a wall to there. Pushing the mouse wheel forward deletes the cube. 
Either by selecting faces or just pointing at them try to create a structure 3 high and 3 to the right like an upside down L. 
Now try holding G and move the mouse wheel towards you once. The selection size is now one step smaller. Any space you alter
at this grid size will be made up of smaller cubes, which will take more time to render but allow finer detail. The finest
grid size is much smaller than this, and the max size much much larger. Try adding a smaller L coming out of your bigger one for practice.
</p>

<p>
Now, let's edit those corners. To select corners press and hold Middle Mouse Button, much the same as selecting with the Left Mouse Button.
Try playing with the mouse wheel. This will push or pull the selected corners. Now make a selction with Left Mouse Button. Hold F and scroll 
with mouse. This edits all 4 corners at once. These operations may seem simple but they allow for the creation of complex geometry.
</p>

<p>
By now you should have an idea of how most editing operations work. Hold a modifier button and use the scroll wheel to change the
selected cubes or the one you're pointing at. It naturally follows that changing the texture of a face of a cube is as simple as holding
Y while using the scroll wheel. Not that there is no way to shift, scale, or rotate textures. While it may feel restrictive it greatly
speeds up the process of mapping and the running of the game. Another useful command is rotate, which is done with R and the scroll
wheel. Experiment with these operations to get a feel for them and then save your creation with the command <i>/savemap mmapname</i>
where mapname is some name of your choosing. This will create a file in packages/base named mapname.ogz. Save your work often!
Backups of old saves will be made for you with a .BAK extension. You can later open your map with the command <i>/map mapname</i>.
</p>

<h2 id="entities">Entities</h2>

<p>
Entities all have a blue particles sparkling to indicate their position. Some entities such as ammo boxes and armor will also show
their standard in-game model, but these will only be rendered if the entites have existed since the map was loaded. Monsters will only
render in single player mode. Make sure you're familiar with the different <a href="editref.html#entitytypes">types on entities</a>.
To add an entity select it from the editing section of the built in menu or type <i>/newent entname arg1 arg2 arg3 arg4</i> such as
<i>/newent light 32 120 120 120</i>. The location of the entity will be exactly where you are, except dropped straight down if it's
not a light. This behavior can be changed through the entdrop variable, but the default is best in most cases. You can delete an
entity with the delent command, which is bound to backspace.
</p>

<p>
For a DM: Place some "playerstart" entities, suggested quite a few of them, i.e. from 5 or so in a really small map up to
15 in really big ones. Place some ammo... remember to not just place excessive amounts: ammo spawns VERY quickly (4 to 8 seconds
depending on player load), and not having endless ammo forces the player to move around the map more and use different weapons, rather
than just using the one she is most effective with all the time. Normal health items... suggested from 3 or 4 for a really small map
to 8 or more in really big ones. The items "boost", "yellow armour", "greenarmour" and "quaddamage" all suggested 1 item, or maybe
multiple green armours or boosts in bigger maps. Add some teleports sparingly, only if they really make sense for connectivity and gameplay.
</p>

<h2 id="lighting">Lighting</h2>

<p>
See the <a href="editref.html#lighting">lighting commands</a> for an indepth list of all lighting related commands.
</p>

<h2 id="materials">Materials</h2>

<p>
There are various materials available such as water, lava & clip etc.  To create a material make a selection then in the console type 
<i>/water</i>. The area of your selection will have the material applied to it.
</p>

<p>
<b>Hint:</b> You do not have to type the full command you can just type the name of the material.  For example <i>/water</i> rather then <i>/editmat water</i>.
</p>

<p>
See <a href="editref.html#editmat">available materials</a>.
</p>

<h2 id="cheat_sheet">Cheat Sheet</h2>

<ul>
<li>Mouse Left Button: Select Faces</li>
<li>Mouse Middle Button: Select Corners</li>
<li>Mouse Right Button: Extend selection; Reorient section direction (requires initial selection)</li>
<li>Mouse Wheel: Pull cubes into existence and push them out of existence</li>
<li>Spacebar: Deselect</li>
<li>F+Mouse Wheel: Push and pull all 4 corners at once (in the case of no corner selection)</li>
<li>R+Mouse Wheel: Rotate relative to the white box</li>
<li>Y+Mouse Wheel: Quick texture change</li>
<li>G+Mouse Wheel: change grid size</li>
<li>U: undo one step</li>
<li>X: Mirror relative to the side of the white box</li>
<li>F2: Texture menu</li>
<li>Keypad Enter: Selection entities within selection</li>
<li><i>/savemap mapname</i> to save your map</li>
</ul>

</body>
</html>