Setting Up a Development Environment
From Multiverse
| Multiverse Server Plug-ins |
|
Understanding the Servers Processes, Plug-ins, and Agents Creating a Server Plug-in • Defining Command Handlers • Setting Perceiver Radius • |
| Examples and Tutorials |
|
Basic Server Plugin • Faction Plug-in • Creating a Slash Command |
| Server Development |
|
Setting Up an IDE • Using Eclipse |
| Reference |
Contents |
Requirements
To develop server plug-ins, you must have:
- Java SE 5.0 (used to be called JDK). If you are running the server, you should already have this, though theoretically you can run the server with only the Java Runtime Engine (JRE).
- Python interpreter. If you are using Linux, you should have this; if you are on Windows and using Cygwin, make sure you have installed the Python package (interpreters.python). You can test this by simply typing "python" in a Cygwin shell window.
- A text editor. You can use any text editor you want: vi, emacs, or even Notepad on Windows. This is the bare minimum requirement; if you use an IDE as recommended, it will come with a far superior editor.
NOTE: You can do most things with Python. However, it may be easier to develop and debug in Java. It really depends on your preference.
Recommendations
We recommend you use an IDE for Java development. Many free Java IDEs are available that run on Linux and Windows, including:
- Eclipse - recommended.
- NetBeans
- JBuilder Foundation
Also see the list of Third-Party Tools put together by Nikmis.
Free Python tools are also available:
Building MARS
The server distribution includes the complete Java source code for MARS, that is, packages multiverse.mars.*, installed to mv_home/src.
There is also an Ant script to build the MARS JAR file in mv_home/build_mars.xml. See Building MARS With Ant.
Setting Up Eclipse
For more detailed instructions on using Eclipse, see Developing With Eclipse.
The following instructions are derived from a post on the forums.
- open Eclipse
- Choose File > New > Project
- Select "Java Project" from the Java folder, click Next.
- Select "Create Project from Existing Source", click Browse.
- Browse to the "src" folder inside your Multiverse directory and select it.
- Go to Project > Properties > Java Build Path, click on the Libraries tab and add external JARs
- Select
multiverse.jarfrom the MV_HOME/dist/lib folder.
