I just started making a plugin and I noticed my mod was not being loaded when I started Minecraft:
[01:46:32] [Client thread/INFO] [FML]: FML has found a non-mod file GymProject-1.0.0.jar in your mods directory. It will now be injected into your classpath. This could severe stability issues, it should be removed if possible.
I googled around for a bit and the answer I seem to have gotten was that it was version incompatability, but I am under the impression that it is fine? According to docs, API 7.2 is made for Forge 1.12.2.
This is my Gradle build:
plugins {
id 'java'
id 'org.spongepowered.plugin' version '0.9.0'
id "de.schablinski.activejdbc-gradle-plugin" version "1.2"
}
// This may not be required, but has solved issues in the past
compileJava.options.encoding = 'UTF-8'
// TODO: Change the following to match your information
group = 'com.gym'
version = '1.0.0'
description = 'Gym Leader Plugin for Pixelmon'
repositories {
jcenter()
}
dependencies {
compile 'org.spongepowered:spongeapi:7.2.0'
compile 'org.javalite:activejdbc:2.2'
}
My forge version is 1.12.2-14.23.5.2838. I am using Eclipse and Gradle and using the build button to assemble my project.
I put the jar file into mods folder and thought that is all I need to do. For extra reference I will also include my main class.
package GymProject;
import org.spongepowered.api.plugin.Plugin;
import org.spongepowered.api.event.Listener;
import org.spongepowered.api.event.game.state.GameInitializationEvent;
import org.spongepowered.api.event.game.state.GameStartedServerEvent;
import org.javalite.activejdbc.Base;
import org.spongepowered.api.text.Text;
// Imports for logger
import com.google.inject.Inject;
import org.slf4j.Logger;
// Import packages
import commands.CommandBuilder;
import db_entities.*;
@Plugin(id = "GymPlugin", name = "Gym Leader Plugin", version = "1.0", description = "Gym Leader Plugin for Pixelmon")
public class GymMain {
@Inject
private Logger logger;
public static void main(String[] args) {
// Open up DB
Base.open("com.mysql.jdbc.Driver", "jdbc:mysql://localhost/test", "user1", "xxxxx");
}
@Listener
public void onServerStart(GameStartedServerEvent event) {
logger.info("GymPlugin is running.");
}
@Listener
public void onInitialization(GameInitializationEvent event) {
// Test DB, delete later
new GymLeader().set("id", "123").saveIt();
CommandBuilder.buildCommands(this);
}
}
To go even further, I was decompiling my previous projects since I lost my code and I realized I did not have mcmod.info on the newer project like I do the old one. This is perhaps making me think that maybe I am not building this correctly.
Please let me know if I am making a dumb mistake or something.
EDIT
Here is the full log file:
And report given by my friend: