Class Raid


  • public class Raid
    extends java.lang.Object
    • Field Detail

      • RAID_NAME_COMPONENT

        private static final ITextComponent RAID_NAME_COMPONENT
      • RAID_BAR_VICTORY_COMPONENT

        private static final ITextComponent RAID_BAR_VICTORY_COMPONENT
      • RAID_BAR_DEFEAT_COMPONENT

        private static final ITextComponent RAID_BAR_DEFEAT_COMPONENT
      • groupToLeaderMap

        private final java.util.Map<java.lang.Integer,​AbstractRaiderEntity> groupToLeaderMap
      • groupRaiderMap

        private final java.util.Map<java.lang.Integer,​java.util.Set<AbstractRaiderEntity>> groupRaiderMap
      • heroesOfTheVillage

        private final java.util.Set<java.util.UUID> heroesOfTheVillage
      • ticksActive

        private long ticksActive
      • started

        private boolean started
      • id

        private final int id
      • totalHealth

        private float totalHealth
      • badOmenLevel

        private int badOmenLevel
      • active

        private boolean active
      • groupsSpawned

        private int groupsSpawned
      • postRaidTicks

        private int postRaidTicks
      • raidCooldownTicks

        private int raidCooldownTicks
      • random

        private final java.util.Random random
      • numGroups

        private final int numGroups
      • celebrationTicks

        private int celebrationTicks
      • waveSpawnPos

        private java.util.Optional<BlockPos> waveSpawnPos
    • Method Detail

      • isOver

        public boolean isOver()
      • isBetweenWaves

        public boolean isBetweenWaves()
      • hasFirstWaveSpawned

        public boolean hasFirstWaveSpawned()
      • isStopped

        public boolean isStopped()
      • isVictory

        public boolean isVictory()
      • isLoss

        public boolean isLoss()
      • getLevel

        public World getLevel()
      • isStarted

        public boolean isStarted()
      • getGroupsSpawned

        public int getGroupsSpawned()
      • updatePlayers

        private void updatePlayers()
      • getMaxBadOmenLevel

        public int getMaxBadOmenLevel()
      • getBadOmenLevel

        public int getBadOmenLevel()
      • absorbBadOmen

        public void absorbBadOmen​(PlayerEntity p_221309_1_)
      • stop

        public void stop()
      • tick

        public void tick()
      • moveRaidCenterToNearbyVillageSection

        private void moveRaidCenterToNearbyVillageSection()
      • getValidSpawnPos

        private java.util.Optional<BlockPos> getValidSpawnPos​(int p_221313_1_)
      • hasMoreWaves

        private boolean hasMoreWaves()
      • isFinalWave

        private boolean isFinalWave()
      • hasBonusWave

        private boolean hasBonusWave()
      • hasSpawnedBonusWave

        private boolean hasSpawnedBonusWave()
      • shouldSpawnBonusGroup

        private boolean shouldSpawnBonusGroup()
      • updateRaiders

        private void updateRaiders()
      • playSound

        private void playSound​(BlockPos p_221293_1_)
      • spawnGroup

        private void spawnGroup​(BlockPos p_221294_1_)
      • joinRaid

        public void joinRaid​(int p_221317_1_,
                             AbstractRaiderEntity p_221317_2_,
                             @Nullable
                             BlockPos p_221317_3_,
                             boolean p_221317_4_)
      • updateBossbar

        public void updateBossbar()
      • getHealthOfLivingRaiders

        public float getHealthOfLivingRaiders()
      • shouldSpawnGroup

        private boolean shouldSpawnGroup()
      • getTotalRaidersAlive

        public int getTotalRaidersAlive()
      • removeFromRaid

        public void removeFromRaid​(AbstractRaiderEntity p_221322_1_,
                                   boolean p_221322_2_)
      • setDirty

        private void setDirty()
      • getLeaderBannerInstance

        public static ItemStack getLeaderBannerInstance()
      • findRandomSpawnPos

        @Nullable
        private BlockPos findRandomSpawnPos​(int p_221298_1_,
                                            int p_221298_2_)
      • addWaveMob

        public boolean addWaveMob​(int p_221300_1_,
                                  AbstractRaiderEntity p_221300_2_,
                                  boolean p_221300_3_)
      • removeLeader

        public void removeLeader​(int p_221296_1_)
      • getCenter

        public BlockPos getCenter()
      • setCenter

        private void setCenter​(BlockPos p_223024_1_)
      • getId

        public int getId()
      • getDefaultNumSpawns

        private int getDefaultNumSpawns​(Raid.WaveMember p_221330_1_,
                                        int p_221330_2_,
                                        boolean p_221330_3_)
      • getPotentialBonusSpawns

        private int getPotentialBonusSpawns​(Raid.WaveMember p_221335_1_,
                                            java.util.Random p_221335_2_,
                                            int p_221335_3_,
                                            DifficultyInstance p_221335_4_,
                                            boolean p_221335_5_)
      • isActive

        public boolean isActive()
      • getNumGroups

        public int getNumGroups​(Difficulty p_221306_1_)
      • getEnchantOdds

        public float getEnchantOdds()
      • addHeroOfTheVillage

        public void addHeroOfTheVillage​(Entity p_221311_1_)