Enum Class SpellBook

java.lang.Object
java.lang.Enum<SpellBook>
net.storm.api.magic.SpellBook
All Implemented Interfaces:
Serializable, Comparable<SpellBook>, Constable

public enum SpellBook extends Enum<SpellBook>
Enumeration representing the four spellbooks available in the game.

Each spellbook contains a different set of spells with unique functionality:

  • STANDARD - The default spellbook available to all players, containing basic combat spells, teleports, and utility spells like alchemy.
  • ANCIENT - Unlocked after completing Desert Treasure, featuring powerful combat spells with special effects (freeze, poison, heal) and Zarosian teleports.
  • LUNAR - Unlocked after completing Lunar Diplomacy, focused on skilling and support spells with group teleports and utility magic.
  • NECROMANCY - The Arceuus spellbook, containing reanimation spells, demonbane spells, and various utility magic for Prayer training.

Each spellbook is represented as a nested enum implementing the Spell interface, allowing type-safe access to all spells within that spellbook.

See Also:
  • Enum Constant Details

    • STANDARD

      public static final SpellBook STANDARD
      The Standard spellbook - default spellbook available to all players.
    • ANCIENT

      public static final SpellBook ANCIENT
      The Ancient spellbook - unlocked via Desert Treasure quest.
    • LUNAR

      public static final SpellBook LUNAR
      The Lunar spellbook - unlocked via Lunar Diplomacy quest.
    • NECROMANCY

      public static final SpellBook NECROMANCY
      The Necromancy (Arceuus) spellbook - available to those with Arceuus favor.
  • Method Details

    • values

      public static SpellBook[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static SpellBook valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getCurrent

      public static SpellBook getCurrent()
      Gets the currently active spellbook for the player.

      This method reads the spellbook varbit to determine which spellbook is currently selected.

      Returns:
      the current SpellBook, or null if unable to determine