Published Jun 22nd, 2015, 6/22/15 6:21 am
- 361 views • 1 today
- 1
- 0
- 1
5
Enabling and Disabling plugin Message
Create the methods onEnable() and onDisable() inside the main class created in the previous section. It will look something like the following
package {$TopLevelDomain}.{$Domain}.{$PluginName};
import org.bukkit.plugin.java.JavaPlugin;
public final class {$PluginName} extends JavaPlugin {
@Override
public void onEnable() {
// TODO the enabling message example codes will be listed below
// First method System.out.println("Plugin successfully enabled");
// Second method getLogger().info("Plugin successfully enabled");
// the "//" thingy is only uses for comments
System.out.println("Plugin successfully enabled");
}
@Override
public void onDisable() {
// TODO the disabling message example codes are kindly looks like above
System.out.println("Plugin successfully disabled");
}
}
Create the methods onEnable() and onDisable() inside the main class created in the previous section. It will look something like the following
package {$TopLevelDomain}.{$Domain}.{$PluginName};
import org.bukkit.plugin.java.JavaPlugin;
public final class {$PluginName} extends JavaPlugin {
@Override
public void onEnable() {
// TODO the enabling message example codes will be listed below
// First method System.out.println("Plugin successfully enabled");
// Second method getLogger().info("Plugin successfully enabled");
// the "//" thingy is only uses for comments
System.out.println("Plugin successfully enabled");
}
@Override
public void onDisable() {
// TODO the disabling message example codes are kindly looks like above
System.out.println("Plugin successfully disabled");
}
}
| Tags |
3359247
6


Have something to say?
Part 2 would be the simple commands enjoy