Class Villager

All Implemented Interfaces:
CommandSource, Attackable, InventoryCarrier, Npc, VillagerDataHolder, ReputationEventHandler, Targeting, VariantHolder<VillagerType>, Merchant, EntityAccess, Nameable, ScoreHolder, ICapabilityProvider, ICapabilityProviderImpl<Entity>, ICapabilitySerializable<CompoundTag>, IForgeEntity, IForgeLivingEntity, INBTSerializable<CompoundTag>

public class Villager extends AbstractVillager implements ReputationEventHandler, VillagerDataHolder
  • Field Details

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • DATA_VILLAGER_DATA

      private static final EntityDataAccessor<VillagerData> DATA_VILLAGER_DATA
    • BREEDING_FOOD_THRESHOLD

      public static final int BREEDING_FOOD_THRESHOLD
      See Also:
    • FOOD_POINTS

      public static final Map<Item,Integer> FOOD_POINTS
    • TRADES_PER_LEVEL

      private static final int TRADES_PER_LEVEL
      See Also:
    • WANTED_ITEMS

      private static final Set<Item> WANTED_ITEMS
    • MAX_GOSSIP_TOPICS

      private static final int MAX_GOSSIP_TOPICS
      See Also:
    • GOSSIP_COOLDOWN

      private static final int GOSSIP_COOLDOWN
      See Also:
    • GOSSIP_DECAY_INTERVAL

      private static final int GOSSIP_DECAY_INTERVAL
      See Also:
    • REPUTATION_CHANGE_PER_EVENT

      private static final int REPUTATION_CHANGE_PER_EVENT
      See Also:
    • HOW_FAR_AWAY_TO_TALK_TO_OTHER_VILLAGERS_ABOUT_GOLEMS

      private static final int HOW_FAR_AWAY_TO_TALK_TO_OTHER_VILLAGERS_ABOUT_GOLEMS
      See Also:
    • HOW_MANY_VILLAGERS_NEED_TO_AGREE_TO_SPAWN_A_GOLEM

      private static final int HOW_MANY_VILLAGERS_NEED_TO_AGREE_TO_SPAWN_A_GOLEM
      See Also:
    • TIME_SINCE_SLEEPING_FOR_GOLEM_SPAWNING

      private static final long TIME_SINCE_SLEEPING_FOR_GOLEM_SPAWNING
      See Also:
    • SPEED_MODIFIER

      public static final float SPEED_MODIFIER
      See Also:
    • updateMerchantTimer

      private int updateMerchantTimer
    • increaseProfessionLevelOnUpdate

      private boolean increaseProfessionLevelOnUpdate
    • lastTradedPlayer

      @Nullable private Player lastTradedPlayer
    • chasing

      private boolean chasing
    • foodLevel

      private int foodLevel
    • gossips

      private final GossipContainer gossips
    • lastGossipTime

      private long lastGossipTime
    • lastGossipDecayTime

      private long lastGossipDecayTime
    • villagerXp

      private int villagerXp
    • lastRestockGameTime

      private long lastRestockGameTime
    • numberOfRestocksToday

      private int numberOfRestocksToday
    • lastRestockCheckDayTime

      private long lastRestockCheckDayTime
    • assignProfessionWhenSpawned

      private boolean assignProfessionWhenSpawned
    • MEMORY_TYPES

      private static final com.google.common.collect.ImmutableList<MemoryModuleType<?>> MEMORY_TYPES
    • SENSOR_TYPES

      private static final com.google.common.collect.ImmutableList<SensorType<? extends Sensor<? super Villager>>> SENSOR_TYPES
    • POI_MEMORIES

      public static final Map<MemoryModuleType<GlobalPos>,BiPredicate<Villager,Holder<PoiType>>> POI_MEMORIES
  • Constructor Details

  • Method Details