Building Minecraft Server Modifications


Building Minecraft Server Modifications
eBook: $17.99
Formats: PDF, PacktLib, ePub and Mobi formats
$15.29
save 15%!
Print + free eBook + free PacktLib access to the book: $47.98    Print cover: $29.99
$29.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Create your own Minecraft server mods
  • Set up a Bukkit server that all your Minecraft friends can play on
  • Step by step instructions guide you through the creation of several unique mods

Book Details

Language : English
Paperback : 142 pages [ 235mm x 191mm ]
Release Date : September 2013
ISBN : 1849696004
ISBN 13 : 9781849696005
Author(s) : Cody M. Sommer
Topics and Technologies : All Books, Other, Games

Table of Contents

Preface
Chapter 1: Deploying a CraftBukkit Server
Chapter 2: Learning the Bukkit API
Chapter 3: Creating Your First Bukkit Plugin
Chapter 4: Testing on the CraftBukkit Server
Chapter 5: Plugin Commands
Chapter 6: Player Permissions
Chapter 7: The Bukkit Event System
Chapter 8: Making Your Plugin Configurable
Chapter 9: Saving Your Data
Chapter 10: The Bukkit Scheduler
Index
    • Chapter 2: Learning the Bukkit API
      • Introduction to APIs
      • The Bukkit API documentation
      • Navigating the Bukkit API documentation
      • Understanding the Java documentation
      • Exploring Bukkit API
      • Summary
      • Chapter 3: Creating Your First Bukkit Plugin
        • Installing an IDE
        • Creating a new project
        • Adding Bukkit as a library
        • The essentials of a Bukkit plugin
          • The plugin.yml file
          • The plugin's main class
        • Making and calling new methods
        • Expanding your code
        • Summary
          • Chapter 5: Plugin Commands
            • Adding a command to plugin.yml
            • Programming the command actions
            • Assigning the executor for the command
            • Summary
            • Chapter 6: Player Permissions
              • The benefits of permissions
              • Understanding permission nodes
              • Adding a permission node to plugin.yml
              • Assigning a permission node to a plugin command
              • Testing player permissions
              • Using a third-party permissions plugin
              • Using permission nodes throughout your plugins
              • Summary
              • Chapter 7: The Bukkit Event System
                • Choosing an event
                • Registering an event listener
                • Listening for an event
                • Canceling an event
                • Communicating among events
                • Modifying an event as it occurs
                • Creating more plugins on your own
                • Summary
                • Chapter 8: Making Your Plugin Configurable
                  • Configurable data types
                  • Writing a config.yml file
                  • Saving, loading, and reloading the config file
                  • Reading and storing the configured values
                  • Using configured settings within your plugin
                  • ItemStack within a configuration
                  • YAML configuration hierarchy
                  • Storing configuration values as variables
                  • Accessing variables from another class
                  • Summary
                  • Chapter 9: Saving Your Data
                    • Types of data that can be saved
                    • Which data to save and when
                    • A sample teleportation plugin
                    • Writing a ConfigurationSerializable class
                    • Saving data to a YAML configuration
                    • Loading data from a YAML configuration
                    • Summary
                    • Chapter 10: The Bukkit Scheduler
                      • Creating a BukkitRunnable class
                      • Synchronous versus asynchronous tasks
                      • Running a task from a BukkitRunnable class
                      • Running a task later from a BukkitRunnable
                      • Running a task timer from a BukkitRunnable class
                      • Writing a repeating task for a plugin
                      • Adding a delayed task to a plugin
                      • Executing a code asynchronously
                      • Summary

                      Cody M. Sommer

                      Cody M. Sommer has always been interested in computers. In his free time he would take them apart just to learn more about how they worked. He eventually began building computers for himself and others. Cody would spend many hours a day on his computer whether he was playing games, browsing the internet, or learning more about how they work. It wasn't until his college career that he was introduced to software development. During his senior year of high school, Cody began taking courses in Computer Science at The College at Brockport: State University of New York. The college primarily taught the Java language due to its vast presence in modern software. After a year or so, Cody had a solid understanding of Java and various programming techniques. He was anxious to put these to use. His first out-of-school project consisted of programming a solitaire type card game to play itself and print out statistics on the results. This is when he discovered that the game he had been trying to win for the past few months only dealt a "winning" deck about once in every 1000 games. Being able to control a computer to complete a task fascinated Cody. Programming the card game took less than one week so he had to find another project; preferably one that would be challenging, keep him busy, and not be completed for a long time. This is when he discovered the Bukkit project. Both Minecraft and the Bukkit API are programmed in Java which Cody knew very well. On the Bukkit forums were countless server administrators just waiting for a developer to come along to create their idea. All that was required of him to begin creating Bukkit plugins was to learn the Bukkit API. Cody first dissected a few public projects to study their structure and get an idea of how these server plugins were programmed. Through self-teaching and with the aid of more experienced developers, he eventually managed to create his first project, called Turnstile. This plugin required that players on a Minecraft server pay in-game money to enter specific areas, such as subway stations. He developed several plugins his first few months. Most of these were requested by other people. However, two of his favorite projects, PhatLoots and TextPlayer, were his original ideas. Cody enjoyed pushing the game to its limits. The creation of TextPlayer is one example of this. The plugin allowed Minecraft players or server admins to always be connected to the servers that they play on. This was all done through e-mail and text messages. People could be alerted on their phone of events that occurred on the server. These events included a friend logging on, a player vandalizing the game world, or a player entering their house or property. The plugin grew to allow people to communicate back to the server which also allowed admins and moderators to run server commands from their cell phone. These various projects aided Cody in learning Java. Most of his programming knowledge came from school but some things are not fully understood until they are put to use in a real-life scenario. Depending on their complexity, Bukkit plugins can even help developers practice advance programming techniques, such as recursion, algorithms, and data structures. Through timing reports, a developer can improve their code by finding slowly executing blocks of code. Some of the most important steps of the software development life cycle are emphasized in Cody's Bukkit plugins. These steps include bug fixes, addition of new features, and writing code that is prepared for future changes in the project. Two years later, Cody graduated with a Bachelor's degree and is still active within the Bukkit community. He has over 10 public plugins, works as a private developer for some of the top Minecraft Servers in the world, and creates private plugins upon request. His projects are still pushing Minecraft servers to their limits of what they are able to accomplish. Cody occasionally tutors developers to write efficient code and help them tackle challenging tasks. One of his goals is to help grow the Bukkit community with new developers as he feels that writing code for something that interests you is a great way to practice programming and encourage you to learn more.
                      Sorry, we don't have any reviews for this title yet.

                      Code Downloads

                      Download the code and support files for this book.


                      Submit Errata

                      Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


                      Errata

                      - 2 submitted: last submission 28 May 2014

                      Errata type: Typo | Page: About the reviewers

                      Correction: In the 1st reviewers bio,

                      Use "MineCon 2011 in Las Vegas" instaed of

                      "MineCon 2011 in Paris, France"

                      Downloading the example code

                      You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.


                       

                      Sample chapters

                      You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

                      Frequently bought together

                      Building Minecraft Server Modifications +    Scratch 1.4: Beginner’s Guide =
                      50% Off
                      the second eBook
                      Price for both: $27.00

                      Buy both these recommended eBooks together and get 50% off the cheapest eBook.

                      What you will learn from this book

                      • Set up a Bukkit-powered Minecraft server including port forwarding
                      • Download and set an IDE to prepare for programming using the Bukkit API
                      • Get to grips with the process of installing and testing server mods on your Bukkit server
                      • Learn the basics of the Java programming language to begin writing your plugins
                      • Handle Bukkit events that occur on a Minecraft server
                      • Create customizable plugins to please multiple users
                      • Set up permissions on your server and include permission checks in your projects

                      In Detail

                      If you have ever played Minecraft on a public server then the chances are that the server was powered by Bukkit. Bukkit plugins allow a server to be modified in more ways than you can imagine. Learning to program your own server mods will allow you to customize the game to your own liking.

                      Building Minecraft Server Modifications is a complete guide that walks you through the creation of Minecraft server mods. From setting up a server, to testing your newly made plugins, this book teaches you everything you need to know. With the help of this book you can start practising for a career in software development or simply create something awesome to play with your friends.

                      This book walks you through installing your own Minecraft server for you and your friends. Once your server is running, it will aid you in modifying the game by programming Bukkit plugins. You will learn how to program simple plugin features such as player commands and permissions. You will also learn more complex features including listening for events, creating a configurable plugin, and utilizing the Bukkit scheduler. All of this will be accomplished while writing your own server mods.

                      You will become familiar with the most important aspects of the Bukkit API. Additional API features will become a breeze to learn after tackling these more complicated tasks.

                      Approach

                      Building Minecraft Server Modifications is a unique guide that will walk you through the entire process of developing mods for your Minecraft server.

                      Who this book is for

                      Building Minecraft Server Modifications is great for anyone who is interested in customizing their Minecraft server. Whether you are new to programming, Java, Bukkit, or even Minecraft itself, this book has you covered. All you need is a valid Minecraft account. If you are interested in software development then this book will help you get started. If you are simply interested in playing Minecraft with your friends then this book will help you make that experience even more enjoyable.

                      Code Download and Errata
                      Packt Anytime, Anywhere
                      Register Books
                      Print Upgrades
                      eBook Downloads
                      Video Support
                      Contact Us
                      Awards Voting Nominations Previous Winners
                      Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
                      Resources
                      Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software