Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[1.12] Mod works in dev environment but not after being built


Samaritans
 Share

Recommended Posts

Hey guys,

 

I recently added Mixin to my mod and it all works fine in my dev environment. However, after i ./gradlew build it, the jar isn't picked up as a forge mod.

 

From the looks of the logs, the core mod (mixin) is loaded but the mod itself is never loaded somehow. Please help!

 

here's my gradle:

buildscript {
    repositories {
        jcenter()
        maven { url = "http://files.minecraftforge.net/maven" }
	    maven { url "https://plugins.gradle.org/m2/" }
        maven {
            name = 'sponge'
            url = 'https://repo.spongepowered.org/maven'
        }	
    }
    dependencies {
        classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
	    classpath 'com.wynprice.cursemaven:CurseMaven:2.1.1'
        classpath "org.spongepowered:mixingradle:0.6-SNAPSHOT"
    }
}
apply plugin: 'net.minecraftforge.gradle.forge'
apply plugin: 'com.wynprice.cursemaven'
apply plugin: 'org.spongepowered.mixin'

version = "1.12.2-0.0.21-testbuild13"
group = "com.bewitchment"
archivesBaseName = "bewitchment"

sourceCompatibility = targetCompatibility = '1.8'
compileJava {
    sourceCompatibility = targetCompatibility = '1.8'
}

minecraft {
    version = "1.12.2-14.23.5.2838"
    runDir = "run"
    mappings = "stable_39"
    clientRunArgs += "--username=Samaritans"
    clientJvmArgs += "-Dfml.coreMods.load=com.bewitchment.core.BewitchmentFMLLoadingPlugin"
    serverJvmArgs += "-Dfml.coreMods.load=com.bewitchment.core.BewitchmentFMLLoadingPlugin"
}

repositories {
    flatDir {
        dirs 'libs'
    }
    maven { url = "http://dvs1.progwml6.com/files/maven" }
    maven { url = "https://minecraft.curseforge.com/api/maven" }
    maven { url "http://maven.tterrag.com" }
    maven { url "https://maven.blamejared.com" }
    maven { url "https://maven.mcmoddev.com/" }
    maven { url "http://repo.spongepowered.org/maven" }    
}

dependencies {
    deobfProvided "mezz.jei:jei_1.12.2:4.15.0.292"
    deobfProvided "thaumcraft:Thaumcraft:1.12.2:6.1.BETA26"
    deobfProvided "dynamictrees:DynamicTrees:1.12.2:0.9.5"
    deobfProvided "vazkii.botania:Botania:r1.10-363.119"
    deobfProvided "betteranimalsplus:betteranimalsplus:1.12.2:7.1.1"
    deobfProvided "curse.maven:rustic:2746408"
    deobfProvided "curse.maven:quark:2759240"
    deobfProvided "curse.maven:autoreglib:2746011"
    deobfProvided "curse.maven:mowzies-mobs:2699705"
    deobfProvided "curse.maven:chisel:2809394"
    deobfProvided "curse.maven:ctm:2809915"
    deobfCompile "net.ilexiconn:llibrary:1.7.9-1.12.2"	
    compile "baubles:Baubles:1.12:1.5.2"
    compile "vazkii.patchouli:Patchouli:1.0-20.99"
    implementation('org.spongepowered:mixin:0.7.11-SNAPSHOT') {
        exclude module: "asm-commons"
        exclude module: "asm-tree"
        exclude module: "launchwrapper"
        exclude module: "guava"
        exclude module: "log4j-core"
        exclude module: "gson"
        exclude module: "commons-io"
    }
    implementation 'org.jetbrains:annotations:15.0'
}

jar {
    manifest.attributes(
            'FMLCorePlugin': 'com.bewitchment.core.BewitchmentFMLLoadingPlugin',
            'TweakClass': 'org.spongepowered.asm.launch.MixinTweaker',
            'MixinConfigs': 'mixins.bewitchment.json',
            'FMLCorePluginContainsFMLMod': 'true'
    )
}

processResources {
    inputs.property "version", project.version
    inputs.property "mcversion", project.minecraft.version
    from(sourceSets.main.resources.srcDirs) {
        include 'mcmod.info'
        expand 'version': project.version, 'mcversion': project.minecraft.version
    }
    from(sourceSets.main.resources.srcDirs) {
        exclude 'mcmod.info'
    }
}

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.