feat: armadilloImmediateDespawns
This commit is contained in:
8 files changed
+37
-18
No files matched your search
+1
-1
@@ -9,7 +9,7 @@ org.gradle.jvmargs=-Xmx1G
|
|||||||
|
|
||||||
|
|
||||||
# Mod Properties
|
# Mod Properties
|
||||||
mod_version = 0.21.1
|
mod_version = 0.22
|
||||||
maven_group = com.github.zly2006
|
maven_group = com.github.zly2006
|
||||||
archives_base_name = carpet-sls-addition
|
archives_base_name = carpet-sls-addition
|
||||||
|
|
||||||
|
|||||||
@@ -79,3 +79,7 @@ datapack enable elytra-craftable
|
|||||||
### spectatorCannotUseLeash
|
### spectatorCannotUseLeash
|
||||||
|
|
||||||
When player becomes spectator, the leash will be detached.
|
When player becomes spectator, the leash will be detached.
|
||||||
|
|
||||||
|
### armadilloImmediateDespawns
|
||||||
|
|
||||||
|
Armadillos will despawn immediately if they are 128 blocks away from the player.
|
||||||
@@ -80,3 +80,7 @@ datapack enable elytra-craftable
|
|||||||
### spectatorCannotUseLeash
|
### spectatorCannotUseLeash
|
||||||
|
|
||||||
当玩家成为旁观者时,拴绳将断开。
|
当玩家成为旁观者时,拴绳将断开。
|
||||||
|
|
||||||
|
### armadilloImmediateDespawns
|
||||||
|
|
||||||
|
当犰狳距离玩家超过 128 格时,它们将立即消失。
|
||||||
@@ -8,67 +8,55 @@ public class SLSCarpetSettings {
|
|||||||
public static final String FROM_AMS = "AMS";
|
public static final String FROM_AMS = "AMS";
|
||||||
public static final String SLSA = "SLS";
|
public static final String SLSA = "SLS";
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.SURVIVAL})
|
@Rule(categories = {SLSA, RuleCategory.SURVIVAL})
|
||||||
public static boolean obtainableReinforcedDeepSlate = false;
|
public static boolean obtainableReinforcedDeepSlate = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
|
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
|
||||||
public static boolean creativeNoInfinitePickup = false;
|
public static boolean creativeNoInfinitePickup = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.OPTIMIZATION})
|
@Rule(categories = {SLSA, RuleCategory.OPTIMIZATION})
|
||||||
public static boolean noBatSpawning = false;
|
public static boolean noBatSpawning = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean canUseHatCommand = false;
|
public static boolean canUseHatCommand = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean canUseSitCommand = false;
|
public static boolean canUseSitCommand = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
@Rule(categories = {SLSA}, strict = false, options = {"#none", "bot_"})
|
||||||
@Rule(categories = {SLSA}, strict = false, options = {"#none"})
|
|
||||||
public static String botPrefix = "#none";
|
public static String botPrefix = "#none";
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA})
|
@Rule(categories = {SLSA})
|
||||||
public static long botMaxOnlineTime = -1;
|
public static long botMaxOnlineTime = -1;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean creativeObeyEnchantmentRule = false;
|
public static boolean creativeObeyEnchantmentRule = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean fakePlayersNotOccupiedSleepQuota = false;
|
public static boolean fakePlayersNotOccupiedSleepQuota = false;
|
||||||
|
|
||||||
/** From Plusls Carpet Addition **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE, NEED_CLIENT})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE, NEED_CLIENT})
|
||||||
public static boolean emptyShulkerBoxStack = false;
|
public static boolean emptyShulkerBoxStack = false;
|
||||||
|
|
||||||
/** From Plusls Carpet Addition **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean playerSit = false;
|
public static boolean playerSit = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean endermanCanPickUpMushroom = true;
|
public static boolean endermanCanPickUpMushroom = true;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
|
@Rule(categories = {SLSA, RuleCategory.CREATIVE})
|
||||||
public static boolean oldRedstoneConnectionLogic = false;
|
public static boolean oldRedstoneConnectionLogic = false;
|
||||||
|
|
||||||
/** From Carpet AMS Addition **/
|
// Ported from Carpet AMS Addition
|
||||||
@Rule(categories = {SLSA, FROM_AMS, RuleCategory.OPTIMIZATION})
|
@Rule(categories = {SLSA, FROM_AMS, RuleCategory.OPTIMIZATION})
|
||||||
public static boolean optimizedOnDragonRespawn = false;
|
public static boolean optimizedOnDragonRespawn = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean elytraCraftable = false;
|
public static boolean elytraCraftable = false;
|
||||||
|
|
||||||
/** Carpet SLS Addition original **/
|
|
||||||
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
public static boolean spectatorCannotUseLeash = false;
|
public static boolean spectatorCannotUseLeash = false;
|
||||||
|
|
||||||
|
@Rule(categories = {SLSA, RuleCategory.FEATURE})
|
||||||
|
public static boolean armadilloImmediateDespawns = false;
|
||||||
}
|
}
|
||||||
+20
@@ -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;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -48,6 +48,7 @@
|
|||||||
"carpet.rule.elytraCraftable.desc": "Make elytra craftable for Minecraft 1.20.6+ (eltra wont disappear when crafting)",
|
"carpet.rule.elytraCraftable.desc": "Make elytra craftable for Minecraft 1.20.6+ (eltra wont disappear when crafting)",
|
||||||
"carpet.rule.botMaxOnlineTime.desc": "Set the maximum living time of the bot which create by carpet sls addition.",
|
"carpet.rule.botMaxOnlineTime.desc": "Set the maximum living time of the bot which create by carpet sls addition.",
|
||||||
"carpet.rule.spectatorCannotUseLeash.desc": "If a player is a spectator, they cannot use the leash.",
|
"carpet.rule.spectatorCannotUseLeash.desc": "If a player is a spectator, they cannot use the leash.",
|
||||||
|
"carpet.rule.armadilloImmediateDespawns.desc": "Armadillos will despawn immediately if they are 128 blocks away from the player.",
|
||||||
|
|
||||||
"carpet.rule.skipTicksForJoblessVillager.extra.0": "Set to 0 to maintain the vanilla behavior",
|
"carpet.rule.skipTicksForJoblessVillager.extra.0": "Set to 0 to maintain the vanilla behavior",
|
||||||
"carpet.rule.skipTicksForJoblessVillager.extra.1": "Set to a number greater than 0, the value will be +1 based on the setting",
|
"carpet.rule.skipTicksForJoblessVillager.extra.1": "Set to a number greater than 0, the value will be +1 based on the setting",
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
"carpet.rule.printStackTraceOnVillagerSpawn.name": "打印村民生成报告",
|
"carpet.rule.printStackTraceOnVillagerSpawn.name": "打印村民生成报告",
|
||||||
"carpet.rule.botMaxOnlineTime.name": "Bot最大存活时间",
|
"carpet.rule.botMaxOnlineTime.name": "Bot最大存活时间",
|
||||||
"carpet.rule.spectatorCannotUseLeash.name": "观察者模式禁用拴绳",
|
"carpet.rule.spectatorCannotUseLeash.name": "观察者模式禁用拴绳",
|
||||||
|
"carpet.rule.armadilloImmediateDespawns.desc": "当犰狳远离玩家128格时,立即消失",
|
||||||
|
|
||||||
"carpet.rule.obtainableReinforcedDeepSlate.desc": "当铁砧砸在9*64个深板岩的掉落物上时,可以获得强化深板岩",
|
"carpet.rule.obtainableReinforcedDeepSlate.desc": "当铁砧砸在9*64个深板岩的掉落物上时,可以获得强化深板岩",
|
||||||
"carpet.rule.skipTicksForJoblessVillager.desc": "对于无业/傻子村民,执行设定数量的tick运算后,跳过1tick的运算",
|
"carpet.rule.skipTicksForJoblessVillager.desc": "对于无业/傻子村民,执行设定数量的tick运算后,跳过1tick的运算",
|
||||||
|
|||||||
@@ -12,6 +12,7 @@
|
|||||||
"datapack.MixinVanillaResourcePackProvider",
|
"datapack.MixinVanillaResourcePackProvider",
|
||||||
"elytra.MixinElytraItem",
|
"elytra.MixinElytraItem",
|
||||||
"elytra.MixinItem",
|
"elytra.MixinItem",
|
||||||
|
"entity.MixinArmadilloEntity",
|
||||||
"entity.MixinArmorStandEntity",
|
"entity.MixinArmorStandEntity",
|
||||||
"entity.MixinBoatEntity",
|
"entity.MixinBoatEntity",
|
||||||
"entity.MixinEnderDragonFight",
|
"entity.MixinEnderDragonFight",
|
||||||
|
|||||||
Reference in new issue
Block a user