Interface IResourcePackSelectEvent

All Known Implementing Classes:
ResourcePackSelectEvent, ResourcePackSelectEvent, ResourcePackSelectEvent

public interface IResourcePackSelectEvent
Created by Phoenix616 on 18.04.2015.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
    The status of the select event
    SUCCESS - Pack found and is not null
    NO_PERMISSION - Selection failed because the player does not have the permission for the pack
    WRONG_VERSION - Selection failed because there is not compatible pack
    NO_PERM_AND_WRONG_VERSION - Both failures happened
    ALREADY_APPLIED - The player already had that pack applied IS_EMPTY - The player already had the empty pack applied UNKNOWN - We don't know why it failed
  • Method Summary

    Modifier and Type
    Method
    Description
    default ResourcePack
    Deprecated.
    Get the packs that were selected
     
    The status of the select event
    SUCCESS - Pack found and is not null
    NO_PERMISSION - Selection failed because the player does not have the permission for the pack
    WRONG_VERSION - Selection failed because there is not compatible pack
    NO_PERM_AND_WRONG_VERSION - Both failures happened
    UNKNOWN - We don't know why it failed
    default void
    Deprecated.
    Directly add to or remove from getPacks()
    void
    Set the status.
  • Method Details

    • getPlayerId

      UUID getPlayerId()
    • getPack

      @Deprecated default ResourcePack getPack()
      Deprecated.
      Get the pack that was selected
      Returns:
      The selected pack; null if the selection failed
    • getPacks

      List<ResourcePack> getPacks()
      Get the packs that were selected
      Returns:
      The selected packs; null if the selection failed
    • setPack

      @Deprecated default void setPack(ResourcePack pack)
      Deprecated.
      Directly add to or remove from getPacks()
      Set the pack. If it isn't null the status will be set to success. Otherwise you have to set the status yourself
      Parameters:
      pack - The pack that was selected
    • getStatus

      The status of the select event
      SUCCESS - Pack found and is not null
      NO_PERMISSION - Selection failed because the player does not have the permission for the pack
      WRONG_VERSION - Selection failed because there is not compatible pack
      NO_PERM_AND_WRONG_VERSION - Both failures happened
      UNKNOWN - We don't know why it failed
      Returns:
      The status of the event
    • setStatus

      void setStatus(IResourcePackSelectEvent.Status status)
      Set the status. If it isn't SUCCESS the pack will be set to null
      Parameters:
      status - The status of the select event