O'Reilly logo

Building Minecraft Server Modifications - Second Edition by Cody M. Sommer

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5. Plugin Commands

The nice thing about the Bukkit API is that it has the basic features already built into its framework. As programmers, we need not go out of our way to implement these basic features into plugins. In this chapter, we will discuss one of these features, namely the in-game commands that can be executed by a player. These are similar to the commands that you are already familiar with, such as /reload, /gamemode, or /give. We will create a plugin that will enchant an item. By the end of this chapter, once the plugin is complete, you will be able to type /enchant to add your favorite enchantments to the item in your hand.

Commands are one of the easiest ways for players to communicate with a plugin. They also allow players ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required