Allow enabling constant burning
This commit is contained in:
parent
ecb58ffa76
commit
1dfecd54be
|
@ -8,7 +8,7 @@ maven_group=io.gitlab.jfronny
|
|||
archives_base_name=combit
|
||||
|
||||
fabric_version=0.45.0+1.18
|
||||
jfapi_version=2.2.2-1641673767
|
||||
jfapi_version=2.3.0
|
||||
|
||||
modrinth_id=oPRrsg3M
|
||||
curseforge_id=561742
|
|
@ -24,6 +24,7 @@ public class CombitConfig implements JfConfig {
|
|||
@Entry public static Boolean zombiesBurn = true;
|
||||
@Entry public static Boolean creepersBurn = false;
|
||||
@Entry public static Boolean creepersExplodeWhenBurning = false;
|
||||
@Entry public static Boolean alwaysBurn = false;
|
||||
// Health
|
||||
@Entry public static Double entityHealthFactor = 1.5;
|
||||
@Entry public static HashSet<String> entityHealthBlacklist = null;
|
||||
|
@ -82,6 +83,7 @@ public class CombitConfig implements JfConfig {
|
|||
zombiesBurn = true;
|
||||
creepersBurn = false;
|
||||
creepersExplodeWhenBurning = false;
|
||||
alwaysBurn = false;
|
||||
entityHealthFactor = 1.0;
|
||||
entityHealthBlacklist = null;
|
||||
cooldownProgressOverride = 0.8;
|
||||
|
@ -108,6 +110,7 @@ public class CombitConfig implements JfConfig {
|
|||
zombiesBurn = false;
|
||||
creepersBurn = true;
|
||||
creepersExplodeWhenBurning = true;
|
||||
alwaysBurn = true;
|
||||
entityHealthFactor = 10d;
|
||||
entityHealthBlacklist = null;
|
||||
cooldownProgressOverride = 1d;
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
package io.gitlab.jfronny.combit.mixin;
|
||||
|
||||
import io.gitlab.jfronny.combit.CombitConfig;
|
||||
import net.minecraft.entity.mob.MobEntity;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.injection.At;
|
||||
import org.spongepowered.asm.mixin.injection.Inject;
|
||||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
|
||||
|
||||
@Mixin(MobEntity.class)
|
||||
public class MobEntityMixin {
|
||||
@Inject(method = "isAffectedByDaylight()Z", at = @At("RETURN"), cancellable = true)
|
||||
private void modifyDaylight(CallbackInfoReturnable<Boolean> cir) {
|
||||
if (CombitConfig.alwaysBurn) cir.setReturnValue(true);
|
||||
}
|
||||
}
|
|
@ -26,6 +26,8 @@
|
|||
"combit.jfconfig.creepersBurn.tooltip": "Causes Creepers to burn in sunlight",
|
||||
"combit.jfconfig.creepersExplodeWhenBurning": "Creepers explode when burning",
|
||||
"combit.jfconfig.creepersExplodeWhenBurning.tooltip": "Causes creepers to explode when on fire. Do not combine with creepersBurn!",
|
||||
"combit.jfconfig.alwaysBurn": "Always burn",
|
||||
"combit.jfconfig.alwaysBurn.tooltip": "Makes mobs that burn in sunlight burn constantly",
|
||||
|
||||
"combit.jfconfig.entityHealthFactor": "Entity Health Factor",
|
||||
"combit.jfconfig.entityHealthFactor.tooltip": "Factor to apply to the maximum health of entities",
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
"HostileEntityMixin",
|
||||
"LivingEntityMixin",
|
||||
"MiningToolItemMixin",
|
||||
"MobEntityMixin",
|
||||
"PlayerEntityMixin",
|
||||
"SnowballEntityMixin",
|
||||
"ZombieEntityMixin"
|
||||
|
|
Loading…
Reference in New Issue