我的世界 开发mod 配置forge步骤

发表在    java 08-03 11:37:57

2 3464 1
// 以下是readme原文。
-------------------------------------------
Source installation information for modders
-------------------------------------------
This code follows the Minecraft Forge installation methodology. It will apply
some small patches to the vanilla MCP source code, giving you and it access 
to some of the data and functions you need to build a successful mod.

Note also that the patches are built against "unrenamed" MCP source code (aka
srgnames) - this means that you will not be able to read them directly against
normal code.

Source pack installation information:

Standalone source installation
==============================

Step 1: Open your command-line and browse to the folder where you extracted the zip file.

Step 2: Once you have a command window up in the folder that the downloaded material was placed, type:

Windows: "gradlew setupDecompWorkspace"
Linux/Mac OS: "./gradlew setupDecompWorkspace"

Step 3: After all that finished, you're left with a choice.
For eclipse, run "gradlew eclipse" (./gradlew eclipse if you are on Mac/Linux)

If you preffer to use IntelliJ, steps are a little different.
1. Open IDEA, and import project.
2. Select your build.gradle file and have it import.
3. Once it's finished you must close IntelliJ and run the following command:

"gradlew genIntellijRuns" (./gradlew genIntellijRuns if you are on Mac/Linux)

Step 4: The final step is to open Eclipse and switch your workspace to /eclipse/ (if you use IDEA, it should automatically start on your project)

If at any point you are missing libraries in your IDE, or you've run into problems you can run "gradlew --refresh-dependencies" to refresh the local cache. "gradlew clean" to reset everything {this does not effect your code} and then start the processs again.

Should it still not work, 
Refer to #ForgeGradle on EsperNet for more information about the gradle environment.

Tip:
If you do not care about seeing Minecraft's source code you can replace "setupDecompWorkspace" with one of the following:
"setupDevWorkspace": Will patch, deobfusicated, and gather required assets to run minecraft, but will not generated human readable source code.
"setupCIWorkspace": Same as Dev but will not download any assets. This is useful in build servers as it is the fastest because it does the least work.

Tip:
When using Decomp workspace, the Minecraft source code is NOT added to your workspace in a editable way. Minecraft is treated like a normal Library. Sources are there for documentation and research purposes and usually can be accessed under the 'referenced libraries' section of your IDE.

Forge source installation
=========================
MinecraftForge ships with this code and installs it as part of the forge
installation process, no further action is required on your part.

LexManos' Install Video
=======================
https://www.youtube.com/watch?v=8VEdtQLuLO0&feature=youtu.be

For more details update more often refer to the Forge Forums:
http://www.minecraftforge.net/forum/index.php/topic,14048.0.html
//以下是谷歌翻译
-------------------------------------------
源代码安装信息
-------------------------------------------
该代码遵循Minecraft Forge安装方法。这将适用
一些小补丁到香草MCP源代码,给你和它的访问
你需要建立一个成功的mod的一些数据和功能。

还要注意,修补程序是针对“未命名的”MCP源代码构建的(也称为“
srgnames) - 这意味着你将无法直接阅读它们
正常代码

源码包安装信息:

独立源安装
==============================

步骤1:打开命令行并浏览到解压缩文件夹的文件夹。

步骤2:在放置下载的资料夹的文件夹中有一个命令窗口后,键入:

Windows:“gradlew setupDecompWorkspace”
Linux / Mac OS:“./gradlew setupDecompWorkspace”

步骤3:完成之后,您可以选择。
对于eclipse,运行“gradlew eclipse”(./gradlew eclipse如果你在Mac / Linux上)

如果您提前使用IntelliJ,步骤有所不同。
1.打开IDEA,并导入项目。
2.选择您的build.gradle文件并将其导入。
3.一旦完成,您必须关闭IntelliJ并运行以下命令:

“gradlew genIntellijRuns”(./gradlew genIntellijRuns如果你在Mac / Linux上)

步骤4:最后一步是打开Eclipse并将工作区切换到/ eclipse /(如果您使用IDEA,则应自动从您的项目开始)

如果在任何时候您在IDE中缺少库,或者遇到问题,可以运行“gradlew - refresh-dependencies”来刷新本地缓存。 “gradlew clean”重置所有的东西{这不影响你的代码},然后再次启动进程。

如果还不行,
有关渐变环境的更多信息,请参阅EsperNet上的#ForgeGradle。

提示:
如果您不在乎看到Minecraft的源代码,您可以使用以下选项之一替换“setupDecompWorkspace”:
“setupDevWorkspace”:将修补,解压缩并收集所需的资源以运行minecraft,但不会生成人类可读的源代码。
“setupCIWorkspace”:与Dev相同,但不会下载任何资产。这在构建服务器中是有用的,因为它是最快的,因为它执行最少的工作。

提示:
使用Decomp工作区时,Minecraft源代码不会以可编辑的方式添加到您的工作区。 Minecraft被视为正常的图书馆。来源有文档和研究目的,通常可以在IDE的“引用库”部分访问。

=========================
MinecraftForge附带此代码,并将其作为伪造的一部分进行安装
安装过程中,您无需进一步的操作。


登录或注册后发布评论