Search in sources :

Example 86 with ICitizenData

use of com.minecolonies.api.colony.ICitizenData in project minecolonies by Minecolonies.

the class CitizenHappinessHandler method getSocialModifier.

/**
 * Get the social modifier for the colony.
 *
 * @param colony the colony.
 * @return true if so.
 */
private double getSocialModifier(final IColony colony) {
    final double total = colony.getCitizenManager().getCitizens().size();
    double unemployment = 0;
    double homelessness = 0;
    double sickPeople = 0;
    double hungryPeople = 0;
    for (final ICitizenData citizen : colony.getCitizenManager().getCitizens()) {
        if (!citizen.isChild() && citizen.getJob() == null) {
            unemployment++;
        }
        if (citizen.getHomeBuilding() == null) {
            homelessness++;
        }
        if (citizen.getEntity().isPresent() && citizen.getEntity().get().getCitizenDiseaseHandler().isSick()) {
            sickPeople++;
        }
        if (citizen.getSaturation() <= 1) {
            hungryPeople++;
        }
    }
    return (total - (unemployment + homelessness + sickPeople + hungryPeople)) / total;
}
Also used : ICitizenData(com.minecolonies.api.colony.ICitizenData)

Example 87 with ICitizenData

use of com.minecolonies.api.colony.ICitizenData in project minecolonies by Minecolonies.

the class EntityAIWorkUndertaker method tryResurrect.

/**
 * Attempt to resurrect buried citizen from its citizen data
 * Randomize to see if resurrection successful and resurrect if need be
 *
 * @return the next IAIState
 */
private IAIState tryResurrect() {
    @Nullable final BuildingGraveyard buildingGraveyard = building;
    if (checkForToolOrWeapon(ToolType.SHOVEL) || buildingGraveyard.getFirstModuleOccurance(GraveyardManagementModule.class).getLastGraveData() == null || buildingGraveyard.getGraveToWorkOn() == null) {
        return IDLE;
    }
    unequip();
    @Nullable final BlockPos gravePos = buildingGraveyard.getGraveToWorkOn();
    if (gravePos == null) {
        return IDLE;
    }
    // Still moving to the block
    if (walkToBlock(gravePos, 3)) {
        return getState();
    }
    final TileEntity entity = world.getBlockEntity(gravePos);
    if (entity instanceof TileEntityGrave) {
        if (effortCounter < EFFORT_RESURRECT) {
            worker.swing(Hand.MAIN_HAND);
            effortCounter += getSecondarySkillLevel();
            return getState();
        }
        effortCounter = 0;
        shouldDumpInventory = true;
        final double chance = getResurrectChance(buildingGraveyard);
        if (getTotemResurrectChance() > 0 && random.nextDouble() <= TOTEM_BREAK_CHANCE) {
            worker.getInventoryCitizen().extractItem(InventoryUtils.findFirstSlotInItemHandlerWith(worker.getInventoryCitizen(), Items.TOTEM_OF_UNDYING), 1, false);
            worker.playSound(SoundEvents.TOTEM_USE, 1.0f, 1.0f);
        }
        if (chance >= random.nextDouble()) {
            final ICitizenData citizenData = buildingGraveyard.getColony().getCitizenManager().resurrectCivilianData(buildingGraveyard.getFirstModuleOccurance(GraveyardManagementModule.class).getLastGraveData().getCitizenDataNBT(), true, world, gravePos);
            MessageUtils.format(MESSAGE_INFO_CITIZEN_UNDERTAKER_RESURRECTED_SUCCESS, citizenData.getName()).sendTo(buildingGraveyard.getColony()).forManagers();
            worker.getCitizenColonyHandler().getColony().getCitizenManager().updateCitizenMourn(citizenData, false);
            AdvancementUtils.TriggerAdvancementPlayersForColony(worker.getCitizenColonyHandler().getColony(), playerMP -> AdvancementTriggers.CITIZEN_RESURRECT.trigger(playerMP));
            buildingGraveyard.getFirstModuleOccurance(GraveyardManagementModule.class).setLastGraveData(null);
            world.setBlockAndUpdate(gravePos, Blocks.AIR.defaultBlockState());
            return INVENTORY_FULL;
        }
    }
    return DIG_GRAVE;
}
Also used : TileEntity(net.minecraft.tileentity.TileEntity) BuildingGraveyard(com.minecolonies.coremod.colony.buildings.workerbuildings.BuildingGraveyard) ICitizenData(com.minecolonies.api.colony.ICitizenData) BlockPos(net.minecraft.util.math.BlockPos) TileEntityGrave(com.minecolonies.api.tileentities.TileEntityGrave) Nullable(org.jetbrains.annotations.Nullable) GraveyardManagementModule(com.minecolonies.coremod.colony.buildings.modules.GraveyardManagementModule)

Example 88 with ICitizenData

use of com.minecolonies.api.colony.ICitizenData in project minecolonies by Minecolonies.

the class EntityAIEatTask method hasFood.

/**
 * Checks if the citizen has food in the inventory and makes a decision based on that.
 *
 * @return the next state to go to.
 */
private boolean hasFood() {
    final int slot = InventoryUtils.findFirstSlotInProviderNotEmptyWith(citizen, stack -> CAN_EAT.test(stack) && canEat(citizen.getCitizenData(), stack));
    if (slot != -1) {
        foodSlot = slot;
        return true;
    }
    final ICitizenData citizenData = citizen.getCitizenData();
    if (InventoryUtils.hasItemInItemHandler(citizen.getInventoryCitizen(), ISCOOKABLE)) {
        citizenData.triggerInteraction(new StandardInteraction(new TranslationTextComponent(RAW_FOOD), ChatPriority.PENDING));
    } else if (InventoryUtils.hasItemInItemHandler(citizen.getInventoryCitizen(), stack -> CAN_EAT.test(stack) && !canEat(citizenData, stack))) {
        if (citizenData.isChild()) {
            citizenData.triggerInteraction(new StandardInteraction(new TranslationTextComponent(BETTER_FOOD_CHILDREN), ChatPriority.BLOCKING));
        } else {
            citizenData.triggerInteraction(new StandardInteraction(new TranslationTextComponent(BETTER_FOOD), ChatPriority.BLOCKING));
        }
    }
    return false;
}
Also used : SittingEntity(com.minecolonies.coremod.entity.SittingEntity) SATURATION(com.minecolonies.api.research.util.ResearchConstants.SATURATION) BuildingCook(com.minecolonies.coremod.colony.buildings.workerbuildings.BuildingCook) TickingTransition(com.minecolonies.api.entity.ai.statemachine.tickratestatemachine.TickingTransition) ICitizenData(com.minecolonies.api.colony.ICitizenData) ItemParticleEffectMessage(com.minecolonies.coremod.network.messages.client.ItemParticleEffectMessage) AdvancementUtils(com.minecolonies.coremod.util.AdvancementUtils) LOW_SATURATION(com.minecolonies.api.util.constant.CitizenConstants.LOW_SATURATION) SEEK_DOCTOR_HEALTH(com.minecolonies.coremod.entity.citizen.citizenhandlers.CitizenDiseaseHandler.SEEK_DOCTOR_HEALTH) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent) Goal(net.minecraft.entity.ai.goal.Goal) CAN_EAT(com.minecolonies.api.util.ItemStackUtils.CAN_EAT) Hand(net.minecraft.util.Hand) Network(com.minecolonies.coremod.Network) Log(com.minecolonies.api.util.Log) CitizenConstants(com.minecolonies.api.util.constant.CitizenConstants) TICKS_SECOND(com.minecolonies.api.util.constant.Constants.TICKS_SECOND) EnumSet(java.util.EnumSet) ItemListModule(com.minecolonies.coremod.colony.buildings.modules.ItemListModule) TickRateStateMachine(com.minecolonies.api.entity.ai.statemachine.tickratestatemachine.TickRateStateMachine) TranslationConstants(com.minecolonies.api.util.constant.TranslationConstants) SECONDS_A_MINUTE(com.minecolonies.api.util.constant.Constants.SECONDS_A_MINUTE) DesiredActivity(com.minecolonies.api.entity.ai.DesiredActivity) EatingState(com.minecolonies.coremod.entity.ai.minimal.EntityAIEatTask.EatingState) VisibleCitizenStatus(com.minecolonies.api.entity.citizen.VisibleCitizenStatus) ChatPriority(com.minecolonies.api.colony.interactionhandling.ChatPriority) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) net.minecraft.item(net.minecraft.item) BlockPos(net.minecraft.util.math.BlockPos) SoundUtils(com.minecolonies.api.util.SoundUtils) BASIC_VOLUME(com.minecolonies.api.util.constant.GuardConstants.BASIC_VOLUME) SoundEvents(net.minecraft.util.SoundEvents) AdvancementTriggers(com.minecolonies.api.advancements.AdvancementTriggers) ISCOOKABLE(com.minecolonies.api.util.ItemStackUtils.ISCOOKABLE) EntityCitizen(com.minecolonies.coremod.entity.citizen.EntityCitizen) IBuilding(com.minecolonies.api.colony.buildings.IBuilding) InventoryUtils(com.minecolonies.api.util.InventoryUtils) IColony(com.minecolonies.api.colony.IColony) AbstractJobGuard(com.minecolonies.coremod.colony.jobs.AbstractJobGuard) IState(com.minecolonies.api.entity.ai.statemachine.states.IState) ItemStorage(com.minecolonies.api.crafting.ItemStorage) WorldUtil(com.minecolonies.api.util.WorldUtil) IJob(com.minecolonies.api.colony.jobs.IJob) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) ICitizenData(com.minecolonies.api.colony.ICitizenData) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent)

Example 89 with ICitizenData

use of com.minecolonies.api.colony.ICitizenData in project minecolonies by Minecolonies.

the class EntityAIWorkHealer method decide.

/**
 * Decide what to do next. Check if all patients are up date, else update their states. Then check if there is any patient we can cure or request things for.
 *
 * @return the next state to go to.
 */
private IAIState decide() {
    if (walkToBuilding()) {
        return DECIDE;
    }
    final BuildingHospital hospital = building;
    for (final AbstractEntityCitizen citizen : WorldUtil.getEntitiesWithinBuilding(world, AbstractEntityCitizen.class, building, cit -> cit.getCitizenDiseaseHandler().isSick())) {
        hospital.checkOrCreatePatientFile(citizen.getCivilianID());
    }
    for (final Patient patient : hospital.getPatients()) {
        final ICitizenData data = hospital.getColony().getCitizenManager().getCivilian(patient.getId());
        if (data == null || !data.getEntity().isPresent() || (data.getEntity().isPresent() && !data.getEntity().get().getCitizenDiseaseHandler().isSick())) {
            hospital.removePatientFile(patient);
            continue;
        }
        final EntityCitizen citizen = (EntityCitizen) data.getEntity().get();
        final String diseaseName = citizen.getCitizenDiseaseHandler().getDisease();
        @Nullable final Disease disease = diseaseName.isEmpty() ? null : IColonyManager.getInstance().getCompatibilityManager().getDisease(diseaseName);
        if (patient.getState() == Patient.PatientState.NEW) {
            this.currentPatient = patient;
            return REQUEST_CURE;
        }
        if (patient.getState() == Patient.PatientState.REQUESTED) {
            if (disease == null) {
                this.currentPatient = patient;
                return CURE;
            }
            if (testRandomCureChance()) {
                this.currentPatient = patient;
                return FREE_CURE;
            }
            if (!InventoryUtils.isItemHandlerFull(citizen.getInventoryCitizen())) {
                if (hasCureInInventory(disease, worker.getInventoryCitizen()) || hasCureInInventory(disease, building.getCapability(CapabilityItemHandler.ITEM_HANDLER_CAPABILITY).orElseGet(null))) {
                    this.currentPatient = patient;
                    return CURE;
                }
                final ImmutableList<IRequest<? extends Stack>> list = building.getOpenRequestsOfType(worker.getCitizenData().getId(), TypeToken.of(Stack.class));
                final ImmutableList<IRequest<? extends Stack>> completed = building.getCompletedRequestsOfType(worker.getCitizenData(), TypeToken.of(Stack.class));
                for (final ItemStack cure : IColonyManager.getInstance().getCompatibilityManager().getDisease(diseaseName).getCure()) {
                    if (!InventoryUtils.hasItemInItemHandler(worker.getInventoryCitizen(), cure::sameItem)) {
                        if (InventoryUtils.getItemCountInItemHandler(building.getCapability(CapabilityItemHandler.ITEM_HANDLER_CAPABILITY).orElseGet(null), stack -> stack.sameItem(cure)) >= cure.getCount()) {
                            needsCurrently = new Tuple<>(stack -> stack.sameItem(cure), cure.getCount());
                            return GATHERING_REQUIRED_MATERIALS;
                        }
                        boolean hasCureRequested = false;
                        for (final IRequest<? extends Stack> request : list) {
                            if (request.getRequest().getStack().sameItem(cure)) {
                                hasCureRequested = true;
                                break;
                            }
                        }
                        for (final IRequest<? extends Stack> request : completed) {
                            if (request.getRequest().getStack().sameItem(cure)) {
                                hasCureRequested = true;
                                break;
                            }
                        }
                        if (!hasCureRequested) {
                            patient.setState(Patient.PatientState.NEW);
                            break;
                        }
                    }
                }
            } else {
                data.triggerInteraction(new StandardInteraction(new TranslationTextComponent(PATIENT_FULL_INVENTORY), ChatPriority.BLOCKING));
            }
        }
        if (patient.getState() == Patient.PatientState.TREATED) {
            if (disease == null) {
                this.currentPatient = patient;
                return CURE;
            }
            if (!hasCureInInventory(disease, citizen.getInventoryCitizen())) {
                patient.setState(Patient.PatientState.NEW);
                return DECIDE;
            }
        }
    }
    for (final PlayerEntity player : WorldUtil.getEntitiesWithinBuilding(world, PlayerEntity.class, building, player -> player.getHealth() < player.getMaxHealth() - 10 - (2 * building.getBuildingLevel()))) {
        playerToHeal = player;
        return CURE_PLAYER;
    }
    final ICitizenData data = building.getColony().getCitizenManager().getRandomCitizen();
    if (data.getEntity().isPresent() && data.getEntity().get().getHealth() < 10.0 && BlockPosUtil.getDistance2D(data.getEntity().get().blockPosition(), building.getPosition()) < building.getBuildingLevel() * 40) {
        remotePatient = data;
        return WANDER;
    }
    return DECIDE;
}
Also used : IItemHandler(net.minecraftforge.items.IItemHandler) IRequest(com.minecolonies.api.colony.requestsystem.request.IRequest) ICitizenData(com.minecolonies.api.colony.ICitizenData) TypeToken(com.google.common.reflect.TypeToken) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent) ItemStack(net.minecraft.item.ItemStack) ImmutableList(com.google.common.collect.ImmutableList) IAIState(com.minecolonies.api.entity.ai.statemachine.states.IAIState) JobHealer(com.minecolonies.coremod.colony.jobs.JobHealer) AITarget(com.minecolonies.api.entity.ai.statemachine.AITarget) com.minecolonies.api.util(com.minecolonies.api.util) Network(com.minecolonies.coremod.Network) PATIENT_FULL_INVENTORY(com.minecolonies.api.util.constant.TranslationConstants.PATIENT_FULL_INVENTORY) StreamParticleEffectMessage(com.minecolonies.coremod.network.messages.client.StreamParticleEffectMessage) Stack(com.minecolonies.api.colony.requestsystem.requestable.Stack) AbstractEntityAIInteract(com.minecolonies.coremod.entity.ai.basic.AbstractEntityAIInteract) PlayerEntity(net.minecraft.entity.player.PlayerEntity) CircleParticleEffectMessage(com.minecolonies.coremod.network.messages.client.CircleParticleEffectMessage) IColonyManager(com.minecolonies.api.colony.IColonyManager) ChatPriority(com.minecolonies.api.colony.interactionhandling.ChatPriority) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) BlockPos(net.minecraft.util.math.BlockPos) AIWorkerState(com.minecolonies.api.entity.ai.statemachine.states.AIWorkerState) ParticleTypes(net.minecraft.particles.ParticleTypes) Nullable(org.jetbrains.annotations.Nullable) AbstractEntityCitizen(com.minecolonies.api.entity.citizen.AbstractEntityCitizen) BuildingHospital(com.minecolonies.coremod.colony.buildings.workerbuildings.BuildingHospital) EntityCitizen(com.minecolonies.coremod.entity.citizen.EntityCitizen) CapabilityItemHandler(net.minecraftforge.items.CapabilityItemHandler) NotNull(org.jetbrains.annotations.NotNull) BuildingHospital(com.minecolonies.coremod.colony.buildings.workerbuildings.BuildingHospital) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) AbstractEntityCitizen(com.minecolonies.api.entity.citizen.AbstractEntityCitizen) ICitizenData(com.minecolonies.api.colony.ICitizenData) ItemStack(net.minecraft.item.ItemStack) Stack(com.minecolonies.api.colony.requestsystem.requestable.Stack) PlayerEntity(net.minecraft.entity.player.PlayerEntity) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent) IRequest(com.minecolonies.api.colony.requestsystem.request.IRequest) AbstractEntityCitizen(com.minecolonies.api.entity.citizen.AbstractEntityCitizen) EntityCitizen(com.minecolonies.coremod.entity.citizen.EntityCitizen) ItemStack(net.minecraft.item.ItemStack) Nullable(org.jetbrains.annotations.Nullable)

Example 90 with ICitizenData

use of com.minecolonies.api.colony.ICitizenData in project minecolonies by Minecolonies.

the class EntityAIWorkHealer method cure.

/**
 * Give a citizen the cure.
 *
 * @return the next state to go to.
 */
private IAIState cure() {
    if (currentPatient == null) {
        return DECIDE;
    }
    final ICitizenData data = building.getColony().getCitizenManager().getCivilian(currentPatient.getId());
    if (data == null || !data.getEntity().isPresent() || !data.getEntity().get().getCitizenDiseaseHandler().isSick()) {
        currentPatient = null;
        return DECIDE;
    }
    final EntityCitizen citizen = (EntityCitizen) data.getEntity().get();
    if (walkToBlock(data.getEntity().get().blockPosition())) {
        return CURE;
    }
    final String diseaseName = citizen.getCitizenDiseaseHandler().getDisease();
    final Disease disease = IColonyManager.getInstance().getCompatibilityManager().getDisease(diseaseName);
    if (diseaseName.isEmpty()) {
        currentPatient = null;
        citizen.heal(10);
        worker.getCitizenExperienceHandler().addExperience(BASE_XP_GAIN);
        citizen.markDirty();
        return DECIDE;
    }
    if (!hasCureInInventory(disease, worker.getInventoryCitizen())) {
        if (hasCureInInventory(disease, building.getCapability(CapabilityItemHandler.ITEM_HANDLER_CAPABILITY).orElseGet(null))) {
            for (final ItemStack cure : disease.getCure()) {
                if (InventoryUtils.getItemCountInItemHandler(worker.getInventoryCitizen(), stack -> stack.sameItem(cure)) < cure.getCount()) {
                    needsCurrently = new Tuple<>(stack -> stack.sameItem(cure), 1);
                    return GATHERING_REQUIRED_MATERIALS;
                }
            }
        }
        currentPatient = null;
        return DECIDE;
    }
    if (!hasCureInInventory(disease, citizen.getInventoryCitizen())) {
        for (final ItemStack cure : disease.getCure()) {
            if (InventoryUtils.getItemCountInItemHandler(citizen.getInventoryCitizen(), stack -> stack.sameItem(cure)) < cure.getCount()) {
                if (InventoryUtils.isItemHandlerFull(citizen.getInventoryCitizen())) {
                    data.triggerInteraction(new StandardInteraction(new TranslationTextComponent(PATIENT_FULL_INVENTORY), ChatPriority.BLOCKING));
                    currentPatient = null;
                    return DECIDE;
                }
                InventoryUtils.transferXOfFirstSlotInItemHandlerWithIntoNextFreeSlotInItemHandler(worker.getInventoryCitizen(), cure::sameItem, cure.getCount(), citizen.getInventoryCitizen());
            }
        }
    }
    worker.getCitizenExperienceHandler().addExperience(BASE_XP_GAIN);
    currentPatient.setState(Patient.PatientState.TREATED);
    currentPatient = null;
    return DECIDE;
}
Also used : IItemHandler(net.minecraftforge.items.IItemHandler) IRequest(com.minecolonies.api.colony.requestsystem.request.IRequest) ICitizenData(com.minecolonies.api.colony.ICitizenData) TypeToken(com.google.common.reflect.TypeToken) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent) ItemStack(net.minecraft.item.ItemStack) ImmutableList(com.google.common.collect.ImmutableList) IAIState(com.minecolonies.api.entity.ai.statemachine.states.IAIState) JobHealer(com.minecolonies.coremod.colony.jobs.JobHealer) AITarget(com.minecolonies.api.entity.ai.statemachine.AITarget) com.minecolonies.api.util(com.minecolonies.api.util) Network(com.minecolonies.coremod.Network) PATIENT_FULL_INVENTORY(com.minecolonies.api.util.constant.TranslationConstants.PATIENT_FULL_INVENTORY) StreamParticleEffectMessage(com.minecolonies.coremod.network.messages.client.StreamParticleEffectMessage) Stack(com.minecolonies.api.colony.requestsystem.requestable.Stack) AbstractEntityAIInteract(com.minecolonies.coremod.entity.ai.basic.AbstractEntityAIInteract) PlayerEntity(net.minecraft.entity.player.PlayerEntity) CircleParticleEffectMessage(com.minecolonies.coremod.network.messages.client.CircleParticleEffectMessage) IColonyManager(com.minecolonies.api.colony.IColonyManager) ChatPriority(com.minecolonies.api.colony.interactionhandling.ChatPriority) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) BlockPos(net.minecraft.util.math.BlockPos) AIWorkerState(com.minecolonies.api.entity.ai.statemachine.states.AIWorkerState) ParticleTypes(net.minecraft.particles.ParticleTypes) Nullable(org.jetbrains.annotations.Nullable) AbstractEntityCitizen(com.minecolonies.api.entity.citizen.AbstractEntityCitizen) BuildingHospital(com.minecolonies.coremod.colony.buildings.workerbuildings.BuildingHospital) EntityCitizen(com.minecolonies.coremod.entity.citizen.EntityCitizen) CapabilityItemHandler(net.minecraftforge.items.CapabilityItemHandler) NotNull(org.jetbrains.annotations.NotNull) StandardInteraction(com.minecolonies.coremod.colony.interactionhandling.StandardInteraction) ICitizenData(com.minecolonies.api.colony.ICitizenData) TranslationTextComponent(net.minecraft.util.text.TranslationTextComponent) AbstractEntityCitizen(com.minecolonies.api.entity.citizen.AbstractEntityCitizen) EntityCitizen(com.minecolonies.coremod.entity.citizen.EntityCitizen) ItemStack(net.minecraft.item.ItemStack)

Aggregations

ICitizenData (com.minecolonies.api.colony.ICitizenData)180 NotNull (org.jetbrains.annotations.NotNull)49 BlockPos (net.minecraft.util.math.BlockPos)47 IColony (com.minecolonies.api.colony.IColony)46 AbstractEntityCitizen (com.minecolonies.api.entity.citizen.AbstractEntityCitizen)40 IBuilding (com.minecolonies.api.colony.buildings.IBuilding)33 TranslationTextComponent (net.minecraft.util.text.TranslationTextComponent)31 ItemStack (net.minecraft.item.ItemStack)28 WorkerBuildingModule (com.minecolonies.coremod.colony.buildings.modules.WorkerBuildingModule)23 PlayerEntity (net.minecraft.entity.player.PlayerEntity)23 IRequest (com.minecolonies.api.colony.requestsystem.request.IRequest)22 Nullable (org.jetbrains.annotations.Nullable)22 CompoundNBT (net.minecraft.nbt.CompoundNBT)18 Colony (com.minecolonies.coremod.colony.Colony)16 ArrayList (java.util.ArrayList)16 AbstractJobCrafter (com.minecolonies.coremod.colony.jobs.AbstractJobCrafter)14 EntityCitizen (com.minecolonies.coremod.entity.citizen.EntityCitizen)14 ServerPlayerEntity (net.minecraft.entity.player.ServerPlayerEntity)13 AbstractAssignedCitizenModule (com.minecolonies.coremod.colony.buildings.modules.AbstractAssignedCitizenModule)12 java.util (java.util)12