Class PoiHelper

java.lang.Object
net.fabricmc.fabric.api.object.builder.v1.world.poi.PoiHelper

public final class PoiHelper extends Object
This class provides utilities to create a PoiType.

A point of interest or POI is typically used by villagers to specify their workstation blocks, meeting zones and homes. Points of interest are also used by bees to specify where their bee hive is and nether portals to find existing portals.

  • Method Summary

    Modifier and Type
    Method
    Description
    static net.minecraft.world.entity.ai.village.poi.PoiType
    register(net.minecraft.resources.Identifier id, int ticketCount, int searchDistance, Iterable<net.minecraft.world.level.block.state.BlockState> blocks)
    Creates and registers a PoiType.
    static net.minecraft.world.entity.ai.village.poi.PoiType
    register(net.minecraft.resources.Identifier id, int ticketCount, int searchDistance, net.minecraft.world.level.block.Block... blocks)
    Creates and registers a PoiType.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • register

      public static net.minecraft.world.entity.ai.village.poi.PoiType register(net.minecraft.resources.Identifier id, int ticketCount, int searchDistance, net.minecraft.world.level.block.Block... blocks)
      Creates and registers a PoiType.
      Parameters:
      id - The id of this PoiType.
      ticketCount - the amount of tickets.
      searchDistance - the search distance.
      blocks - all the blocks where a PoiRecord of this type will be present.
      Returns:
      a new PoiType.
    • register

      public static net.minecraft.world.entity.ai.village.poi.PoiType register(net.minecraft.resources.Identifier id, int ticketCount, int searchDistance, Iterable<net.minecraft.world.level.block.state.BlockState> blocks)
      Creates and registers a PoiType.
      Parameters:
      id - the id of this PoiType.
      ticketCount - the amount of tickets.
      searchDistance - the search distance.
      blocks - all block states where a PoiRecord of this type will be present
      Returns:
      a new PoiType.