MOD技术的完全汉化 非软件翻译版
花了些时间对http://wiki.stilwater.info/index.php/Main_Page里面的内容进行翻译,由于对MOD不怎么熟悉,所以一些专业名词可能不很合适,或者存在硬伤,还得请熟悉MOD技术的朋友进行纠正,希望可以完善。Main Page
This site is a resource for Saints Row 2 modding information.
This wiki is for modding (and mod) information ONLY. Do not request mods or anything else of that nature on this wiki, use the Saints Row 2 community forum for that. Discussion on file formats, etc, is more than appropriate though!
[*]Getting started with modding. [*]Significant files found in Saints Row 2. [*]File formats found in Saints Row 2. [*]Useful tools. [*]Common problems that occur when editing Saints Row 2 files. [*]Rick's SVN repository for Saints Row 2 related code.
Getting startedDue to how Saints Row 2 loads game related files, it's not simple to just edit what you want. Saints Row 2 will load packages in a specific order, and unfortunately the game does not load any *.vpp_pc file found in the game directory, and it does not check the real filesystem before looking at packages for files.
There is no directory information retained in the package files. Meaning in order to override content in the packages you either have to make a new package for the game to load, or extract all files from all packages (or at least, common.vpp_pc and patch.vpp_pc) into your game directory (not a very good idea, there are many thousands of files in the packages).
Creating a new patch.vpp_pc file You'll want to extract common.vpp_pc and patch.vpp_pc to their own directories using Gibbed.SaintsRow2.ExtractPackage.exe. The common and patch packages contain the majority of files any modder will want to edit.
You will want to set up a directory structure similar to:
[*]moddingextractedcommon -- containing extracted contents of common.vpp_pc [*]moddingextractedpatch -- containing extracted contents of patch.vpp_pc [*]moddingmodified -- containing files that you have edited This tree does not have to be in the game directory (this is how I prefer it).
To make things simple, create a new text file named build.txt in the modding directory, put the following in it: (adjust it if you've changed the directory structure)
Gibbed.SaintsRow2.BuildPackage.exe "patch.vpp_pc" "modified" "extractedpatch"
Now rename build.txt to build.bat.
This batch file will build a package named patch.vpp_pc, using the directories modified, extractedpatch for files. Files in modified will override files in extractedpatch. Gibbed.SaintsRow2.BuildPackage.exe was made this way so that you didn't have to deal with copying files around to make a single directory. You want to add the original contents of the patch.vpp_pc since we are replacing it.
Running the batch file should generate a patch.vpp_pc file that you can now copy to your game directory. Be sure to back up the original patch.vpp_pc file!
Significant files [*]customization_categories.xtbl -- Defines the categories that items can fall under.[*]customization_icons.xtbl -- Sets up how the customization stores menus are laid out (what item categories go where, etc).[*]customization_items.xtbl -- Contains definitions for all clothing, tattoos, etc, that can be used to customize characters.[*]customization_logos.xtbl -- What logos the player can use for clothing that allow logo placement.[*]customization_outfits.xtbl -- Defines outfits -- what items go in them.[*]customization_slots.xtbl -- Defines item slots (where items can go).[*]customization_stores.xtbl -- Store definitions, defines what stores sell what.
Gibbed tools [*]Gibbed.SaintsRow2.BuildPackage.exe -- Command-line tool to create .vpp_pc packages.[*]Gibbed.SaintsRow2.ConvertPeg.exe -- Converts .peg_pc files to PNG files.[*]Gibbed.SaintsRow2.ExtractPackage.exe -- GUI tool to extract the contents of .vpp_pc packages.
Common problems that occur when editing Saints Row 2 files.
[*]Game will crash on missing or badly formatted files (especially XTBL files!), usually when the game is at 80% loaded.[*]Game will crash if you add an item to a store that is in a slot flagged as NPC only (example: items in loose belt slot, such as the police belt).[*]Customization stores will fail to open (when using the shopping cart icon) if you add an invalid customization outfit.[*]Editing customization_items.xml will possibly cause the game to crash when attempting to load a save that wasn't made with the edited customization_items.xml.
Aerosmiths汉化版:
首页
这个站点提供关于黑道圣徒2的modding相关信息。
这个wiki(是一种多人协作的写作工具,wiki可以有多人维护,甚至是来宾,每个人都可以发表自己的意见,或
对相同的主题进行扩展和探讨。这种超文本系统支持面向社群的协作式写作)站点仅提供modding(和mod)信
息。请不要索求mods或者其他与信息无关的事情,或者去黑道圣徒2的社区论坛,进行关于文件格式等问题的讨
论,虽然这里比那里更合适。
l
Modding的初始化。
l
黑道圣徒2中的重要文件。
l
黑道圣徒2中的文件格式。
l
有用的工具。
l
当编辑黑道圣徒2中两个文件时遇到的共同问题。
l
包含了黑道圣徒2相关代码Rick的SVN库。
Modding的初始化
由于黑道圣徒2读取游戏相关文件的方式,使得你不能够很简单的就对其进行编辑。黑道圣徒2会在一个特殊的命令下读
取packages文件,而不幸的是这个游戏并不能读取在游戏目录中找到的任何后缀名为*.vpp_pc的文件,并且它会在读取
文件之前检查packages文件是否是真正的系统文件。(也就是会对文件进行加密)
在packages文件中不会保留目录信息,这就意味着为了使它忽略packages包里的内容你必须做一个可以让游戏读取的
新的packages包,或者是从所有的packages中提取所有文件(至少,是common.vpp_pc 和 patch.vpp_pc文件)到你
的游戏目录(这不是一个很好的办法,因为在packages包里有数以万计的文件)。
创建一个新的patch.vpp_pc文件
使用Gibbed.SaintsRow2.ExtractPackage.exe,提取common.vpp_pc和patch.vpp_pc两个文件到他们自己的目录。并创造一个新的patch.vpp_pc文件。
补丁包中包含了大多数你想要对其进行编辑的modder文件。
你要将设定目录格式结构如下列:
lModdingextracted(提取)common--包含从common.vpp_pc中提取的内容
lModding extracted(提取)patch--包含从patch.vpp_pc中提取的内容
lModdingmodified(修改)--包含你编辑过的文件
这个结构不用必须在游戏目录中(这是我喜欢它的原因)
要想使事情变得简单,那么在modding目录里创建一个名字为build.txt的新文件,把下面的内容添加进去:(如果你改变了目录结构那么就需要加以调整)
Gibbed.SaintsRow2.BuildPackage.exe "patch.vpp_pc" "modified" "extractedpatch"
添加完成后,重命名这个build.txt为build.bat
这个批处理文件将在你修改过的目录里建立一个名为patch.vpp_pc和extractedpatch的文件。在extractedpatch里修改
过的文件会被覆盖。
Gibbed.SaintsRow2.BuildPackage.exe被做成了这样以便你不用必须在唯一的目录中复制所涉及到的文件。你可以在我
们替换它之前添加patch.vpp_pc的原始内容。
运行批处理文件会激活你复制到游戏目录中的patch.vpp_pc文件,在运行之前请务必备份原始的patch.vpp_pc文件。
黑道圣徒2中的重要文件
customization_categories.xtbl – 定义了项目可能属于什么类别.
customization_icons.xtbl - - 设定了怎样定制商店菜单(项目类别等等)。
customization_items.xtbl - - 包括了所有衣物,纹身的定义,可以被用于定做字符。
customization_logos.xtbl - - 允许在衣物上设置商标以供使用。
customization_outfits.xtbl - - 定义了成套的装备。
customization_slots.xtbl - - 定义了项目扩展点。
customization_stores.xtbl - - 存放定义,定义了什么商店出售什么商品。
黑道圣徒2中的文件格式。
LUA
Lua是一个小巧的脚本语言,游戏的许多地方都会用到它。幸运的是La脚本提供还没有被游戏编译的由开发商编写的文件。
看看system_lib.lua, ug_lib.lua, and vint_lib.lua(在patch.vpp_pc可以被找到)的信息。
LeStrings
.le_strings是字符串文件,标注了一些无用信息以便于能够高效率的查询所需文件信息。
.peg_pc
.peg_pc文件定义了在.g_peg_pc中被找到的纹理数据的信息,例如宽度,框架高度,多重图像等等。
以下是在.g_peg_pc文件中存放的图像数据的多种格式:
粗体显示的词条是在黑道圣徒2中使用到的。
DXT1 (400)
DXT3 (401)
DXT5 (402)
R5G6B5 (403)
A1R5G5B5 (404)
A4R4G4B4 (405)
R8G8B8 (406)
A8R8G8B8 (407)
V8U8 (408)
CxV8U8 (409)
A8 (410)
.g_peg_pc
包含了未加工的纹理数据。
XTBL
XML的推测表
XML格式文件包含了结构配置的设置。一个_Editor的元素在多数的.xtbl文件末端定义了文件的结构。
有用的工具
Gibbed.SaintsRow2.BuildPackage.exe - - 创造.vpp_pc包的工具。
Gibbed.SaintsRow2.ConvertPeg.exe - - 将.peg_pc文件转换成PNG文件的工具。
Gibbed.SaintsRow2.ExtractPackage.exe - - 提取.vpp_pc包裹内容的图像工具。
当编辑黑道圣徒2中两个文件时遇到的共同问题
游戏会在丢失或者损坏文件情况下崩溃(特别是XTBL文件),通常情况下发生在游戏读取到80%的时候。
如果你增加一个仅能够让NPC使用的项目到商店目录中时游戏会发生崩溃(例如警察的腰带)
如果你增加了无效的套装装备,那么商店将不会被打开。
编辑customization_items.xml可能会造成游戏崩溃,
Packages
Packages(*.vpp_pc)是按照具体顺寻被读取的,新的Packages
文件将覆盖掉旧的Packages文件。
Packages文件按以下顺序被读取装载
anims.vpp_pc -- 动画
audio.vpp_pc -- 声音
chunks1.vpp_pc -- 地图相关文件(纹理、大体积物体等等)
chunks2.vpp_pc -- 地图相关文件(纹理、大体积物体等等)
chunks3.vpp_pc -- 地图相关文件(纹理、大体积物体等等)
chunks4.vpp_pc -- 纹理数据,映射相关文件(纹理、大体积物体等等)
common.vpp_pc – XML表和其他配置文件
cutscenes.vpp_pc – 关于Cutscene的文件
meshes.vpp_pc -- 滤网
music1.vpp_pc -- 音乐
music2.vpp_pc -- 音乐
music3.vpp_pc -- 音乐
music4.vpp_pc -- 音乐
pegs.vpp_pc -- 纹理信息
textures.vpp_pc -- 纹理数据
patch.vpp_pc – Lua脚本,配置文件,其他混杂文件
city_load.vpp_pc --当游戏开始(新的游戏、读取游戏等等)时的装载文件,注意不要使用这个文件!
太强大了,这种深入的研究
有讲到与语音有关的吗?汉化就有希望了吧。。。。。 我是门外汉···只有纯支持了·· 72。。。你怎么会跑这里来。。。 还不是你吸引来的……我是第一次游戏区看见他…… 强大······期待做的MOD Gibbed.SaintsRow2.ExtractPackage.exe并没有提供啊
应该可以把语言文件提取出来吧。。 。。。找到了,好多相关文件,,尝试分析一下
。。刚刚用beyond compare,发现1.1版本把除了US以外的语言设置文件都去掉了,也就是说1.1补丁确实只有英文
能否用1.0的文件替换进去有待试验 人力置顶,楼主如此强人不知道M版几顾茅庐请来的^0^
看来改商店服装有难度啊,关联文件一大堆还说崩溃就崩溃 通过传送门过来支持黑道产业~~ 标个记....日后好找.....额....我的意思是以后 欢迎各位大驾光临 万分感谢楼主的无私奉献,努力回帖表示感谢!!!! 偶是民工玩家,这么深奥就等待强人去造。。。。 支持强大的MOD 完全看不懂
门外汉的悲哀
非常感谢LZ分享
非常感谢LZ分享 顶啊!!!!! 翻译的很好但是有很浓重的电脑翻译色彩 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 精華區的連接不對了說 非常感谢楼主分享 坐等3代!!!
页:
[1]