Baritone AI pathfinder

Baritone AI pathfinder

72.7k Downloads

The problem with the Baritone api

chadans opened this issue · 2 comments

commented

Crashes out of the game with an error

`---- Minecraft Crash Report ----
// Who set us up the TNT?

Time: 1/29/24 4:46 AM
Description: There was a severe problem during mod loading that has caused the game to fail

net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from RPGClient Mod (rpg)
Caused by: java.lang.NoClassDefFoundError: ain
at baritone.api.Settings.(Unknown Source)
at baritone.api.BaritoneAPI.(Unknown Source)
at com.example.examplemod.Module.MOVEMENT.AutoWalk.stopWalking(AutoWalk.java:38)
at com.example.examplemod.Module.MOVEMENT.AutoWalk.onDisable(AutoWalk.java:20)
at com.example.examplemod.Module.Module.setToggled(Module.java:80)
at com.example.examplemod.Module.ModSettings.startClient(ModSettings.java:68)
at com.example.examplemod.ExampleMod.init(ExampleMod.java:51)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at net.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:639)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:219)
at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:197)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:136)
at net.minecraftforge.fml.common.Loader.initializeMods(Loader.java:749)
at net.minecraftforge.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:336)
at net.minecraft.client.Minecraft.init(Minecraft.java:535)
at net.minecraft.client.Minecraft.run(Minecraft.java:378)
at net.minecraft.client.main.Main.main(Main.java:118)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at net.minecraftforge.legacydev.Main.start(Main.java:86)
at net.minecraftforge.legacydev.MainClient.main(MainClient.java:29)
Caused by: java.lang.ClassNotFoundException: ain
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:191)
at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
... 54 more
Caused by: java.lang.NullPointerException

A detailed walkthrough of the error, its code path and all known details is as follows:

-- System Details --
Details:
Minecraft Version: 1.12.2
Operating System: Windows 10 (amd64) version 10.0
Java Version: 1.8.0_372, Amazon.com Inc.
Java VM Version: OpenJDK 64-Bit Server VM (mixed mode), Amazon.com Inc.
Memory: 226951440 bytes (216 MB) / 693633024 bytes (661 MB) up to 3668967424 bytes (3499 MB)
JVM Flags: 0 total;
IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
FML: MCP 9.42 Powered by Forge 14.23.5.2859 5 mods loaded, 5 mods active
States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored

| State | ID        | Version      | Source                                                             | Signature |
|:----- |:--------- |:------------ |:------------------------------------------------------------------ |:--------- |
| LCHI  | minecraft | 1.12.2       | minecraft.jar                                                      | None      |
| LCHI  | mcp       | 9.42         | minecraft.jar                                                      | None      |
| LCHI  | FML       | 8.0.99.99    | forge-1.12.2-14.23.5.2859_mapped_snapshot_20171003-1.12-recomp.jar | None      |
| LCHI  | forge     | 14.23.5.2859 | forge-1.12.2-14.23.5.2859_mapped_snapshot_20171003-1.12-recomp.jar | None      |
| LCHE  | rpg       | 3.9.1        | main                                                               | None      |

Loaded coremods (and transformers): 
GL info: ' Vendor: 'ATI Technologies Inc.' Version: '4.6.0 Compatibility Profile Context 23.3.1.230305' Renderer: 'AMD Radeon(TM) Graphics'`

My build.gradle

`buildscript {
repositories {
maven { url = 'https://maven.minecraftforge.net/' }
mavenCentral()
}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:3.+'
}
}

apply plugin: 'net.minecraftforge.gradle'
// Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.
apply plugin: 'eclipse'
apply plugin: 'maven-publish'

version = '3.9.1'
group = 'com.example.examplemod' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
archivesBaseName = 'RPG-Client Alpha'

sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = '1.8' // Need this here so eclipse task generates correctly.

minecraft {
// The mappings can be changed at any time, and must be in the following format.
// snapshot_YYYYMMDD Snapshot are built nightly.
// stable_# Stables are built at the discretion of the MCP team.
// Use non-default mappings at your own risk. they may not always work.
// Simply re-run your setup task after changing the mappings to update your workspace.
//mappings channel: 'snapshot', version: '20171003-1.12'
mappings channel: 'snapshot', version: '20171003-1.12'
// makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable.

// accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg')

// Default run configurations.
// These can be tweaked, removed, or duplicated as needed.
runs {
    client {
        workingDirectory project.file('run')

        // Recommended logging data for a userdev environment
        property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'

        // Recommended logging level for the console
        property 'forge.logging.console.level', 'debug'
    }

    server {

        // Recommended logging data for a userdev environment
        property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'

        // Recommended logging level for the console
        property 'forge.logging.console.level', 'debug'
    }
}

}

dependencies {
implementation 'javazoom:jlayer:1.0.1'
implementation 'io.github.jgkamat.JayLayer:JayLayer:4.1.1'
implementation 'com.googlecode.soundlibs:jlayer:1.0.1.4'
implementation 'com.googlecode.soundlibs:jlayer:1.0.1.4'

// Добавление Baritone API как зависимости проекта из папки 'libs'
implementation files('libs/baritone-api-forge-1.2.19.jar')

// Specify the version of Minecraft to use, If this is any group other then 'net.minecraft' it is assumed
// that the dep is a ForgeGradle 'patcher' dependency. And it's patches will be applied.
// The userdev artifact is a special name and will get all sorts of transformations applied to it.
minecraft 'net.minecraftforge:forge:1.12.2-14.23.5.2859'

// You may put jars on which you depend on in ./libs or you may define them like so..
// compile "some.group:artifact:version:classifier"
// compile "some.group:artifact:version"

// Real examples
// compile 'com.mod-buildcraft:buildcraft:6.0.8:dev'  // adds buildcraft to the dev env
// compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env

// The 'provided' configuration is for optional dependencies that exist at compile-time but might not at runtime.
// provided 'com.mod-buildcraft:buildcraft:6.0.8:dev'

// These dependencies get remapped to your current MCP mappings
// deobf 'com.mod-buildcraft:buildcraft:6.0.8:dev'

// For more info...
// http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
// http://www.gradle.org/docs/current/userguide/dependency_management.html

}

// Example for how to get properties into the manifest for reading by the runtime..
jar {
manifest {
attributes([
"Specification-Title": "examplemod",
"Specification-Vendor": "examplemodsareus",
"Specification-Version": "1", // We are version 1 of ourselves
"Implementation-Title": project.name,
"Implementation-Version": "${version}",
"Implementation-Vendor" :"examplemodsareus",
"Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
])
}
}

// Example configuration to allow publishing using the maven-publish task
// This is the preferred method to reobfuscate your jar file
jar.finalizedBy('reobfJar')
// However if you are in a multi-project build, dev time needs unobfed jar files, so you can delay the obfuscation until publishing by doing
//publish.dependsOn('reobfJar')

publishing {
publications {
mavenJava(MavenPublication) {
artifact jar
}
}
repositories {
maven {
url "file:///${project.projectDir}/mcmodsrepo"
}
}
}
`

commented

HELP

commented

Duplicate of #4262