类 ForgeChunkManager.TicketHelper

java.lang.Object
net.minecraftforge.common.world.ForgeChunkManager.TicketHelper
封闭类:
ForgeChunkManager

public static class ForgeChunkManager.TicketHelper extends Object
Class to help mods remove no longer valid tickets.
  • 字段概要

    字段
    修饰符和类型
    字段
    说明
    private final Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>>
     
    private final Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>>
     
    private final String
     
    private final ForcedChunksSavedData
     
  • 构造器概要

    构造器
    限定符
    构造器
    说明
    private
    TicketHelper(ForcedChunksSavedData saveData, String modId, Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> blockTickets, Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> entityTickets)
     
  • 方法概要

    修饰符和类型
    方法
    说明
    Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>>
    Gets all "BLOCK" tickets this mod had registered and which block positions are forcing which chunks.
    Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>>
    Gets all "ENTITY" tickets this mod had registered and which entity (UUID) is forcing which chunks.
    void
    Removes all tickets that a given entity (UUID) was responsible for; both ticking and not ticking.
    void
    Removes all tickets that a given block was responsible for; both ticking and not ticking.
    private <T extends Comparable<? super T>>
    void
    Removes all tickets that a given owner was responsible for; both ticking and not ticking.
    void
    removeTicket(UUID owner, long chunk, boolean ticking)
    Removes the ticket for the given chunk that a given entity (UUID) was responsible for.
    void
    removeTicket(BlockPos owner, long chunk, boolean ticking)
    Removes the ticket for the given chunk that a given block was responsible for.
    private <T extends Comparable<? super T>>
    void
    removeTicket(ForgeChunkManager.TicketTracker<T> tickets, T owner, long chunk, boolean ticking)
     

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 字段详细资料

    • blockTickets

      private final Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> blockTickets
    • entityTickets

      private final Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> entityTickets
    • saveData

      private final ForcedChunksSavedData saveData
    • modId

      private final String modId
  • 构造器详细资料

    • TicketHelper

      private TicketHelper(ForcedChunksSavedData saveData, String modId, Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> blockTickets, Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> entityTickets)
  • 方法详细资料

    • getBlockTickets

      public Map<BlockPos,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> getBlockTickets()
      Gets all "BLOCK" tickets this mod had registered and which block positions are forcing which chunks. First element of the pair is the non-fully ticking tickets, second element is the fully ticking tickets.
      API Note:
      This map is unmodifiable and does not update to reflect removed tickets so it is safe to call the remove methods while iterating it.
    • getEntityTickets

      public Map<UUID,com.mojang.datafixers.util.Pair<it.unimi.dsi.fastutil.longs.LongSet,it.unimi.dsi.fastutil.longs.LongSet>> getEntityTickets()
      Gets all "ENTITY" tickets this mod had registered and which entity (UUID) is forcing which chunks. First element of the pair is the non-fully ticking tickets, second element is the fully ticking tickets.
      API Note:
      This map is unmodifiable and does not update to reflect removed tickets so it is safe to call the remove methods while iterating it.
    • removeAllTickets

      public void removeAllTickets(BlockPos owner)
      Removes all tickets that a given block was responsible for; both ticking and not ticking.
      参数:
      owner - Block that was responsible.
    • removeAllTickets

      public void removeAllTickets(UUID owner)
      Removes all tickets that a given entity (UUID) was responsible for; both ticking and not ticking.
      参数:
      owner - Entity (UUID) that was responsible.
    • removeAllTickets

      private <T extends Comparable<? super T>> void removeAllTickets(ForgeChunkManager.TicketTracker<T> tickets, T owner)
      Removes all tickets that a given owner was responsible for; both ticking and not ticking.
    • removeTicket

      public void removeTicket(BlockPos owner, long chunk, boolean ticking)
      Removes the ticket for the given chunk that a given block was responsible for.
      参数:
      owner - Block that was responsible.
      chunk - Chunk to remove ticket of.
      ticking - Whether or not the ticket to remove represents a ticking set of tickets or not.
    • removeTicket

      public void removeTicket(UUID owner, long chunk, boolean ticking)
      Removes the ticket for the given chunk that a given entity (UUID) was responsible for.
      参数:
      owner - Entity (UUID) that was responsible.
      chunk - Chunk to remove ticket of.
      ticking - Whether or not the ticket to remove represents a ticking set of tickets or not.
    • removeTicket

      private <T extends Comparable<? super T>> void removeTicket(ForgeChunkManager.TicketTracker<T> tickets, T owner, long chunk, boolean ticking)