![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Digital and Interactive Games 2015 – Term 3, Session 2
Today:
・ Create your first plugin
・ Create a plugin with one simple command
Link file
spigot-1.8.7.jar
Totally open source
Plugin Tutorial
plugin.yml

public final class pluginTutorial extends JavaPlugin
import org.bukkitt.plugin.java.JavaPlugin;
import org.bukkit.Bukkit;
Bukkit.broadcastmessage(“PluginTutorial”);
Command Tutorial
My Command
getCommand(“myCommand”).setExecuter(new myCommandCommand());
Minecraft
|
onEnable() → main Plugin reference sent
|
Link new command
. Command
. Class
. . on Command() reference received
・ method
・ method
if (!sender instanceOf Player) {
run();
} else {
Player player = (Player) sender;
player.sendMessage(“You type my command”);
}
return true;
Player
・ location
・ inventory
Next week manipulating blocks
Week 3 manipulating timing
Create a plugin based on your .yml
Search Bukkit for similar plugins
・ read the docs
・ what needs to be improved