mirror of
				https://github.com/SquidDev-CC/CC-Tweaked
				synced 2025-11-03 23:22:59 +00:00 
			
		
		
		
	Compare commits
	
		
			113 Commits
		
	
	
		
			v1.16.5-1.
			...
			v1.18.2-1.
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					159f90896e | ||
| 
						 | 
					f108ba93af | ||
| 
						 | 
					2a4f75ba15 | ||
| 
						 | 
					ad228e94a3 | ||
| 
						 | 
					42b98bce28 | ||
| 
						 | 
					59e3608d2a | ||
| 
						 | 
					fccca22d3f | ||
| 
						 | 
					4bfdb65989 | ||
| 
						 | 
					22e8b9b587 | ||
| 
						 | 
					77a00b14ae | ||
| 
						 | 
					78aa757549 | ||
| 
						 | 
					1196568a7c | ||
| 
						 | 
					48c4f397f9 | ||
| 
						 | 
					8871f40ced | ||
| 
						 | 
					aa62c1f206 | ||
| 
						 | 
					fd32b06d6f | ||
| 
						 | 
					739d6813c0 | ||
| 
						 | 
					daf81b897a | ||
| 
						 | 
					e865d96f7b | ||
| 
						 | 
					79b1872cab | ||
| 
						 | 
					41fa95bce4 | ||
| 
						 | 
					2a92794da3 | ||
| 
						 | 
					b3e009cca5 | ||
| 
						 | 
					ba7598c689 | ||
| 
						 | 
					70c5cbafec | ||
| 
						 | 
					2c64186965 | ||
| 
						 | 
					7731759c77 | ||
| 
						 | 
					e6339b2847 | ||
| 
						 | 
					31ba17d085 | ||
| 
						 | 
					6353e8d930 | ||
| 
						 | 
					78cce4981a | ||
| 
						 | 
					97c953a9be | ||
| 
						 | 
					52df7cb8a4 | ||
| 
						 | 
					6735cfd12e | ||
| 
						 | 
					bcc7dd6991 | ||
| 
						 | 
					f994696161 | ||
| 
						 | 
					4a4e8bb4b6 | ||
| 
						 | 
					bd36185662 | ||
| 
						 | 
					045c4fc88c | ||
| 
						 | 
					e0fcc425c6 | ||
| 
						 | 
					e01895d719 | ||
| 
						 | 
					87b38f4249 | ||
| 
						 | 
					60d1d1bb18 | ||
| 
						 | 
					cdf8b77ffd | ||
| 
						 | 
					e2ce52fe81 | ||
| 
						 | 
					9edce36efd | ||
| 
						 | 
					e05588c662 | ||
| 
						 | 
					9cf70b10ef | ||
| 
						 | 
					9ac8f3aeea | ||
| 
						 | 
					e191b08eb5 | ||
| 
						 | 
					a1221b99e1 | ||
| 
						 | 
					85bced6b1d | ||
| 
						 | 
					fc4569e0cc | ||
| 
						 | 
					e7f08313d9 | ||
| 
						 | 
					79366bf2f5 | ||
| 
						 | 
					413fa5bcc8 | ||
| 
						 | 
					79fc8237b6 | ||
| 
						 | 
					9d50d6414c | ||
| 
						 | 
					16df86224b | ||
| 
						 | 
					a9519f68a1 | ||
| 
						 | 
					f1a08a3362 | ||
| 
						 | 
					802949d888 | ||
| 
						 | 
					2b901f2d5e | ||
| 
						 | 
					62f2cd5cb2 | ||
| 
						 | 
					901d8d4c3b | ||
| 
						 | 
					f794ce42ab | ||
| 
						 | 
					2562642664 | ||
| 
						 | 
					632db1cfa5 | ||
| 
						 | 
					aa0d544bba | ||
| 
						 | 
					2f6ad00764 | ||
| 
						 | 
					05da4dd362 | ||
| 
						 | 
					fe3c42ce22 | ||
| 
						 | 
					f6fcba7a39 | ||
| 
						 | 
					82a7edee12 | ||
| 
						 | 
					7c373c6e06 | ||
| 
						 | 
					6196aae488 | ||
| 
						 | 
					57c5d19f95 | ||
| 
						 | 
					23c17075be | ||
| 
						 | 
					87988a705b | ||
| 
						 | 
					179da1d8cf | ||
| 
						 | 
					92fd93c0e0 | ||
| 
						 | 
					af966179ce | ||
| 
						 | 
					2418cfb87b | ||
| 
						 | 
					095101831c | ||
| 
						 | 
					7b7527ec80 | ||
| 
						 | 
					a4c5ecf8df | ||
| 
						 | 
					99de00e16e | ||
| 
						 | 
					600227e481 | ||
| 
						 | 
					cf3f1d3d48 | ||
| 
						 | 
					bca964629a | ||
| 
						 | 
					0e94355a85 | ||
| 
						 | 
					0d35331b82 | ||
| 
						 | 
					076b454c8f | ||
| 
						 | 
					36e0dcbad0 | ||
| 
						 | 
					0b5fe990e5 | ||
| 
						 | 
					29ece2a6e3 | ||
| 
						 | 
					eba26dedab | ||
| 
						 | 
					3eb601e554 | ||
| 
						 | 
					d0e79f310e | ||
| 
						 | 
					0d6528aaf0 | ||
| 
						 | 
					b447b0e308 | ||
| 
						 | 
					b2273c9b29 | ||
| 
						 | 
					bbf3e48763 | ||
| 
						 | 
					92fe1d4bc2 | ||
| 
						 | 
					4d591c600c | ||
| 
						 | 
					0a8e427c61 | ||
| 
						 | 
					0a537eaeee | ||
| 
						 | 
					aa857c1be3 | ||
| 
						 | 
					e4ced551eb | ||
| 
						 | 
					6eec9ba1a3 | ||
| 
						 | 
					a8f675c59d | ||
| 
						 | 
					bb1ebaee4f | ||
| 
						 | 
					bb1183d274 | 
							
								
								
									
										173
									
								
								build.gradle
									
									
									
									
									
								
							
							
						
						
									
										173
									
								
								build.gradle
									
									
									
									
									
								
							@@ -31,7 +31,7 @@ version = mod_version
 | 
			
		||||
group = "org.squiddev"
 | 
			
		||||
archivesBaseName = "cc-tweaked-${mc_version}"
 | 
			
		||||
 | 
			
		||||
def javaVersion = JavaLanguageVersion.of(8)
 | 
			
		||||
def javaVersion = JavaLanguageVersion.of(17)
 | 
			
		||||
java {
 | 
			
		||||
    toolchain {
 | 
			
		||||
        languageVersion = javaVersion
 | 
			
		||||
@@ -58,6 +58,10 @@ sourceSets {
 | 
			
		||||
minecraft {
 | 
			
		||||
    runs {
 | 
			
		||||
        all {
 | 
			
		||||
            lazyToken('minecraft_classpath') {
 | 
			
		||||
                configurations.shade.copyRecursive().resolve().collect { it.absolutePath }.join(File.pathSeparator)
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            property 'forge.logging.markers', 'REGISTRIES'
 | 
			
		||||
            property 'forge.logging.console.level', 'debug'
 | 
			
		||||
 | 
			
		||||
@@ -84,25 +88,19 @@ minecraft {
 | 
			
		||||
            args '--mod', 'computercraft', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        testClient {
 | 
			
		||||
            workingDirectory project.file('test-files/client')
 | 
			
		||||
            parent runs.client
 | 
			
		||||
        gameTestServer {
 | 
			
		||||
            workingDirectory project.file('test-files/server')
 | 
			
		||||
 | 
			
		||||
            mods {
 | 
			
		||||
                cctest {
 | 
			
		||||
                    source sourceSets.testMod
 | 
			
		||||
                }
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        testServer {
 | 
			
		||||
            workingDirectory project.file('test-files/server')
 | 
			
		||||
            parent runs.server
 | 
			
		||||
 | 
			
		||||
            mods {
 | 
			
		||||
                cctest {
 | 
			
		||||
                    source sourceSets.testMod
 | 
			
		||||
                }
 | 
			
		||||
            lazyToken('minecraft_classpath') {
 | 
			
		||||
                (configurations.shade.copyRecursive().resolve() + configurations.testModExtra.copyRecursive().resolve())
 | 
			
		||||
                    .collect { it.absolutePath }
 | 
			
		||||
                    .join(File.pathSeparator)
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
@@ -128,23 +126,22 @@ repositories {
 | 
			
		||||
configurations {
 | 
			
		||||
    shade
 | 
			
		||||
    implementation.extendsFrom shade
 | 
			
		||||
 | 
			
		||||
    cctJavadoc
 | 
			
		||||
 | 
			
		||||
    testModExtra
 | 
			
		||||
    testModImplementation.extendsFrom(testModExtra)
 | 
			
		||||
    testModImplementation.extendsFrom(implementation)
 | 
			
		||||
    testModImplementation.extendsFrom(testImplementation)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
dependencies {
 | 
			
		||||
    checkstyle "com.puppycrawl.tools:checkstyle:8.25"
 | 
			
		||||
    checkstyle "com.puppycrawl.tools:checkstyle:8.45"
 | 
			
		||||
 | 
			
		||||
    minecraft "net.minecraftforge:forge:${mc_version}-${forge_version}"
 | 
			
		||||
    annotationProcessor 'org.spongepowered:mixin:0.8.4:processor'
 | 
			
		||||
 | 
			
		||||
    compileOnly fg.deobf("mezz.jei:jei-1.16.5:7.7.0.104:api")
 | 
			
		||||
    compileOnly fg.deobf("com.blamejared.crafttweaker:CraftTweaker-1.16.5:7.1.0.313")
 | 
			
		||||
    compileOnly fg.deobf("commoble.morered:morered-1.16.5:2.1.1.0")
 | 
			
		||||
 | 
			
		||||
    runtimeOnly fg.deobf("mezz.jei:jei-1.16.5:7.7.0.104")
 | 
			
		||||
    compileOnly fg.deobf("mezz.jei:jei-1.18.2:9.4.1.116:api")
 | 
			
		||||
    runtimeOnly fg.deobf("mezz.jei:jei-1.18.2:9.4.1.116")
 | 
			
		||||
 | 
			
		||||
    shade 'org.squiddev:Cobalt:0.5.2-SNAPSHOT'
 | 
			
		||||
 | 
			
		||||
@@ -153,10 +150,12 @@ dependencies {
 | 
			
		||||
    testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.7.0'
 | 
			
		||||
    testImplementation 'org.hamcrest:hamcrest:2.2'
 | 
			
		||||
    testImplementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.6.0'
 | 
			
		||||
    testImplementation 'org.jetbrains.kotlin:kotlin-reflect:1.6.0'
 | 
			
		||||
    testImplementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2'
 | 
			
		||||
 | 
			
		||||
    testModImplementation sourceSets.main.output
 | 
			
		||||
    testModExtra('org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.6.0') {
 | 
			
		||||
        exclude group: "org.jetbrains", module: "annotations"
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    cctJavadoc 'cc.tweaked:cct-javadoc:1.4.5'
 | 
			
		||||
}
 | 
			
		||||
@@ -184,7 +183,7 @@ task luaJavadoc(type: Javadoc) {
 | 
			
		||||
    options.noTimestamp = false
 | 
			
		||||
 | 
			
		||||
    javadocTool = javaToolchains.javadocToolFor {
 | 
			
		||||
        languageVersion = JavaLanguageVersion.of(11)
 | 
			
		||||
        languageVersion = javaVersion
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@@ -197,7 +196,8 @@ jar {
 | 
			
		||||
            "Implementation-Title"    : "CC: Tweaked",
 | 
			
		||||
            "Implementation-Version"  : "${mod_version}",
 | 
			
		||||
            "Implementation-Vendor"   : "SquidDev",
 | 
			
		||||
            "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"),
 | 
			
		||||
            "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
 | 
			
		||||
        ,
 | 
			
		||||
            "MixinConfigs"            : "computercraft.mixins.json",
 | 
			
		||||
        ])
 | 
			
		||||
    }
 | 
			
		||||
@@ -205,6 +205,8 @@ jar {
 | 
			
		||||
    from configurations.shade.collect { it.isDirectory() ? it : zipTree(it) }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
jar.finalizedBy('reobfJar')
 | 
			
		||||
 | 
			
		||||
[compileJava, compileTestJava, compileTestModJava].forEach {
 | 
			
		||||
    it.configure {
 | 
			
		||||
        options.compilerArgs << "-Xlint" << "-Xlint:-processing"
 | 
			
		||||
@@ -212,9 +214,6 @@ jar {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
processResources {
 | 
			
		||||
    inputs.property "version", mod_version
 | 
			
		||||
    inputs.property "mcversion", mc_version
 | 
			
		||||
 | 
			
		||||
    def hash = 'none'
 | 
			
		||||
    Set<String> contributors = []
 | 
			
		||||
    try {
 | 
			
		||||
@@ -231,16 +230,14 @@ processResources {
 | 
			
		||||
    duplicatesStrategy = DuplicatesStrategy.INCLUDE
 | 
			
		||||
 | 
			
		||||
    from(sourceSets.main.resources.srcDirs) {
 | 
			
		||||
        include 'META-INF/mods.toml'
 | 
			
		||||
        include 'data/computercraft/lua/rom/help/credits.txt'
 | 
			
		||||
 | 
			
		||||
        expand 'version': mod_version,
 | 
			
		||||
                'mcversion': mc_version,
 | 
			
		||||
                'gitcontributors': contributors.sort(false, String.CASE_INSENSITIVE_ORDER).join('\n')
 | 
			
		||||
        expand(
 | 
			
		||||
            'gitcontributors': contributors.sort(false, String.CASE_INSENSITIVE_ORDER).join('\n')
 | 
			
		||||
        )
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    from(sourceSets.main.resources.srcDirs) {
 | 
			
		||||
        exclude 'META-INF/mods.toml'
 | 
			
		||||
        exclude 'data/computercraft/lua/rom/help/credits.txt'
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
@@ -254,6 +251,7 @@ sourcesJar {
 | 
			
		||||
 | 
			
		||||
import com.hierynomus.gradle.license.tasks.LicenseCheck
 | 
			
		||||
import com.hierynomus.gradle.license.tasks.LicenseFormat
 | 
			
		||||
import com.modrinth.minotaur.TaskModrinthUpload
 | 
			
		||||
import org.apache.tools.ant.taskdefs.condition.Os
 | 
			
		||||
 | 
			
		||||
List<String> mkCommand(String command) {
 | 
			
		||||
@@ -357,69 +355,49 @@ task licenseFormatAPI(type: LicenseFormat)
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
task setupServer(type: Copy) {
 | 
			
		||||
    group "test server"
 | 
			
		||||
    description "Sets up the environment for the test server."
 | 
			
		||||
tasks.register("testServer", JavaExec.class).configure {
 | 
			
		||||
    it.group('In-game tests')
 | 
			
		||||
    it.description("Runs tests on a temporary Minecraft instance.")
 | 
			
		||||
    it.dependsOn("prepareRunGameTestServer", "cleanTestServer", 'compileTestModJava')
 | 
			
		||||
 | 
			
		||||
    from("src/testMod/server-files") {
 | 
			
		||||
        include "eula.txt"
 | 
			
		||||
        include "server.properties"
 | 
			
		||||
    }
 | 
			
		||||
    into "test-files/server"
 | 
			
		||||
    // Copy from runTestServer. We do it in this slightly odd way as runTestServer
 | 
			
		||||
    // isn't created until the task is configured (which is no good for us).
 | 
			
		||||
    JavaExec exec = tasks.getByName("runGameTestServer")
 | 
			
		||||
    exec.copyTo(it)
 | 
			
		||||
    it.setClasspath(exec.getClasspath())
 | 
			
		||||
    it.mainClass = exec.mainClass
 | 
			
		||||
    it.setArgs(exec.getArgs())
 | 
			
		||||
 | 
			
		||||
    // Jacoco and modlauncher don't play well together as the classes loaded in-game don't
 | 
			
		||||
    // match up with those written to disk. We get Jacoco to dump all classes to disk, and
 | 
			
		||||
    // use that when generating the report.
 | 
			
		||||
    def coverageOut = new File(buildDir, "jacocoClassDump/testServer")
 | 
			
		||||
    jacoco.applyTo(it)
 | 
			
		||||
    it.jacoco.setIncludes(["dan200.computercraft.*"])
 | 
			
		||||
    it.jacoco.setClassDumpDir(coverageOut)
 | 
			
		||||
    it.outputs.dir(coverageOut)
 | 
			
		||||
    // Older versions of modlauncher don't include a protection domain (and thus no code
 | 
			
		||||
    // source). Jacoco skips such classes by default, so we need to explicitly include them.
 | 
			
		||||
    it.jacoco.setIncludeNoLocationClasses(true)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
["Client", "Server"].forEach { name ->
 | 
			
		||||
    tasks.register("test$name", JavaExec.class).configure {
 | 
			
		||||
        it.group('In-game tests')
 | 
			
		||||
        it.description("Runs tests on a temporary Minecraft instance.")
 | 
			
		||||
        it.dependsOn(setupServer, "prepareRunTest$name", "cleanTest$name", 'compileTestModJava')
 | 
			
		||||
tasks.register("jacocoTestServerReport", JacocoReport.class).configure {
 | 
			
		||||
    it.group('In-game')
 | 
			
		||||
    it.description("Generate coverage reports for testServer")
 | 
			
		||||
    it.dependsOn("testServer")
 | 
			
		||||
 | 
			
		||||
        // Copy from runTestServer. We do it in this slightly odd way as runTestServer
 | 
			
		||||
        // isn't created until the task is configured (which is no good for us).
 | 
			
		||||
        JavaExec exec = tasks.getByName("runTest$name")
 | 
			
		||||
        exec.copyTo(it)
 | 
			
		||||
        it.setClasspath(exec.getClasspath())
 | 
			
		||||
        it.mainClass = exec.mainClass
 | 
			
		||||
        it.setArgs(exec.getArgs())
 | 
			
		||||
    it.executionData(new File(buildDir, "jacoco/testServer.exec"))
 | 
			
		||||
    it.sourceDirectories.from(sourceSets.main.allJava.srcDirs)
 | 
			
		||||
    it.classDirectories.from(new File(buildDir, "jacocoClassDump/testServer"))
 | 
			
		||||
 | 
			
		||||
        it.systemProperty('forge.logging.console.level', 'info')
 | 
			
		||||
        it.systemProperty('cctest.run', 'true')
 | 
			
		||||
 | 
			
		||||
        // Jacoco and modlauncher don't play well together as the classes loaded in-game don't
 | 
			
		||||
        // match up with those written to disk. We get Jacoco to dump all classes to disk, and
 | 
			
		||||
        // use that when generating the report.
 | 
			
		||||
        def coverageOut = new File(buildDir, "jacocoClassDump/test$name")
 | 
			
		||||
        jacoco.applyTo(it)
 | 
			
		||||
        it.jacoco.setIncludes(["dan200.computercraft.*"])
 | 
			
		||||
        it.jacoco.setClassDumpDir(coverageOut)
 | 
			
		||||
        it.outputs.dir(coverageOut)
 | 
			
		||||
        // Older versions of modlauncher don't include a protection domain (and thus no code
 | 
			
		||||
        // source). Jacoco skips such classes by default, so we need to explicitly include them.
 | 
			
		||||
        it.jacoco.setIncludeNoLocationClasses(true)
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    tasks.register("jacocoTest${name}Report", JacocoReport.class).configure {
 | 
			
		||||
        it.group('In-game')
 | 
			
		||||
        it.description("Generate coverage reports for test$name")
 | 
			
		||||
        it.dependsOn("test$name")
 | 
			
		||||
 | 
			
		||||
        it.executionData(new File(buildDir, "jacoco/test${name}.exec"))
 | 
			
		||||
        it.sourceDirectories.from(sourceSets.main.allJava.srcDirs)
 | 
			
		||||
        it.classDirectories.from(new File(buildDir, "jacocoClassDump/test$name"))
 | 
			
		||||
 | 
			
		||||
        it.reports {
 | 
			
		||||
            xml.enabled true
 | 
			
		||||
            html.enabled true
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    if (name != "Client" || project.findProperty('cc.tweaked.clientTests') == 'true') {
 | 
			
		||||
        // Don't run client tests unless explicitly opted into them. They're a bit of a faff
 | 
			
		||||
        // to run and pretty flakey.
 | 
			
		||||
        check.dependsOn("jacocoTest${name}Report")
 | 
			
		||||
    it.reports {
 | 
			
		||||
        xml.enabled true
 | 
			
		||||
        html.enabled true
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
check.dependsOn("jacocoTestServerReport")
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
// Upload tasks
 | 
			
		||||
 | 
			
		||||
@@ -463,18 +441,19 @@ task checkRelease {
 | 
			
		||||
}
 | 
			
		||||
check.dependsOn checkRelease
 | 
			
		||||
 | 
			
		||||
def isStable = true
 | 
			
		||||
 | 
			
		||||
curseforge {
 | 
			
		||||
    apiKey = project.hasProperty('curseForgeApiKey') ? project.curseForgeApiKey : ''
 | 
			
		||||
    project {
 | 
			
		||||
        id = '282001'
 | 
			
		||||
        releaseType = 'release'
 | 
			
		||||
        releaseType = isStable ? 'release' : 'alpha'
 | 
			
		||||
        changelog = "Release notes can be found on the GitHub repository (https://github.com/cc-tweaked/CC-Tweaked/releases/tag/v${mc_version}-${mod_version})."
 | 
			
		||||
 | 
			
		||||
        addGameVersion "${mc_version}"
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
import com.modrinth.minotaur.TaskModrinthUpload
 | 
			
		||||
tasks.register('publishModrinth', TaskModrinthUpload.class).configure {
 | 
			
		||||
    dependsOn('assemble', 'reobfJar')
 | 
			
		||||
    onlyIf {
 | 
			
		||||
@@ -485,6 +464,7 @@ tasks.register('publishModrinth', TaskModrinthUpload.class).configure {
 | 
			
		||||
    projectId = 'gu7yAYhd'
 | 
			
		||||
    versionNumber = "${project.mc_version}-${project.mod_version}"
 | 
			
		||||
    uploadFile = jar
 | 
			
		||||
    versionType = isStable ? 'RELEASE' : 'ALPHA'
 | 
			
		||||
    addGameVersion(project.mc_version)
 | 
			
		||||
    changelog = "Release notes can be found on the [GitHub repository](https://github.com/cc-tweaked/CC-Tweaked/releases/tag/v${mc_version}-${mod_version})."
 | 
			
		||||
    addLoader('forge')
 | 
			
		||||
@@ -545,12 +525,17 @@ githubRelease {
 | 
			
		||||
    owner 'cc-tweaked'
 | 
			
		||||
    repo 'CC-Tweaked'
 | 
			
		||||
    targetCommitish.set(project.provider({
 | 
			
		||||
        try {
 | 
			
		||||
            return ["git", "-C", projectDir, "rev-parse", "--abbrev-ref", "HEAD"].execute().text.trim()
 | 
			
		||||
        } catch (Exception e) {
 | 
			
		||||
            e.printStackTrace()
 | 
			
		||||
        def cmd = ["git", "rev-parse", "--abbrev-ref", "HEAD"]
 | 
			
		||||
        println(cmd)
 | 
			
		||||
        def proc = cmd.execute([], projectDir)
 | 
			
		||||
        if (proc.waitFor() != 0) {
 | 
			
		||||
            println(proc.err.text.trim())
 | 
			
		||||
            throw new IllegalStateException("Executed with a non-0 exit code (${proc.exitValue()}).")
 | 
			
		||||
        }
 | 
			
		||||
        return "master"
 | 
			
		||||
 | 
			
		||||
        def branch = proc.text.trim()
 | 
			
		||||
        if (branch == "") throw new IllegalStateException("Cannot determine branch")
 | 
			
		||||
        return branch
 | 
			
		||||
    }))
 | 
			
		||||
 | 
			
		||||
    tagName "v${mc_version}-${mod_version}"
 | 
			
		||||
@@ -561,7 +546,7 @@ githubRelease {
 | 
			
		||||
            .takeWhile { it != 'Type "help changelog" to see the full version history.' }
 | 
			
		||||
            .join("\n").trim()
 | 
			
		||||
    }))
 | 
			
		||||
    prerelease false
 | 
			
		||||
    prerelease !isStable
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def uploadTasks = ["publish", "curseforge", "publishModrinth", "githubRelease"]
 | 
			
		||||
 
 | 
			
		||||
@@ -58,13 +58,20 @@
 | 
			
		||||
        <module name="SimplifyBooleanExpression" />
 | 
			
		||||
        <module name="SimplifyBooleanReturn" />
 | 
			
		||||
        <module name="StringLiteralEquality" />
 | 
			
		||||
        <module name="UnnecessaryParentheses" />
 | 
			
		||||
        <module name="UnnecessaryParentheses">
 | 
			
		||||
            <!-- Default minus LAND. -->
 | 
			
		||||
            <property name="tokens" value="EXPR,IDENT,NUM_DOUBLE,NUM_FLOAT,NUM_INT,NUM_LONG,STRING_LITERAL,LITERAL_NULL,LITERAL_FALSE,LITERAL_TRUE,ASSIGN,BAND_ASSIGN,BOR_ASSIGN,BSR_ASSIGN,BXOR_ASSIGN,DIV_ASSIGN,MINUS_ASSIGN,MOD_ASSIGN,PLUS_ASSIGN,SL_ASSIGN,SR_ASSIGN,STAR_ASSIGN,LAMBDA,TEXT_BLOCK_LITERAL_BEGIN,LITERAL_INSTANCEOF,GT,LT,GE,LE,EQUAL,NOT_EQUAL,UNARY_MINUS,UNARY_PLUS,INC,DEC,LNOT,BNOT,POST_INC,POST_DEC" />
 | 
			
		||||
        </module>
 | 
			
		||||
        <module name="UnnecessarySemicolonAfterTypeMemberDeclaration" />
 | 
			
		||||
        <module name="UnnecessarySemicolonInTryWithResources" />
 | 
			
		||||
        <module name="UnnecessarySemicolonInEnumeration" />
 | 
			
		||||
 | 
			
		||||
        <!-- Imports -->
 | 
			
		||||
        <module name="CustomImportOrder" />
 | 
			
		||||
        <module name="CustomImportOrder">
 | 
			
		||||
            <property name="customImportOrderRules"
 | 
			
		||||
                value="THIRD_PARTY_PACKAGE###STANDARD_JAVA_PACKAGE###STATIC"
 | 
			
		||||
            />
 | 
			
		||||
        </module>
 | 
			
		||||
        <module name="IllegalImport" />
 | 
			
		||||
        <module name="RedundantImport" />
 | 
			
		||||
        <module name="UnusedImports" />
 | 
			
		||||
@@ -154,6 +161,7 @@
 | 
			
		||||
            <property name="allowEmptyLambdas" value="true" />
 | 
			
		||||
            <property name="allowEmptyMethods" value="true" />
 | 
			
		||||
            <property name="allowEmptyConstructors" value="true" />
 | 
			
		||||
            <property name="allowEmptyTypes" value="true" />
 | 
			
		||||
 | 
			
		||||
            <property name="tokens" value="ASSIGN,BAND,BAND_ASSIGN,BOR,BOR_ASSIGN,BSR,BSR_ASSIGN,BXOR,BXOR_ASSIGN,COLON,DIV,DIV_ASSIGN,EQUAL,GE,GT,LAMBDA,LAND,LCURLY,LE,LITERAL_RETURN,LOR,LT,MINUS,MINUS_ASSIGN,MOD,MOD_ASSIGN,NOT_EQUAL,PLUS,PLUS_ASSIGN,QUESTION,RCURLY,SL,SLIST,SL_ASSIGN,SR,SR_ASSIGN,STAR,STAR_ASSIGN,LITERAL_ASSERT,TYPE_EXTENSION_AND" />
 | 
			
		||||
        </module>
 | 
			
		||||
 
 | 
			
		||||
@@ -3,6 +3,6 @@ FROM gitpod/workspace-base
 | 
			
		||||
USER gitpod
 | 
			
		||||
 | 
			
		||||
RUN sudo apt-get -q update \
 | 
			
		||||
 && sudo apt-get install -yq openjdk-8-jdk openjdk-16-jdk python3-pip npm \
 | 
			
		||||
 && sudo apt-get install -yq openjdk-16-jdk python3-pip npm \
 | 
			
		||||
 && sudo pip3 install pre-commit \
 | 
			
		||||
 && sudo update-java-alternatives --set java-1.8.0-openjdk-amd64
 | 
			
		||||
 && sudo update-java-alternatives --set java-1.16.0-openjdk-amd64
 | 
			
		||||
 
 | 
			
		||||
@@ -19,8 +19,8 @@ numerical value depending on which button on your mouse was last pressed when th
 | 
			
		||||
    <!-- Our markdown parser doesn't work on tables!? Guess I'll have to roll my own soonish :/. -->
 | 
			
		||||
    <tr><th>Button code</th><th>Mouse button</th></tr>
 | 
			
		||||
    <tr><td align="right">1</td><td>Left button</td></tr>
 | 
			
		||||
    <tr><td align="right">2</td><td>Middle button</td></tr>
 | 
			
		||||
    <tr><td align="right">3</td><td>Right button</td></tr>
 | 
			
		||||
    <tr><td align="right">2</td><td>Right button</td></tr>
 | 
			
		||||
    <tr><td align="right">3</td><td>Middle button</td></tr>
 | 
			
		||||
</table>
 | 
			
		||||
 | 
			
		||||
## Example
 | 
			
		||||
 
 | 
			
		||||
@@ -2,7 +2,12 @@
 | 
			
		||||
module: [kind=event] term_resize
 | 
			
		||||
---
 | 
			
		||||
 | 
			
		||||
The @{term_resize} event is fired when the main terminal is resized, mainly when a new tab is opened or closed in @{multishell}.
 | 
			
		||||
The @{term_resize} event is fired when the main terminal is resized. For instance:
 | 
			
		||||
 - When a the tab bar is shown or hidden in @{multishell}.
 | 
			
		||||
 - When the terminal is redirected to a monitor via the "monitor" program and the monitor is resized.
 | 
			
		||||
 | 
			
		||||
When this event fires, some parts of the terminal may have been moved or deleted. Simple terminal programs (those
 | 
			
		||||
not using @{term.setCursorPos}) can ignore this event, but more complex GUI programs should redraw the entire screen.
 | 
			
		||||
 | 
			
		||||
## Example
 | 
			
		||||
Prints :
 | 
			
		||||
 
 | 
			
		||||
@@ -18,7 +18,7 @@ representable value.
 | 
			
		||||
 | 
			
		||||
This representation of sound - a long, uniformally sampled list of amplitudes is referred to as [Pulse-code
 | 
			
		||||
Modulation][PCM] (PCM). PCM can be thought of as the "standard" audio format, as it's incredibly easy to work with. For
 | 
			
		||||
instance, to mix two pieces of audio together, you can just samples from the two tracks together and take the average.
 | 
			
		||||
instance, to mix two pieces of audio together, you can just add samples from the two tracks together and take the average.
 | 
			
		||||
 | 
			
		||||
CC: Tweaked's speakers also work with PCM audio. It plays back 48,000 samples a second, where each sample is an integer
 | 
			
		||||
between -128 and 127. This is more commonly referred to as 48kHz and an 8-bit resolution.
 | 
			
		||||
 
 | 
			
		||||
@@ -1,8 +1,10 @@
 | 
			
		||||
org.gradle.jvmargs=-Xmx3G
 | 
			
		||||
 | 
			
		||||
# Mod properties
 | 
			
		||||
mod_version=1.100.0
 | 
			
		||||
mod_version=1.100.5
 | 
			
		||||
 | 
			
		||||
# Minecraft properties (update mods.toml when changing)
 | 
			
		||||
mc_version=1.16.5
 | 
			
		||||
mapping_version=2021.08.08
 | 
			
		||||
forge_version=36.2.20
 | 
			
		||||
mc_version=1.18.2
 | 
			
		||||
mapping_version=2022.03.13
 | 
			
		||||
forge_version=40.1.0
 | 
			
		||||
# NO SERIOUSLY, UPDATE mods.toml WHEN CHANGING
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:redstone"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:redstone"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:gold_ingot"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:gold_ingot"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:command_block"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:command_block"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:disk_drive"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:disk_drive"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:speaker"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:speaker"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -21,7 +21,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:golden_apple"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:golden_apple"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -21,7 +21,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:golden_apple"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:golden_apple"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:speaker"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:speaker"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:pocket_computer_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:pocket_computer_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:printer"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:printer"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:printer"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:printer"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:speaker"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:speaker"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:crafting_table"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:crafting_table"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_axe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_axe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_hoe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_hoe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_pickaxe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_pickaxe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_shovel"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_shovel"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_sword"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_sword"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:speaker"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:speaker"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:crafting_table"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:crafting_table"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_axe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_axe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_hoe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_hoe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_pickaxe"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_pickaxe"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_shovel"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_shovel"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,14 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:turtle_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:turtle_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          },
 | 
			
		||||
          {
 | 
			
		||||
            "item": "minecraft:diamond_sword"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "minecraft:diamond_sword"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -21,7 +21,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:cable"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:cable"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -21,7 +21,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:wireless_modem_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:monitor_normal"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:monitor_normal"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
@@ -11,7 +11,9 @@
 | 
			
		||||
      "conditions": {
 | 
			
		||||
        "items": [
 | 
			
		||||
          {
 | 
			
		||||
            "item": "computercraft:computer_advanced"
 | 
			
		||||
            "items": [
 | 
			
		||||
              "computercraft:computer_advanced"
 | 
			
		||||
            ]
 | 
			
		||||
          }
 | 
			
		||||
        ]
 | 
			
		||||
      }
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										4
									
								
								src/generated/resources/data/computercraft/computercraft/pocket_upgrades/speaker.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								src/generated/resources/data/computercraft/computercraft/pocket_upgrades/speaker.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:speaker",
 | 
			
		||||
  "item": "computercraft:speaker"
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:wireless_modem_advanced",
 | 
			
		||||
  "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:wireless_modem_normal",
 | 
			
		||||
  "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										4
									
								
								src/generated/resources/data/computercraft/computercraft/turtle_upgrades/speaker.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								src/generated/resources/data/computercraft/computercraft/turtle_upgrades/speaker.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:speaker",
 | 
			
		||||
  "item": "computercraft:speaker"
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:wireless_modem_advanced",
 | 
			
		||||
  "item": "computercraft:wireless_modem_advanced"
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:wireless_modem_normal",
 | 
			
		||||
  "item": "computercraft:wireless_modem_normal"
 | 
			
		||||
}
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "cable",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
@@ -25,7 +26,8 @@
 | 
			
		||||
    },
 | 
			
		||||
    {
 | 
			
		||||
      "name": "wired_modem",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:dynamic",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:dynamic",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:dynamic",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:dynamic",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:dynamic",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,8 @@
 | 
			
		||||
  "pools": [
 | 
			
		||||
    {
 | 
			
		||||
      "name": "main",
 | 
			
		||||
      "rolls": 1,
 | 
			
		||||
      "rolls": 1.0,
 | 
			
		||||
      "bonus_rolls": 0.0,
 | 
			
		||||
      "entries": [
 | 
			
		||||
        {
 | 
			
		||||
          "type": "minecraft:item",
 | 
			
		||||
 
 | 
			
		||||
@@ -2,6 +2,7 @@
 | 
			
		||||
  "replace": false,
 | 
			
		||||
  "values": [
 | 
			
		||||
    "#minecraft:crops",
 | 
			
		||||
    "#minecraft:mineable/hoe",
 | 
			
		||||
    "minecraft:cactus",
 | 
			
		||||
    "minecraft:melon",
 | 
			
		||||
    "minecraft:pumpkin",
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,7 @@
 | 
			
		||||
{
 | 
			
		||||
  "replace": false,
 | 
			
		||||
  "values": [
 | 
			
		||||
    "#minecraft:mineable/shovel",
 | 
			
		||||
    "minecraft:melon",
 | 
			
		||||
    "minecraft:pumpkin",
 | 
			
		||||
    "minecraft:carved_pumpkin",
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										4
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/crafting_table.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/crafting_table.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:workbench",
 | 
			
		||||
  "item": "minecraft:crafting_table"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_axe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_axe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,5 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:tool",
 | 
			
		||||
  "item": "minecraft:diamond_axe",
 | 
			
		||||
  "damageMultiplier": 6.0
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_hoe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_hoe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,5 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:tool",
 | 
			
		||||
  "item": "minecraft:diamond_hoe",
 | 
			
		||||
  "breakable": "computercraft:turtle_hoe_harvestable"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										4
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_pickaxe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_pickaxe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,4 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:tool",
 | 
			
		||||
  "item": "minecraft:diamond_pickaxe"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_shovel.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_shovel.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,5 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:tool",
 | 
			
		||||
  "item": "minecraft:diamond_shovel",
 | 
			
		||||
  "breakable": "computercraft:turtle_shovel_harvestable"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										6
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_sword.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								src/generated/resources/data/minecraft/computercraft/turtle_upgrades/diamond_sword.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,6 @@
 | 
			
		||||
{
 | 
			
		||||
  "type": "computercraft:tool",
 | 
			
		||||
  "item": "minecraft:diamond_sword",
 | 
			
		||||
  "damageMultiplier": 9.0,
 | 
			
		||||
  "breakable": "computercraft:turtle_sword_harvestable"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json
									
									
									
										generated
									
									
									
										Normal file
									
								
							@@ -0,0 +1,18 @@
 | 
			
		||||
{
 | 
			
		||||
  "replace": false,
 | 
			
		||||
  "values": [
 | 
			
		||||
    "computercraft:computer_normal",
 | 
			
		||||
    "computercraft:computer_advanced",
 | 
			
		||||
    "computercraft:turtle_normal",
 | 
			
		||||
    "computercraft:turtle_advanced",
 | 
			
		||||
    "computercraft:speaker",
 | 
			
		||||
    "computercraft:disk_drive",
 | 
			
		||||
    "computercraft:printer",
 | 
			
		||||
    "computercraft:monitor_normal",
 | 
			
		||||
    "computercraft:monitor_advanced",
 | 
			
		||||
    "computercraft:wireless_modem_normal",
 | 
			
		||||
    "computercraft:wireless_modem_advanced",
 | 
			
		||||
    "computercraft:wired_modem_full",
 | 
			
		||||
    "computercraft:cable"
 | 
			
		||||
  ]
 | 
			
		||||
}
 | 
			
		||||
@@ -1,11 +1,10 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of ComputerCraft - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. Do not distribute without permission.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. Do not distribute without permission.
 | 
			
		||||
 * Send enquiries to dratcliffe@gmail.com
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft;
 | 
			
		||||
 | 
			
		||||
import dan200.computercraft.api.turtle.event.TurtleAction;
 | 
			
		||||
import dan200.computercraft.core.apis.http.options.Action;
 | 
			
		||||
import dan200.computercraft.core.apis.http.options.AddressRule;
 | 
			
		||||
import dan200.computercraft.shared.Config;
 | 
			
		||||
@@ -13,16 +12,10 @@ import dan200.computercraft.shared.Registry;
 | 
			
		||||
import dan200.computercraft.shared.computer.core.ClientComputerRegistry;
 | 
			
		||||
import dan200.computercraft.shared.computer.core.ServerComputerRegistry;
 | 
			
		||||
import dan200.computercraft.shared.peripheral.monitor.MonitorRenderer;
 | 
			
		||||
import dan200.computercraft.shared.pocket.peripherals.PocketModem;
 | 
			
		||||
import dan200.computercraft.shared.pocket.peripherals.PocketSpeaker;
 | 
			
		||||
import dan200.computercraft.shared.turtle.upgrades.*;
 | 
			
		||||
import net.minecraftforge.fml.common.Mod;
 | 
			
		||||
import org.apache.logging.log4j.LogManager;
 | 
			
		||||
import org.apache.logging.log4j.Logger;
 | 
			
		||||
 | 
			
		||||
import java.util.Arrays;
 | 
			
		||||
import java.util.Collections;
 | 
			
		||||
import java.util.EnumSet;
 | 
			
		||||
import java.util.List;
 | 
			
		||||
import java.util.concurrent.TimeUnit;
 | 
			
		||||
 | 
			
		||||
@@ -45,10 +38,10 @@ public final class ComputerCraft
 | 
			
		||||
 | 
			
		||||
    public static boolean httpEnabled = true;
 | 
			
		||||
    public static boolean httpWebsocketEnabled = true;
 | 
			
		||||
    public static List<AddressRule> httpRules = Collections.unmodifiableList( Arrays.asList(
 | 
			
		||||
    public static List<AddressRule> httpRules = List.of(
 | 
			
		||||
        AddressRule.parse( "$private", null, Action.DENY.toPartial() ),
 | 
			
		||||
        AddressRule.parse( "*", null, Action.ALLOW.toPartial() )
 | 
			
		||||
    ) );
 | 
			
		||||
    );
 | 
			
		||||
 | 
			
		||||
    public static int httpMaxRequests = 16;
 | 
			
		||||
    public static int httpMaxWebsockets = 4;
 | 
			
		||||
@@ -62,7 +55,7 @@ public final class ComputerCraft
 | 
			
		||||
    public static int modemHighAltitudeRangeDuringStorm = 384;
 | 
			
		||||
    public static int maxNotesPerTick = 8;
 | 
			
		||||
    public static MonitorRenderer monitorRenderer = MonitorRenderer.BEST;
 | 
			
		||||
    public static double monitorDistanceSq = 4096;
 | 
			
		||||
    public static int monitorDistance = 65;
 | 
			
		||||
    public static long monitorBandwidth = 1_000_000;
 | 
			
		||||
 | 
			
		||||
    public static boolean turtlesNeedFuel = true;
 | 
			
		||||
@@ -70,7 +63,6 @@ public final class ComputerCraft
 | 
			
		||||
    public static int advancedTurtleFuelLimit = 100000;
 | 
			
		||||
    public static boolean turtlesObeyBlockProtection = true;
 | 
			
		||||
    public static boolean turtlesCanPush = true;
 | 
			
		||||
    public static EnumSet<TurtleAction> turtleDisabledActions = EnumSet.noneOf( TurtleAction.class );
 | 
			
		||||
 | 
			
		||||
    public static int computerTermWidth = 51;
 | 
			
		||||
    public static int computerTermHeight = 19;
 | 
			
		||||
@@ -84,27 +76,6 @@ public final class ComputerCraft
 | 
			
		||||
    public static int monitorWidth = 8;
 | 
			
		||||
    public static int monitorHeight = 6;
 | 
			
		||||
 | 
			
		||||
    public static final class TurtleUpgrades
 | 
			
		||||
    {
 | 
			
		||||
        public static TurtleModem wirelessModemNormal;
 | 
			
		||||
        public static TurtleModem wirelessModemAdvanced;
 | 
			
		||||
        public static TurtleSpeaker speaker;
 | 
			
		||||
 | 
			
		||||
        public static TurtleCraftingTable craftingTable;
 | 
			
		||||
        public static TurtleSword diamondSword;
 | 
			
		||||
        public static TurtleShovel diamondShovel;
 | 
			
		||||
        public static TurtleTool diamondPickaxe;
 | 
			
		||||
        public static TurtleAxe diamondAxe;
 | 
			
		||||
        public static TurtleHoe diamondHoe;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public static final class PocketUpgrades
 | 
			
		||||
    {
 | 
			
		||||
        public static PocketModem wirelessModemNormal;
 | 
			
		||||
        public static PocketModem wirelessModemAdvanced;
 | 
			
		||||
        public static PocketSpeaker speaker;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    // Registries
 | 
			
		||||
    public static final ClientComputerRegistry clientComputerRegistry = new ClientComputerRegistry();
 | 
			
		||||
    public static final ServerComputerRegistry serverComputerRegistry = new ServerComputerRegistry();
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of ComputerCraft - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. Do not distribute without permission.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. Do not distribute without permission.
 | 
			
		||||
 * Send enquiries to dratcliffe@gmail.com
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft;
 | 
			
		||||
@@ -15,30 +15,29 @@ import dan200.computercraft.api.network.IPacketNetwork;
 | 
			
		||||
import dan200.computercraft.api.network.wired.IWiredElement;
 | 
			
		||||
import dan200.computercraft.api.network.wired.IWiredNode;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IPeripheralProvider;
 | 
			
		||||
import dan200.computercraft.api.pocket.IPocketUpgrade;
 | 
			
		||||
import dan200.computercraft.api.redstone.IBundledRedstoneProvider;
 | 
			
		||||
import dan200.computercraft.api.turtle.ITurtleUpgrade;
 | 
			
		||||
import dan200.computercraft.core.apis.ApiFactories;
 | 
			
		||||
import dan200.computercraft.core.asm.GenericMethod;
 | 
			
		||||
import dan200.computercraft.core.filesystem.FileMount;
 | 
			
		||||
import dan200.computercraft.core.filesystem.ResourceMount;
 | 
			
		||||
import dan200.computercraft.shared.*;
 | 
			
		||||
import dan200.computercraft.shared.BundledRedstone;
 | 
			
		||||
import dan200.computercraft.shared.MediaProviders;
 | 
			
		||||
import dan200.computercraft.shared.Peripherals;
 | 
			
		||||
import dan200.computercraft.shared.peripheral.generic.GenericPeripheralProvider;
 | 
			
		||||
import dan200.computercraft.shared.peripheral.modem.wireless.WirelessNetwork;
 | 
			
		||||
import dan200.computercraft.shared.util.IDAssigner;
 | 
			
		||||
import dan200.computercraft.shared.wired.WiredNode;
 | 
			
		||||
import net.minecraft.resources.IReloadableResourceManager;
 | 
			
		||||
import net.minecraft.resources.IResourceManager;
 | 
			
		||||
import net.minecraft.tileentity.TileEntity;
 | 
			
		||||
import net.minecraft.util.Direction;
 | 
			
		||||
import net.minecraft.util.ResourceLocation;
 | 
			
		||||
import net.minecraft.util.math.BlockPos;
 | 
			
		||||
import net.minecraft.world.IBlockReader;
 | 
			
		||||
import net.minecraft.world.World;
 | 
			
		||||
import net.minecraft.core.BlockPos;
 | 
			
		||||
import net.minecraft.core.Direction;
 | 
			
		||||
import net.minecraft.resources.ResourceLocation;
 | 
			
		||||
import net.minecraft.server.packs.resources.ResourceManager;
 | 
			
		||||
import net.minecraft.world.level.BlockGetter;
 | 
			
		||||
import net.minecraft.world.level.Level;
 | 
			
		||||
import net.minecraft.world.level.block.entity.BlockEntity;
 | 
			
		||||
import net.minecraftforge.common.capabilities.Capability;
 | 
			
		||||
import net.minecraftforge.common.util.LazyOptional;
 | 
			
		||||
import net.minecraftforge.fml.ModList;
 | 
			
		||||
import net.minecraftforge.fml.server.ServerLifecycleHooks;
 | 
			
		||||
import net.minecraftforge.server.ServerLifecycleHooks;
 | 
			
		||||
 | 
			
		||||
import javax.annotation.Nonnull;
 | 
			
		||||
import java.io.File;
 | 
			
		||||
@@ -59,7 +58,7 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
 | 
			
		||||
    public static InputStream getResourceFile( String domain, String subPath )
 | 
			
		||||
    {
 | 
			
		||||
        IReloadableResourceManager manager = (IReloadableResourceManager) ServerLifecycleHooks.getCurrentServer().getDataPackRegistries().getResourceManager();
 | 
			
		||||
        var manager = ServerLifecycleHooks.getCurrentServer().getResourceManager();
 | 
			
		||||
        try
 | 
			
		||||
        {
 | 
			
		||||
            return manager.getResource( new ResourceLocation( domain, subPath ) ).getInputStream();
 | 
			
		||||
@@ -81,13 +80,13 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public int createUniqueNumberedSaveDir( @Nonnull World world, @Nonnull String parentSubPath )
 | 
			
		||||
    public int createUniqueNumberedSaveDir( @Nonnull Level world, @Nonnull String parentSubPath )
 | 
			
		||||
    {
 | 
			
		||||
        return IDAssigner.getNextId( parentSubPath );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public IWritableMount createSaveDirMount( @Nonnull World world, @Nonnull String subPath, long capacity )
 | 
			
		||||
    public IWritableMount createSaveDirMount( @Nonnull Level world, @Nonnull String subPath, long capacity )
 | 
			
		||||
    {
 | 
			
		||||
        try
 | 
			
		||||
        {
 | 
			
		||||
@@ -102,7 +101,7 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
    @Override
 | 
			
		||||
    public IMount createResourceMount( @Nonnull String domain, @Nonnull String subPath )
 | 
			
		||||
    {
 | 
			
		||||
        IResourceManager manager = ServerLifecycleHooks.getCurrentServer().getDataPackRegistries().getResourceManager();
 | 
			
		||||
        ResourceManager manager = ServerLifecycleHooks.getCurrentServer().getResourceManager();
 | 
			
		||||
        ResourceMount mount = ResourceMount.get( domain, subPath, manager );
 | 
			
		||||
        return mount.exists( "" ) ? mount : null;
 | 
			
		||||
    }
 | 
			
		||||
@@ -125,12 +124,6 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
        GenericPeripheralProvider.addCapability( capability );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void registerTurtleUpgrade( @Nonnull ITurtleUpgrade upgrade )
 | 
			
		||||
    {
 | 
			
		||||
        TurtleUpgrades.register( upgrade );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void registerBundledRedstoneProvider( @Nonnull IBundledRedstoneProvider provider )
 | 
			
		||||
    {
 | 
			
		||||
@@ -138,7 +131,7 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public int getBundledRedstoneOutput( @Nonnull World world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    public int getBundledRedstoneOutput( @Nonnull Level world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    {
 | 
			
		||||
        return BundledRedstone.getDefaultOutput( world, pos, side );
 | 
			
		||||
    }
 | 
			
		||||
@@ -149,12 +142,6 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
        MediaProviders.register( provider );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void registerPocketUpgrade( @Nonnull IPocketUpgrade upgrade )
 | 
			
		||||
    {
 | 
			
		||||
        PocketUpgrades.register( upgrade );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    @Override
 | 
			
		||||
    public IPacketNetwork getWirelessNetwork()
 | 
			
		||||
@@ -177,9 +164,9 @@ public final class ComputerCraftAPIImpl implements IComputerCraftAPI
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    @Override
 | 
			
		||||
    public LazyOptional<IWiredElement> getWiredElementAt( @Nonnull IBlockReader world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    public LazyOptional<IWiredElement> getWiredElementAt( @Nonnull BlockGetter world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    {
 | 
			
		||||
        TileEntity tile = world.getBlockEntity( pos );
 | 
			
		||||
        BlockEntity tile = world.getBlockEntity( pos );
 | 
			
		||||
        return tile == null ? LazyOptional.empty() : tile.getCapability( CAPABILITY_WIRED_ELEMENT, side );
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api;
 | 
			
		||||
@@ -17,13 +17,11 @@ import dan200.computercraft.api.network.wired.IWiredNode;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IComputerAccess;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IPeripheral;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IPeripheralProvider;
 | 
			
		||||
import dan200.computercraft.api.pocket.IPocketUpgrade;
 | 
			
		||||
import dan200.computercraft.api.redstone.IBundledRedstoneProvider;
 | 
			
		||||
import dan200.computercraft.api.turtle.ITurtleUpgrade;
 | 
			
		||||
import net.minecraft.util.Direction;
 | 
			
		||||
import net.minecraft.util.math.BlockPos;
 | 
			
		||||
import net.minecraft.world.IBlockReader;
 | 
			
		||||
import net.minecraft.world.World;
 | 
			
		||||
import net.minecraft.core.BlockPos;
 | 
			
		||||
import net.minecraft.core.Direction;
 | 
			
		||||
import net.minecraft.world.level.BlockGetter;
 | 
			
		||||
import net.minecraft.world.level.Level;
 | 
			
		||||
import net.minecraftforge.common.capabilities.Capability;
 | 
			
		||||
import net.minecraftforge.common.util.LazyOptional;
 | 
			
		||||
 | 
			
		||||
@@ -38,19 +36,14 @@ import javax.annotation.Nullable;
 | 
			
		||||
 */
 | 
			
		||||
public final class ComputerCraftAPI
 | 
			
		||||
{
 | 
			
		||||
    public static final String MOD_ID = "computercraft";
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    public static String getInstalledVersion()
 | 
			
		||||
    {
 | 
			
		||||
        return getInstance().getInstalledVersion();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    @Deprecated
 | 
			
		||||
    public static String getAPIVersion()
 | 
			
		||||
    {
 | 
			
		||||
        return getInstalledVersion();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Creates a numbered directory in a subfolder of the save directory for a given world, and returns that number.
 | 
			
		||||
     *
 | 
			
		||||
@@ -62,9 +55,9 @@ public final class ComputerCraftAPI
 | 
			
		||||
     *
 | 
			
		||||
     * eg: if createUniqueNumberedSaveDir( world, "computer/disk" ) was called returns 42, then "computer/disk/42" is now
 | 
			
		||||
     * available for writing.
 | 
			
		||||
     * @see #createSaveDirMount(World, String, long)
 | 
			
		||||
     * @see #createSaveDirMount(Level, String, long)
 | 
			
		||||
     */
 | 
			
		||||
    public static int createUniqueNumberedSaveDir( @Nonnull World world, @Nonnull String parentSubPath )
 | 
			
		||||
    public static int createUniqueNumberedSaveDir( @Nonnull Level world, @Nonnull String parentSubPath )
 | 
			
		||||
    {
 | 
			
		||||
        return getInstance().createUniqueNumberedSaveDir( world, parentSubPath );
 | 
			
		||||
    }
 | 
			
		||||
@@ -81,14 +74,14 @@ public final class ComputerCraftAPI
 | 
			
		||||
     * @param capacity The amount of data that can be stored in the directory before it fills up, in bytes.
 | 
			
		||||
     * @return The mount, or null if it could be created for some reason. Use IComputerAccess.mount() or IComputerAccess.mountWritable()
 | 
			
		||||
     * to mount this on a Computers' file system.
 | 
			
		||||
     * @see #createUniqueNumberedSaveDir(World, String)
 | 
			
		||||
     * @see #createUniqueNumberedSaveDir(Level, String)
 | 
			
		||||
     * @see IComputerAccess#mount(String, IMount)
 | 
			
		||||
     * @see IComputerAccess#mountWritable(String, IWritableMount)
 | 
			
		||||
     * @see IMount
 | 
			
		||||
     * @see IWritableMount
 | 
			
		||||
     */
 | 
			
		||||
    @Nullable
 | 
			
		||||
    public static IWritableMount createSaveDirMount( @Nonnull World world, @Nonnull String subPath, long capacity )
 | 
			
		||||
    public static IWritableMount createSaveDirMount( @Nonnull Level world, @Nonnull String subPath, long capacity )
 | 
			
		||||
    {
 | 
			
		||||
        return getInstance().createSaveDirMount( world, subPath, capacity );
 | 
			
		||||
    }
 | 
			
		||||
@@ -118,7 +111,7 @@ public final class ComputerCraftAPI
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * rers a peripheral provider to convert blocks into {@link IPeripheral} implementations.
 | 
			
		||||
     * Registers a peripheral provider to convert blocks into {@link IPeripheral} implementations.
 | 
			
		||||
     *
 | 
			
		||||
     * @param provider The peripheral provider to register.
 | 
			
		||||
     * @see IPeripheral
 | 
			
		||||
@@ -151,19 +144,6 @@ public final class ComputerCraftAPI
 | 
			
		||||
        getInstance().registerGenericCapability( capability );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Registers a new turtle turtle for use in ComputerCraft. After calling this,
 | 
			
		||||
     * users should be able to craft Turtles with your new turtle. It is recommended to call
 | 
			
		||||
     * this during the load() method of your mod.
 | 
			
		||||
     *
 | 
			
		||||
     * @param upgrade The turtle upgrade to register.
 | 
			
		||||
     * @see ITurtleUpgrade
 | 
			
		||||
     */
 | 
			
		||||
    public static void registerTurtleUpgrade( @Nonnull ITurtleUpgrade upgrade )
 | 
			
		||||
    {
 | 
			
		||||
        getInstance().registerTurtleUpgrade( upgrade );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Registers a bundled redstone provider to provide bundled redstone output for blocks.
 | 
			
		||||
     *
 | 
			
		||||
@@ -185,7 +165,7 @@ public final class ComputerCraftAPI
 | 
			
		||||
     * If there is no block capable of emitting bundled redstone at the location, -1 will be returned.
 | 
			
		||||
     * @see IBundledRedstoneProvider
 | 
			
		||||
     */
 | 
			
		||||
    public static int getBundledRedstoneOutput( @Nonnull World world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    public static int getBundledRedstoneOutput( @Nonnull Level world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    {
 | 
			
		||||
        return getInstance().getBundledRedstoneOutput( world, pos, side );
 | 
			
		||||
    }
 | 
			
		||||
@@ -201,11 +181,6 @@ public final class ComputerCraftAPI
 | 
			
		||||
        getInstance().registerMediaProvider( provider );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public static void registerPocketUpgrade( @Nonnull IPocketUpgrade upgrade )
 | 
			
		||||
    {
 | 
			
		||||
        getInstance().registerPocketUpgrade( upgrade );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Attempt to get the game-wide wireless network.
 | 
			
		||||
     *
 | 
			
		||||
@@ -244,7 +219,7 @@ public final class ComputerCraftAPI
 | 
			
		||||
     * @see IWiredElement#getNode()
 | 
			
		||||
     */
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    public static LazyOptional<IWiredElement> getWiredElementAt( @Nonnull IBlockReader world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    public static LazyOptional<IWiredElement> getWiredElementAt( @Nonnull BlockGetter world, @Nonnull BlockPos pos, @Nonnull Direction side )
 | 
			
		||||
    {
 | 
			
		||||
        return getInstance().getWiredElementAt( world, pos, side );
 | 
			
		||||
    }
 | 
			
		||||
@@ -272,10 +247,10 @@ public final class ComputerCraftAPI
 | 
			
		||||
        @Nonnull
 | 
			
		||||
        String getInstalledVersion();
 | 
			
		||||
 | 
			
		||||
        int createUniqueNumberedSaveDir( @Nonnull World world, @Nonnull String parentSubPath );
 | 
			
		||||
        int createUniqueNumberedSaveDir( @Nonnull Level world, @Nonnull String parentSubPath );
 | 
			
		||||
 | 
			
		||||
        @Nullable
 | 
			
		||||
        IWritableMount createSaveDirMount( @Nonnull World world, @Nonnull String subPath, long capacity );
 | 
			
		||||
        IWritableMount createSaveDirMount( @Nonnull Level world, @Nonnull String subPath, long capacity );
 | 
			
		||||
 | 
			
		||||
        @Nullable
 | 
			
		||||
        IMount createResourceMount( @Nonnull String domain, @Nonnull String subPath );
 | 
			
		||||
@@ -286,16 +261,12 @@ public final class ComputerCraftAPI
 | 
			
		||||
 | 
			
		||||
        void registerGenericCapability( @Nonnull Capability<?> capability );
 | 
			
		||||
 | 
			
		||||
        void registerTurtleUpgrade( @Nonnull ITurtleUpgrade upgrade );
 | 
			
		||||
 | 
			
		||||
        void registerBundledRedstoneProvider( @Nonnull IBundledRedstoneProvider provider );
 | 
			
		||||
 | 
			
		||||
        int getBundledRedstoneOutput( @Nonnull World world, @Nonnull BlockPos pos, @Nonnull Direction side );
 | 
			
		||||
        int getBundledRedstoneOutput( @Nonnull Level world, @Nonnull BlockPos pos, @Nonnull Direction side );
 | 
			
		||||
 | 
			
		||||
        void registerMediaProvider( @Nonnull IMediaProvider provider );
 | 
			
		||||
 | 
			
		||||
        void registerPocketUpgrade( @Nonnull IPocketUpgrade upgrade );
 | 
			
		||||
 | 
			
		||||
        @Nonnull
 | 
			
		||||
        IPacketNetwork getWirelessNetwork();
 | 
			
		||||
 | 
			
		||||
@@ -305,6 +276,6 @@ public final class ComputerCraftAPI
 | 
			
		||||
        IWiredNode createWiredNodeForElement( @Nonnull IWiredElement element );
 | 
			
		||||
 | 
			
		||||
        @Nonnull
 | 
			
		||||
        LazyOptional<IWiredElement> getWiredElementAt( @Nonnull IBlockReader world, @Nonnull BlockPos pos, @Nonnull Direction side );
 | 
			
		||||
        LazyOptional<IWiredElement> getWiredElementAt( @Nonnull BlockGetter world, @Nonnull BlockPos pos, @Nonnull Direction side );
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -0,0 +1,66 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api;
 | 
			
		||||
 | 
			
		||||
import dan200.computercraft.ComputerCraft;
 | 
			
		||||
import net.minecraft.resources.ResourceLocation;
 | 
			
		||||
import net.minecraft.tags.BlockTags;
 | 
			
		||||
import net.minecraft.tags.ItemTags;
 | 
			
		||||
import net.minecraft.tags.TagKey;
 | 
			
		||||
import net.minecraft.world.item.Item;
 | 
			
		||||
import net.minecraft.world.level.block.Block;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Tags provided by ComputerCraft.
 | 
			
		||||
 */
 | 
			
		||||
public class ComputerCraftTags
 | 
			
		||||
{
 | 
			
		||||
    public static class Items
 | 
			
		||||
    {
 | 
			
		||||
        public static final TagKey<Item> COMPUTER = make( "computer" );
 | 
			
		||||
        public static final TagKey<Item> TURTLE = make( "turtle" );
 | 
			
		||||
        public static final TagKey<Item> WIRED_MODEM = make( "wired_modem" );
 | 
			
		||||
        public static final TagKey<Item> MONITOR = make( "monitor" );
 | 
			
		||||
 | 
			
		||||
        private static TagKey<Item> make( String name )
 | 
			
		||||
        {
 | 
			
		||||
            return ItemTags.create( new ResourceLocation( ComputerCraft.MOD_ID, name ) );
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public static class Blocks
 | 
			
		||||
    {
 | 
			
		||||
        public static final TagKey<Block> COMPUTER = make( "computer" );
 | 
			
		||||
        public static final TagKey<Block> TURTLE = make( "turtle" );
 | 
			
		||||
        public static final TagKey<Block> WIRED_MODEM = make( "wired_modem" );
 | 
			
		||||
        public static final TagKey<Block> MONITOR = make( "monitor" );
 | 
			
		||||
 | 
			
		||||
        /**
 | 
			
		||||
         * Blocks which can be broken by any turtle tool.
 | 
			
		||||
         */
 | 
			
		||||
        public static final TagKey<Block> TURTLE_ALWAYS_BREAKABLE = make( "turtle_always_breakable" );
 | 
			
		||||
 | 
			
		||||
        /**
 | 
			
		||||
         * Blocks which can be broken by the default shovel tool.
 | 
			
		||||
         */
 | 
			
		||||
        public static final TagKey<Block> TURTLE_SHOVEL_BREAKABLE = make( "turtle_shovel_harvestable" );
 | 
			
		||||
 | 
			
		||||
        /**
 | 
			
		||||
         * Blocks which can be broken with the default sword tool.
 | 
			
		||||
         */
 | 
			
		||||
        public static final TagKey<Block> TURTLE_SWORD_BREAKABLE = make( "turtle_sword_harvestable" );
 | 
			
		||||
 | 
			
		||||
        /**
 | 
			
		||||
         * Blocks which can be broken with the default hoe tool.
 | 
			
		||||
         */
 | 
			
		||||
        public static final TagKey<Block> TURTLE_HOE_BREAKABLE = make( "turtle_hoe_harvestable" );
 | 
			
		||||
 | 
			
		||||
        private static TagKey<Block> make( String name )
 | 
			
		||||
        {
 | 
			
		||||
            return BlockTags.create( new ResourceLocation( ComputerCraft.MOD_ID, name ) );
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
@@ -1,16 +1,16 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.client;
 | 
			
		||||
 | 
			
		||||
import com.mojang.math.Transformation;
 | 
			
		||||
import net.minecraft.client.Minecraft;
 | 
			
		||||
import net.minecraft.client.renderer.model.IBakedModel;
 | 
			
		||||
import net.minecraft.client.renderer.model.ModelManager;
 | 
			
		||||
import net.minecraft.client.renderer.model.ModelResourceLocation;
 | 
			
		||||
import net.minecraft.item.ItemStack;
 | 
			
		||||
import net.minecraft.util.math.vector.TransformationMatrix;
 | 
			
		||||
import net.minecraft.client.resources.model.BakedModel;
 | 
			
		||||
import net.minecraft.client.resources.model.ModelManager;
 | 
			
		||||
import net.minecraft.client.resources.model.ModelResourceLocation;
 | 
			
		||||
import net.minecraft.world.item.ItemStack;
 | 
			
		||||
 | 
			
		||||
import javax.annotation.Nonnull;
 | 
			
		||||
import java.util.Objects;
 | 
			
		||||
@@ -20,19 +20,19 @@ import java.util.Objects;
 | 
			
		||||
 */
 | 
			
		||||
public final class TransformedModel
 | 
			
		||||
{
 | 
			
		||||
    private final IBakedModel model;
 | 
			
		||||
    private final TransformationMatrix matrix;
 | 
			
		||||
    private final BakedModel model;
 | 
			
		||||
    private final Transformation matrix;
 | 
			
		||||
 | 
			
		||||
    public TransformedModel( @Nonnull IBakedModel model, @Nonnull TransformationMatrix matrix )
 | 
			
		||||
    public TransformedModel( @Nonnull BakedModel model, @Nonnull Transformation matrix )
 | 
			
		||||
    {
 | 
			
		||||
        this.model = Objects.requireNonNull( model );
 | 
			
		||||
        this.matrix = Objects.requireNonNull( matrix );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public TransformedModel( @Nonnull IBakedModel model )
 | 
			
		||||
    public TransformedModel( @Nonnull BakedModel model )
 | 
			
		||||
    {
 | 
			
		||||
        this.model = Objects.requireNonNull( model );
 | 
			
		||||
        matrix = TransformationMatrix.identity();
 | 
			
		||||
        matrix = Transformation.identity();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public static TransformedModel of( @Nonnull ModelResourceLocation location )
 | 
			
		||||
@@ -41,20 +41,20 @@ public final class TransformedModel
 | 
			
		||||
        return new TransformedModel( modelManager.getModel( location ) );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public static TransformedModel of( @Nonnull ItemStack item, @Nonnull TransformationMatrix transform )
 | 
			
		||||
    public static TransformedModel of( @Nonnull ItemStack item, @Nonnull Transformation transform )
 | 
			
		||||
    {
 | 
			
		||||
        IBakedModel model = Minecraft.getInstance().getItemRenderer().getItemModelShaper().getItemModel( item );
 | 
			
		||||
        BakedModel model = Minecraft.getInstance().getItemRenderer().getItemModelShaper().getItemModel( item );
 | 
			
		||||
        return new TransformedModel( model, transform );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    public IBakedModel getModel()
 | 
			
		||||
    public BakedModel getModel()
 | 
			
		||||
    {
 | 
			
		||||
        return model;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Nonnull
 | 
			
		||||
    public TransformationMatrix getMatrix()
 | 
			
		||||
    public Transformation getMatrix()
 | 
			
		||||
    {
 | 
			
		||||
        return matrix;
 | 
			
		||||
    }
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.filesystem;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.filesystem;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.filesystem;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,13 +1,13 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.filesystem;
 | 
			
		||||
 | 
			
		||||
import dan200.computercraft.api.ComputerCraftAPI;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IComputerAccess;
 | 
			
		||||
import net.minecraft.world.World;
 | 
			
		||||
import net.minecraft.world.level.Level;
 | 
			
		||||
 | 
			
		||||
import javax.annotation.Nonnull;
 | 
			
		||||
import java.io.IOException;
 | 
			
		||||
@@ -20,10 +20,10 @@ import java.util.List;
 | 
			
		||||
 * {@link IComputerAccess#mount(String, IMount)}.
 | 
			
		||||
 *
 | 
			
		||||
 * Ready made implementations of this interface can be created using
 | 
			
		||||
 * {@link ComputerCraftAPI#createSaveDirMount(World, String, long)} or
 | 
			
		||||
 * {@link ComputerCraftAPI#createSaveDirMount(Level, String, long)} or
 | 
			
		||||
 * {@link ComputerCraftAPI#createResourceMount(String, String)}, or you're free to implement it yourselves!
 | 
			
		||||
 *
 | 
			
		||||
 * @see ComputerCraftAPI#createSaveDirMount(World, String, long)
 | 
			
		||||
 * @see ComputerCraftAPI#createSaveDirMount(Level, String, long)
 | 
			
		||||
 * @see ComputerCraftAPI#createResourceMount(String, String)
 | 
			
		||||
 * @see IComputerAccess#mount(String, IMount)
 | 
			
		||||
 * @see IWritableMount
 | 
			
		||||
 
 | 
			
		||||
@@ -1,13 +1,13 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.filesystem;
 | 
			
		||||
 | 
			
		||||
import dan200.computercraft.api.ComputerCraftAPI;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IComputerAccess;
 | 
			
		||||
import net.minecraft.world.World;
 | 
			
		||||
import net.minecraft.world.level.Level;
 | 
			
		||||
 | 
			
		||||
import javax.annotation.Nonnull;
 | 
			
		||||
import java.io.IOException;
 | 
			
		||||
@@ -20,9 +20,9 @@ import java.util.OptionalLong;
 | 
			
		||||
 * or {@link IComputerAccess#mountWritable(String, IWritableMount)}, that can also be written to.
 | 
			
		||||
 *
 | 
			
		||||
 * Ready made implementations of this interface can be created using
 | 
			
		||||
 * {@link ComputerCraftAPI#createSaveDirMount(World, String, long)}, or you're free to implement it yourselves!
 | 
			
		||||
 * {@link ComputerCraftAPI#createSaveDirMount(Level, String, long)}, or you're free to implement it yourselves!
 | 
			
		||||
 *
 | 
			
		||||
 * @see ComputerCraftAPI#createSaveDirMount(World, String, long)
 | 
			
		||||
 * @see ComputerCraftAPI#createSaveDirMount(Level, String, long)
 | 
			
		||||
 * @see IComputerAccess#mount(String, IMount)
 | 
			
		||||
 * @see IComputerAccess#mountWritable(String, IWritableMount)
 | 
			
		||||
 * @see IMount
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.lua;
 | 
			
		||||
@@ -9,7 +9,7 @@ import dan200.computercraft.api.ComputerCraftAPI;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IPeripheral;
 | 
			
		||||
import dan200.computercraft.api.peripheral.IPeripheralProvider;
 | 
			
		||||
import dan200.computercraft.core.asm.LuaMethod;
 | 
			
		||||
import net.minecraft.util.ResourceLocation;
 | 
			
		||||
import net.minecraft.resources.ResourceLocation;
 | 
			
		||||
import net.minecraftforge.common.capabilities.Capability;
 | 
			
		||||
import net.minecraftforge.items.IItemHandler;
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.lua;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.lua;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
/*
 | 
			
		||||
 * This file is part of the public ComputerCraft API - http://www.computercraft.info
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2021. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * Copyright Daniel Ratcliffe, 2011-2022. This API may be redistributed unmodified and in full only.
 | 
			
		||||
 * For help using the API, and posting your mods, visit the forums at computercraft.info.
 | 
			
		||||
 */
 | 
			
		||||
package dan200.computercraft.api.lua;
 | 
			
		||||
 
 | 
			
		||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user