mirror of
https://github.com/Creators-of-Create/Create.git
synced 2024-12-24 14:06:42 +01:00
Fix AirCurrent damage handling
This commit is contained in:
parent
a7ad1c423a
commit
21cdea67f6
1 changed files with 13 additions and 4 deletions
|
@ -17,7 +17,9 @@ import com.simibubi.create.modules.logistics.InWorldProcessing.Type;
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.block.Blocks;
|
import net.minecraft.block.Blocks;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.entity.EntityType;
|
||||||
import net.minecraft.entity.item.ItemEntity;
|
import net.minecraft.entity.item.ItemEntity;
|
||||||
|
import net.minecraft.entity.monster.EndermanEntity;
|
||||||
import net.minecraft.entity.player.ServerPlayerEntity;
|
import net.minecraft.entity.player.ServerPlayerEntity;
|
||||||
import net.minecraft.nbt.CompoundNBT;
|
import net.minecraft.nbt.CompoundNBT;
|
||||||
import net.minecraft.state.properties.BlockStateProperties;
|
import net.minecraft.state.properties.BlockStateProperties;
|
||||||
|
@ -113,14 +115,21 @@ public class AirCurrent {
|
||||||
} else {
|
} else {
|
||||||
switch (processingType) {
|
switch (processingType) {
|
||||||
case BLASTING:
|
case BLASTING:
|
||||||
entity.setFire(10);
|
if (!entity.isImmuneToFire()) {
|
||||||
entity.attackEntityFrom(damageSourceLava, 4);
|
entity.setFire(10);
|
||||||
|
entity.attackEntityFrom(damageSourceLava, 4);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case SMOKING:
|
case SMOKING:
|
||||||
entity.setFire(2);
|
if (!entity.isImmuneToFire()) {
|
||||||
entity.attackEntityFrom(damageSourceFire, 2);
|
entity.setFire(2);
|
||||||
|
entity.attackEntityFrom(damageSourceFire, 2);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case SPLASHING:
|
case SPLASHING:
|
||||||
|
if (entity instanceof EndermanEntity || entity.getType() == EntityType.SNOW_GOLEM || entity.getType() == EntityType.BLAZE) {
|
||||||
|
entity.attackEntityFrom(DamageSource.DROWN, 2);
|
||||||
|
}
|
||||||
if (!entity.isBurning())
|
if (!entity.isBurning())
|
||||||
break;
|
break;
|
||||||
entity.extinguish();
|
entity.extinguish();
|
||||||
|
|
Loading…
Reference in a new issue