Zh/Saving and Compiling: Difference between revisions

From Valve Developer Community
< Zh
Jump to navigation Jump to search
No edit summary
 
No edit summary
Line 1: Line 1:
{{first room menu:zh-cn}}
{{first room menu:zh-cn}}


The final stage of making a level is saving and compiling it. A map must be compiled to run it in the [[Source|Source Engine]].
制作关卡的最后一个步骤就是保存并编译。一张地图如果想在[[Source|起源引擎]]中运行则必须要编译。
{{clr}}
{{clr}}


== Saving the map ==
== 保存地图 ==
[[Image:hammer_saveas.jpg |thumb|right|200px| Choose ''Save As...'' to save the map.]]
[[Image:hammer_saveas.jpg |thumb|right|200px| 选择 ''另存为...''保存地图。]]
<!--[[Image:hammer_setname.jpg |thumb|right|200px| Type in a name for the map, then Click the Save button.]]-->
<!--[[Image:hammer_setname.jpg |thumb|right|200px| 键入地图的名字,然后点击保存按钮。]]-->


First, let’s save this map:
首先,我们来保存地图:


# Click the '''File''' menu.
# 点击'''文件'''菜单。
# As this is your first time saving this map, we will need to give it a name, so choose '''Save As...'''.
# 因为这是你第一次保存地图,所以我们要给它命名,因此请选'''另存为...'''
# A '''Save As...''' dialog will open. Type the name of your map into the '''File Name''' field:
# '''另存为...'''对话框将会打开。在'''文件名'''文本框中键入地图的名字:
#:{{warning|You cannot include any spaces in the filename.}}
#:{{warning:zh-cn|文件名中不能包含空格。}}
#* [[Half-Life 2: Deathmatch]] maps should have the <code>dm_</code> prefix before their map names so that they can easily be recognized.
#* [[Half-Life 2: Deathmatch|半条命2:死亡模式]]的地图应当在地图名称前有<code>dm_</code>前缀这样才容易和其他地图区分开。
# Click the '''Save''' button to save the map to disk.
# 点击'''保存'''按钮将地图保存到硬盘。


The map is saved in the .VMF file format.
地图会以.VMF文件格式保存。


{{note|You can also press <Ctrl+S> to save the map without having to open the menu.}}{{clr}}
{{note:zh-cn|你也可以使用快捷键<Ctrl+S>代替打开菜单来保存地图。}}{{clr}}


== Compiling the map ==
== 编译地图 ==
[[Image:hammer_pickrunmap.jpg |thumb|right|200px|Click the '''Run Map''' icon to compile your map.]]
[[Image:hammer_pickrunmap.jpg |thumb|right|200px|Click the '''Run Map''' icon to compile your map.]]



Revision as of 03:13, 2 December 2008

制作关卡的最后一个步骤就是保存并编译。一张地图如果想在起源引擎中运行则必须要编译。

保存地图

选择 另存为...保存地图。

首先,我们来保存地图:

  1. 点击文件菜单。
  2. 因为这是你第一次保存地图,所以我们要给它命名,因此请选另存为...
  3. 另存为...对话框将会打开。在文件名文本框中键入地图的名字:
    Template:Warning:zh-cn
  4. 点击保存按钮将地图保存到硬盘。

地图会以.VMF文件格式保存。

Template:Note:zh-cn

编译地图

Click the Run Map icon to compile your map.

You have saved your map, but you will also need to compile it before it can be played in the game engine.

When a map is compiled, it is converted from the raw .VMF file that you just saved, into the .BSP format used by the game engine. The geometry is processed and the proper lighting and shadows are pre-calculated with several compile programs.

Open the File menu, and choose Run Map....

The Run Map dialog will open.

Note.png注意:You can also press the F9 key to display this dialog
Change the Run Map parameters to match these settings, then click OK.

This dialog is used to set some basic compile parameters.

  1. Make sure that Normal is set under the Run BSP, Run VIS, and Run RAD settings.
  2. Under Additional game parameters:, type:
    -dev -console +sv_lan 1
    See Additional game parameters if you wish to learn more about these settings.
  3. Now click the OK button to start the map compile process.

The Compile Process Window will show the progress of the compile. When the compilation is done, the game you are mapping for will automatically launch, and load your map in the engine.

Note.png注意:If you wish to compile under HDR lighting, simply check the box that says HDR. The time to compile the map will be twice as long, but that is completely normal.
The final room, compiled and running in the game.

Here's a shot of the compiled map in-game. It isn’t much to look at yet, but it has the basic pieces you need to get started making your own maps.

Congratulations, you’ve made your first map!

Where do I go from here?

Now that you know the basics, look at the Level Design Category page for a list of articles and tutorials on different level design topics.

If you're having problems, you may wish to consult the Level Design FAQ.


Template:Otherlang:zh-cn Template:Otherlang:zh-cn:en, Template:Otherlang:zh-cn:fr, Template:Otherlang:zh-cn:ru.