Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
danorris709 authored May 7, 2023
1 parent 9a59342 commit 9be5937
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,19 @@ their documentation [here](https://github.com/Mojang/brigadier/blob/master/READM
I have my own API for commands. If you're looking for examples of how to
use that I'd suggest looking through the [bingo](https://github.com/EnvyWare/ReforgedBingo) sidemod I have made.

There is now two examples of commands in the MDK
- https://github.com/EnvyWare/Pixelmon-MDK/blob/main/src/main/java/your/domain/path/command/ExampleCommand.java
- https://github.com/EnvyWare/Pixelmon-MDK/blob/main/src/main/java/your/domain/path/command/MoreComplicatedCommand.java

Both of these demonstrate how you can use Brigadier to create server side commands (all commands are server side in 1.16.5).
The second example shows a more complicated example with arguments and also gives an example of how to use the PokemonSpecification (spec) system.

## Configs
To create configs I recommend using Pixelmon's internal config API, which is the same as the config API in the EnvyWare API.
The config API is just a small wrapper around Sponge's Configurate, and allows for very easy config reloading and simple config
design from a code perspective.
You can find an example of how to use it [here](https://github.com/EnvyWare/Pixelmon-MDK/blob/main/src/main/java/your/domain/path/config/ExampleConfig.java)

## Listeners
In the project you can find an example Pixelmon listener. However, below I'll
include an example for TCG, Pixelmon and Forge.
Expand Down Expand Up @@ -143,4 +156,4 @@ public static class GenericEventListener {
## EnvyAPI

If you're looking for an example of how to use my API please look at
any of the sidemods on this GitHub organization.
any of the sidemods on this GitHub organization.

0 comments on commit 9be5937

Please sign in to comment.