Class ClickRedirectTrait

java.lang.Object
net.citizensnpcs.api.trait.Trait
net.citizensnpcs.trait.ClickRedirectTrait
All Implemented Interfaces:
Runnable, Listener

public class ClickRedirectTrait extends Trait
Redirects left and right clicks to another NPC.
  • Constructor Details

    • ClickRedirectTrait

      public ClickRedirectTrait()
    • ClickRedirectTrait

      public ClickRedirectTrait(NPC npc)
  • Method Details

    • getRedirectNPC

      public NPC getRedirectNPC()
    • load

      public void load(DataKey key)
      Description copied from class: Trait
      Loads a trait.
      Overrides:
      load in class Trait
      Parameters:
      key - DataKey to load from
    • onTraitAdd

      public void onTraitAdd(NPCAddTraitEvent event)
    • save

      public void save(DataKey key)
      Description copied from class: Trait
      Saves a trait.
      Overrides:
      save in class Trait
      Parameters:
      key - DataKey to save to