apply from: 'gradle/scripts/helpers.gradle'

repositories {
    // Other repositories described by default:
    // CleanroomMC: https://maven.cleanroommc.com
    maven {
        name 'CurseMaven'
        url 'https://curse.cleanroommc.com'
    }
    maven {
        name 'Modrinth'
        url 'https://api.modrinth.com/maven'
    }
    maven {
        name 'CleanroomMC Maven'
        url 'https://maven.cleanroommc.com'
    }
    maven {
        name 'Hileb'
        url 'https://ecdcaeb.github.io/maven/'
    }
    mavenLocal() // Must be last for caching to work
}

dependencies {
    compileOnly "com.cleanroommc:sponge-mixin:0.20.10+mixin.0.8.7"
    if (propertyBool('enable_lwjglx')) {
        compileOnly "com.cleanroommc:lwjglx:1.0.0"
    }

    compileOnly "net.optifine:optifine:1.12.2-HD_U_G5_unpatched_srg"

    runtimeOnly "net.optifine:optifine:1.12.2-HD_U_G5"
    runtimeOnly files("gradle/classpath/!!OptiFineDevTweaker-2.6.15-all.jar")

    // Example - Dependency descriptor:
    // 'com.google.code.gson:gson:2.8.6' << group: com.google.code.gson, name:gson, version:2.8.6
    // 'group:name:version:classifier' where classifier is optional

    // Example - Deobfuscating dependencies:
    // rfg.deobf('curse.maven:had-enough-items-557549:4543375')
    // By wrapping a dependency descriptor in rfg.deobf() method call, the dependency is queued for deobfuscation
    // When deobfuscating, RFG respects the mapping_channel + mapping_version stated in gradle.properties

    // Example - CurseMaven dependencies:
    // 'curse.maven:had-enough-items-557549:4543375' << had-enough-items = project slug, 557549 = project id, 4543375 = file id
    // Full documentation: https://cursemaven.com/

    // Example - Modrinth dependencies:
    // 'maven.modrinth:jei:4.16.1.1000' << jei = project name, 4.16.1.1000 = file version
    // Full documentation: https://docs.modrinth.com/docs/tutorials/maven/

    // Common dependency types (configuration):
    // implementation = dependency available at both compile time and runtime
    // runtimeOnly = runtime dependency
    // compileOnly = compile time dependency
    // annotationProcessor = annotation processing dependencies
    // contain = bundle dependency jars into final artifact, will extract them in mod loading. Please only do this to non-mod dependencies.
    // shadow = bundle dependencies into shadow output artifact (relocation configurable in shadowJar task)

    // Transitive dependencies:
    // (Dependencies that your dependency depends on)
    // If you wish to exclude transitive dependencies in the described dependencies
    // Use a closure as such:
    // implementation ('com.google.code.gson:gson:2.8.6') {
    //     transitive = false
    // }
}
