Sueta

PCore

2

Particle API version for all SpigotMC versions.

·Plugin

PCore

Particle API for all SpigotMC versions. Unlike other API's that need to be updated every new version of SpigotMC, PCore aims to be prepared for future updates without having to be updated.

Installation
There is no public repository for PCore. This means you must clone this project into your workspace.

Usage
Using PCore is simple and hassle free. Setup is easy, simply store the PCore instance for all your particle needs. It is more efficient to use a saved instance instead of PCore instead of creating a new instance every time. To create a new instance:

PCore pcore  =   new  PCore  (   )   ;

To get all particles on your server version, simply use the following code:

List  <  String  >  particles  =  pcore.  getParticles   (   )   ;

To test if a string is a particle string, you can check is using this:

boolean  isParticle  =  pcore.  isParticle   (   "REDSTONE"   )   ;

And last but not least, the method to play particles. These arguments are the same as those from versions previous to 1.13. Except for 2, the player (instead of the craft player), and the particle (this is the particle string).

pcore.send(player, particle, b, x, y, z, xOffset, yOffset, zOffset, other, data, amount);

And that's it! You're ready to go with all spigot versions and write your own custom implementation of particles. Enjoy!

Similar projects

Plugin →