October 2014
Beginner to intermediate
285 pages
6h 24m
English
We’ve been using a bunch of objects in the Minecraft code. For example, you know that a player is represented as a Player object and the server is a Server object.
So it shouldn’t be too surprising to realize that our plugins are, in fact, Plugin objects. Canary has kindly defined a basic “recipe,” a basic Plugin class that it knows about. I’ve added an additional EZPlugin class to make things a little easier. Our job, as plugin writers, is to provide our own plugin code that fits into that framework.
As we’ve seen, the first line of a plugin declares the plugin’s name and then adds the magical phrase extends EZPlugin:
| | import net.canarymod.plugin.Plugin; |
| | import com.pragprog.ahmine.ez.EZPlugin; ... |
Read now
Unlock full access