I'm trying to minimize how much I create an instance, as I am not particularly skilled in Java. Currently I have a set of instances of other classes in my Main, a quick example...
public final class ClassName extends JavaPlugin {
AntiSwear antiSwear = new AntiSwear();
Spam spam = new Spam();
@Override
public void onEnable() {
// Plugin startup logic
}
@Override
public void onDisable() {
// Plugin shutdown logic
}
}
And instead of making more and more instances, I just want to make an instance of the main class, ClassName className = new ClassName();
and run something like className.spam...
Basically to put my gibberish into English: I just want to see how to reference instances using an instance.