Zh/Decompiling Maps: Difference between revisions

From Valve Developer Community
< Zh
Jump to navigation Jump to search
No edit summary
No edit summary
Line 6: Line 6:


Releasing reproductions, modifications, or approximations of another's work without permission nor credit is frowned upon and may be considered as a copyright violation.
Releasing reproductions, modifications, or approximations of another's work without permission nor credit is frowned upon and may be considered as a copyright violation.
==Tools==
==工具==
* [[Entspy|EntSpy]]
* [[Entspy|EntSpy]]
* [[BSPSource]]
* [[BSPSource]]
Line 16: Line 16:
* [[BSP Viewer]]
* [[BSP Viewer]]


== Getting Dirty ==
== 注意事项 ==
The latest decompiler is called [[BSPSource]] and is written in Java. You need an updated version of the Java Runtime Environment (JRE), which can be downloaded from [http://java.sun.com/javase/downloads/ Sun] to run BSPSource. Once installed, you are ready to decompile your first map.
最新的反编译软件叫做[[BSPSource]],由Java语言写成。你需要一个升级版的Java Runtime Environment(JRE)来运行BSPSource。下载:[http://java.sun.com/javase/downloads/ Sun]。安装完成后,你就可以准备开始反编译地图了。


== Extracting Valve maps ==
== 提取地图 ==


'''(Note: This tutorial assumes that you have opted into the SteamPipe beta for any Orange Box titles. Games released after 2007 or games that are multiplayer titles will have already stashed their content in <code>\steamapps\common\</code>.)'''
'''(Note: 本教程假设你已经为橙盒游戏选择了[[https://developer.valvesoftware.com/wiki/SteamPipe|SteamPipe]]。在2007年之后发行的游戏或者是存在多人内容的游戏已经把他们的内容放在了<code>\steamapps\common\</code>.)'''


# Install [[GCFScape]].
# 安装 [[GCFScape]].
# After you install GCFScape, go to <code>File &gt;&gt; Open</code>.
# GCFScape安装完成后,单击<code>文件→打开</code>.
#* For {{csgo}}[[Counter-Strike: Global Offensive]] maps, open '''<code>\steamapps\common\Counter-Strike Global Offensive\csgo\pak01_dir.vpk</code>'''
#* {{csgo}}反恐精英:全球攻势的地图,打开'''<code>\steamapps\common\Counter-Strike Global Offensive\csgo\pak01_dir.vpk</code>'''
#* For {{css}}[[Counter-Strike: Source]] maps, open '''<code>\steamapps\common\counter-strike source\cstrike\strike_pak_dir.vpk</code>'''
#* {{css}}反恐精英:起源的地图,打开'''<code>\steamapps\common\counter-strike source\cstrike\strike_pak_dir.vpk</code>'''
#* For {{dods}}[[Day of Defeat: Source]] maps, open '''<code>\steamapps\common\Day of Defeat Source\dod\dod_pak_dir.vpk</code>'''
#* {{dods}}胜利之日:起源的地图,打开'''<code>\steamapps\common\Day of Defeat Source\dod\dod_pak_dir.vpk</code>'''
#* For {{hl2}}[[Half-Life 2]] maps, open '''<code>\steamapps\common\half-life 2\hl2\hl2_misc_dir.vpk</code>'''
#* {{hl2}}半条命2的地图,打开'''<code>\steamapps\common\half-life 2\hl2\hl2_misc_dir.vpk</code>'''
#* For {{hl2}}[[Half-Life 2: Deathmatch]] maps, open '''<code>\steamapps\common\half-life 2 deathmatch\hl2mp\hl2mp_pak_dir.vpk</code>'''
#* {{hl2}}半条命2:死亡竞赛的地图,打开'''<code>\steamapps\common\half-life 2 deathmatch\hl2mp\hl2mp_pak_dir.vpk</code>'''
#* For {{ep1}}[[Half-Life 2: Episode One]] maps, open '''<code>\steamapps\common\half-life 2\episodic\ep1_pak_dir.vpk</code>'''
#* {{ep1}}半条命2:第一章的地图,打开'''<code>\steamapps\common\half-life 2\episodic\ep1_pak_dir.vpk</code>'''
#* For {{ep2}}[[Half-Life 2: Episode Two]] maps, open '''<code>\steamapps\common\half-life 2\ep2\ep2_pak_dir.vpk</code>'''
#* {{ep2}}半条命2:第二章的地图,打开'''<code>\steamapps\common\half-life 2\ep2\ep2_pak_dir.vpk</code>'''
#* For {{portal}}[[Portal]] maps, open '''<code>\steamapps\common\portal\portal\portal_pak_dir.vpk</code>'''
#* {{portal}}传送门的地图,打开'''<code>\steamapps\common\portal\portal\portal_pak_dir.vpk</code>'''
#* For {{portal2}}[[Portal 2]] maps, open '''<code>steamapps\common\portal 2\portal2\pak01_dir.vpk</code>'''
#* {{portal2}}传送门2的地图,打开'''<code>steamapps\common\portal 2\portal2\pak01_dir.vpk</code>'''
#* For {{tf2}}[[Team Fortress 2]] maps, open '''<code>\steamapps\common\Team Fortress 2\tf\tf2_misc_dir.vpk</code>'''
#* {{tf2}}军团要塞2的地图,打开'''<code>\steamapps\common\Team Fortress 2\tf\tf2_misc_dir.vpk</code>'''
#* For {{l4d}}[[Left 4 Dead]] maps, open '''<code>steamapps\common\left 4 dead\l4d\pak01_dir.vpk</code>'''
#* {{l4d}}求生之路的地图,打开'''<code>steamapps\common\left 4 dead\l4d\pak01_dir.vpk</code>'''
#* For {{l4d2}}[[Left 4 Dead 2]] maps, open '''<code>steamapps\common\left 4 dead 2\l4d2\pak01_dir.vpk</code>'''
#* {{l4d2}}求生之路2的地图,打开'''<code>steamapps\common\left 4 dead 2\l4d2\pak01_dir.vpk</code>'''
{{note|Left 4 Dead, Left 4 Dead 2, and Portal 2 also have other folders for DLCs, for examples:  
{{note|求生之路、求生之路2、传送门2都有DLC专用文件夹,例如:  
'''<code>steamapps\common\portal2\portal2_dlc1\pak01_dir.vpk</code>''' and '''<code>steamapps\common\left 4 dead\l4d_dlc1\pak01_dir.vpk</code>''' .}}
'''<code>steamapps\common\portal2\portal2_dlc1\pak01_dir.vpk</code>''' and '''<code>steamapps\common\left 4 dead\l4d_dlc1\pak01_dir.vpk</code>''' .}}
3. Browse the directory until you find a <code>\maps\</code> folder. Each location varies per game.<br />
3. 找到<code>\maps\</code>文件夹,每个游戏的位置各不相同。<br />
4. Right-click on the BSP file you want, then click <code>Extract</code> or drag the file from the GCF into a folder.
4. 右击BSP文件,然后点击<code>提取(Extract)</code>


== Before You Go ==
== Before You Go ==

Revision as of 20:39, 18 September 2015

Template:Otherlang2 Decompiling is the process of taking a compiled level and generating a source that can be opened in a map editor. Decompiled levels mimic the original source, they are not exact reproductions. This makes them useful for learning, measurement, and inspection, but not direct recompilation. The original source is ideal for reproductions or modifications.

Releasing reproductions, modifications, or approximations of another's work without permission nor credit is frowned upon and may be considered as a copyright violation.

工具

注意事项

最新的反编译软件叫做BSPSource,由Java语言写成。你需要一个升级版的Java Runtime Environment(JRE)来运行BSPSource。下载:Sun。安装完成后,你就可以准备开始反编译地图了。

提取地图

(Note: 本教程假设你已经为橙盒游戏选择了[[1]]。在2007年之后发行的游戏或者是存在多人内容的游戏已经把他们的内容放在了\steamapps\common\.)

  1. 安装 GCFScape.
  2. GCFScape安装完成后,单击文件→打开.
    • 反恐精英:全球攻势反恐精英:全球攻势的地图,打开\steamapps\common\Counter-Strike Global Offensive\csgo\pak01_dir.vpk
    • 反恐精英:起源反恐精英:起源的地图,打开\steamapps\common\counter-strike source\cstrike\strike_pak_dir.vpk
    • 胜利之日:起源胜利之日:起源的地图,打开\steamapps\common\Day of Defeat Source\dod\dod_pak_dir.vpk
    • 半衰期2半条命2的地图,打开\steamapps\common\half-life 2\hl2\hl2_misc_dir.vpk
    • 半衰期2半条命2:死亡竞赛的地图,打开\steamapps\common\half-life 2 deathmatch\hl2mp\hl2mp_pak_dir.vpk
    • 半衰期2:第一章半条命2:第一章的地图,打开\steamapps\common\half-life 2\episodic\ep1_pak_dir.vpk
    • 半衰期2:第二章半条命2:第二章的地图,打开\steamapps\common\half-life 2\ep2\ep2_pak_dir.vpk
    • 传送门传送门的地图,打开\steamapps\common\portal\portal\portal_pak_dir.vpk
    • 传送门2传送门2的地图,打开steamapps\common\portal 2\portal2\pak01_dir.vpk
    • 军团要塞2军团要塞2的地图,打开\steamapps\common\Team Fortress 2\tf\tf2_misc_dir.vpk
    • 求生之路求生之路的地图,打开steamapps\common\left 4 dead\l4d\pak01_dir.vpk
    • 求生之路2求生之路2的地图,打开steamapps\common\left 4 dead 2\l4d2\pak01_dir.vpk
Note.png注意:求生之路、求生之路2、传送门2都有DLC专用文件夹,例如: steamapps\common\portal2\portal2_dlc1\pak01_dir.vpk and steamapps\common\left 4 dead\l4d_dlc1\pak01_dir.vpk .

3. 找到\maps\文件夹,每个游戏的位置各不相同。
4. 右击BSP文件,然后点击提取(Extract)

Before You Go

Before you take this jump to run off and decompile a map take a second or two to think, "What am I trying to learn/do?". Read the included TXT files, you may just find the creator's e-mail, and that could be more helpful than you imagine.

Some mappers will offer up help and advice, they may even go so far as to provide perfect examples of what you were trying to "borrow" from the map.