Class ResetSpeakerNPC

java.lang.Object
games.stendhal.server.util.ResetSpeakerNPC

public class ResetSpeakerNPC extends Object
Utility class to restoring SpeakerNPC to startup state. NOTE: Be mindful that resetting NPCs will erase ALL quest transitions. If the NPC is associated with multiple quests be sure to reload any quests that should remain active.
  • Constructor Details

    • ResetSpeakerNPC

      public ResetSpeakerNPC()
  • Method Details

    • reload

      public static boolean reload(ZoneConfigurator zc, Object z, String... names)
      Resets multiple SpeakerNPC to state at server startup.
      Parameters:
      zc - Zone configurator to be reloaded.
      z - Zone or name of zone passed to configurator.
      names - Names of NPCs that should be reset.
      Returns:
      true if each NPC was removed & reloaded.
    • reload

      public static boolean reload(ZoneConfigurator zc, String name)
      Resets a SpeakerNPC to state at server startup. The zone to be passed to configurator is the zone where NPC is located.
      Parameters:
      zc - Zone configurator to be reloaded.
      name - Names of NPC that should be reset.
      Returns:
      true if the NPC was removed & reloaded.