feat: armadilloImmediateDespawns

This commit is contained in:
zly2006 committed 2024-07-17 06:16:16 +08:00
1 parent c7ffec6782
commit 75594d970e
8 files changed
+37 -18

No files matched your search

@@ -8,67 +8,55 @@ public class SLSCarpetSettings {
public static final String FROM_AMS = "AMS";
public static final String SLSA = "SLS";
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.SURVIVAL})
public static boolean obtainableReinforcedDeepSlate = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
public static boolean creativeNoInfinitePickup = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.OPTIMIZATION})
public static boolean noBatSpawning = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean canUseHatCommand = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean canUseSitCommand = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA}, strict = false, options = {"#none"})
@Rule(categories = {SLSA}, strict = false, options = {"#none", "bot_"})
public static String botPrefix = "#none";
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA})
public static long botMaxOnlineTime = -1;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean creativeObeyEnchantmentRule = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean fakePlayersNotOccupiedSleepQuota = false;
/** From Plusls Carpet Addition **/
@Rule(categories = {SLSA, RuleCategory.FEATURE, NEED_CLIENT})
public static boolean emptyShulkerBoxStack = false;
/** From Plusls Carpet Addition **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean playerSit = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean endermanCanPickUpMushroom = true;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
public static boolean oldRedstoneConnectionLogic = false;
/** From Carpet AMS Addition **/
// Ported from Carpet AMS Addition
@Rule(categories = {SLSA, FROM_AMS, RuleCategory.OPTIMIZATION})
public static boolean optimizedOnDragonRespawn = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean elytraCraftable = false;
/** Carpet SLS Addition original **/
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean spectatorCannotUseLeash = false;
@Rule(categories = {SLSA, RuleCategory.FEATURE})
public static boolean armadilloImmediateDespawns = false;
}
@@ -0,0 +1,20 @@
package com.github.zly2006.carpetslsaddition.mixin.entity;
import com.github.zly2006.carpetslsaddition.SLSCarpetSettings;
import net.minecraft.entity.EntityType;
import net.minecraft.entity.passive.AnimalEntity;
import net.minecraft.entity.passive.ArmadilloEntity;
import net.minecraft.world.World;
import org.spongepowered.asm.mixin.Mixin;
@Mixin(ArmadilloEntity.class)
public abstract class MixinArmadilloEntity extends AnimalEntity {
protected MixinArmadilloEntity(EntityType<? extends AnimalEntity> entityType, World world) {
super(entityType, world);
}
@Override
public boolean canImmediatelyDespawn(double distanceSquared) {
return SLSCarpetSettings.armadilloImmediateDespawns;
}
}