Skip to content

Commit

Permalink
Fix wrong SRG mapping type
Browse files Browse the repository at this point in the history
  • Loading branch information
LunNova committed Mar 4, 2016
1 parent a06a8e3 commit f2d2325
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,10 @@ if (System.env.GRADLE_USER_HOME) {
ext.homeDir = System.properties['user.home'] + '/.gradle/'
}
ext.mappingsPath = homeDir + 'caches/minecraft/de/oceanlabs/mcp/mcp_' + mappings_channel + '/' + mappings_version + '/'
ext.srgPath = mappingsPath + 'srgs/srg-mcp.srg'

jar.doFirst {
if (!file(mappingsPath + 'fields.csv').exists())
if (!file(mappingsPath + 'fields.csv').exists() || !file(srgPath))
throw new Error("Can't find mappings at " + mappingsPath)
}

Expand All @@ -104,7 +105,7 @@ jar {
}) {
exclude "META-INF/**"
}
from mappingsPath + '/srg/srg-mcp.srg'
from srgPath
from mappingsPath + 'methods.csv'
from mappingsPath + 'fields.csv'
from './generated/extendsMap.obj'
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/me/nallar/modpatcher/MCPMappings.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public MCPMappings() throws IOException {
try {
loadCsv(Mappings.class.getResourceAsStream("/methods.csv"), methodSeargeMappings);
loadCsv(Mappings.class.getResourceAsStream("/fields.csv"), fieldSeargeMappings);
loadSrg(Mappings.class.getResourceAsStream("/packaged.srg"));
loadSrg(Mappings.class.getResourceAsStream("/srg-mcp.srg"));
} catch (Exception e) {
PatcherLog.error("Failed to load MCP mappings", e);
}
Expand Down

0 comments on commit f2d2325

Please sign in to comment.