(World worldIn, BlockPos pos, IBlockState state, Random rand)
| 149 | } |
| 150 | |
| 151 | public void updateTick(World worldIn, BlockPos pos, IBlockState state, Random rand) |
| 152 | { |
| 153 | if (worldIn.getGameRules().getGameRuleBooleanValue("doFireTick")) |
| 154 | { |
| 155 | if (!this.canPlaceBlockAt(worldIn, pos)) |
| 156 | { |
| 157 | worldIn.setBlockToAir(pos); |
| 158 | } |
| 159 | |
| 160 | Block block = worldIn.getBlockState(pos.down()).getBlock(); |
| 161 | boolean flag = block == Blocks.netherrack; |
| 162 | |
| 163 | if (worldIn.provider instanceof WorldProviderEnd && block == Blocks.bedrock) |
| 164 | { |
| 165 | flag = true; |
| 166 | } |
| 167 | |
| 168 | if (!flag && worldIn.isRaining() && this.canDie(worldIn, pos)) |
| 169 | { |
| 170 | worldIn.setBlockToAir(pos); |
| 171 | } |
| 172 | else |
| 173 | { |
| 174 | int i = state.getValue(AGE); |
| 175 | |
| 176 | if (i < 15) |
| 177 | { |
| 178 | state = state.withProperty(AGE, i + rand.nextInt(3) / 2); |
| 179 | worldIn.setBlockState(pos, state, 4); |
| 180 | } |
| 181 | |
| 182 | worldIn.scheduleUpdate(pos, this, this.tickRate(worldIn) + rand.nextInt(10)); |
| 183 | |
| 184 | if (!flag) |
| 185 | { |
| 186 | if (!this.canNeighborCatchFire(worldIn, pos)) |
| 187 | { |
| 188 | if (!World.doesBlockHaveSolidTopSurface(worldIn, pos.down()) || i > 3) |
| 189 | { |
| 190 | worldIn.setBlockToAir(pos); |
| 191 | } |
| 192 | |
| 193 | return; |
| 194 | } |
| 195 | |
| 196 | if (!this.canCatchFire(worldIn, pos.down()) && i == 15 && rand.nextInt(4) == 0) |
| 197 | { |
| 198 | worldIn.setBlockToAir(pos); |
| 199 | return; |
| 200 | } |
| 201 | } |
| 202 | |
| 203 | boolean flag1 = worldIn.isBlockinHighHumidity(pos); |
| 204 | int j = 0; |
| 205 | |
| 206 | if (flag1) |
| 207 | { |
| 208 | j = -50; |
nothing calls this directly
no test coverage detected