Skip to content
This repository was archived by the owner on Jul 25, 2024. It is now read-only.

Create custom spells Java API

jamailun edited this page Jun 28, 2020 · 1 revision

Here, you will learn how to use my API to create a new spell.

Please, consider learning the spigot API first. It's what you will have to use mostly.


It's really simple.

  1. Create a class that extends fr.jamailun.halytsia.spells.Spell (note that if you want to summon things around the spell's caster, you shoulg extends the fr.jamailun.halytsia.spells.InvocationSpell class.

  2. Do not create constructor. It's useless. If you want to instantiate things before any spell to be cast, just override the Spell#init() method.

  3. Implements all missings methods. The Spell#cast(Player) will be the most important one. Just do whatever you want to do here !

  4. Once your spell is designed, you have to register it. Just do : HalystiaRPG.getInstance().getSpellManager().addSpell(MyBrandNewSpell.class). Let my API do the instanciation work, just gimme the class.


Note that the Spell and InvocationSpell classes will let you use a lot of nice methods. Look at the docs !

Clone this wiki locally