xsavior-of-god / armorstand-limiter Goto Github PK
View Code? Open in Web Editor NEWProblems with tps? Is it ArmorStand's fault? Use ArmorStandLimiter to prevent your server from crash
License: MIT License
Problems with tps? Is it ArmorStand's fault? Use ArmorStandLimiter to prevent your server from crash
License: MIT License
If you're using papermc, you can accomplish preventing armorstands from moving in water quite easily without disabling gravity:
@EventHandler
public void onEntityMove(EntityMoveEvent event) {
if (event.getEntity() instanceof ArmorStand armorstand) {
if (armorstand.isInWater()) {
event.setCancelled(true);
}
}
}
I don't have enough time to make a pull request, but since you're using spigot-api, I'd recommend using reflection to check if the papermc event exists.
I know this plugins scope is ArmorStand Limiter, but is there any possibility of a future where you could prevent other lag machines like this one with minecarts?
I'm using 1.18.2 papermc and the current comparison to determine if armorstands are wearing a helmet doesn't work. I recommend changing it to armorstand.getEquipment().getHelmet().getType() != Material.AIR
for later versions of mc.
[10:08:44 ERROR]: Could not pass event onArmorStandRemove to ArmorStand-Limiter v1.6
java.lang.NoSuchMethodError: 'com.ticxo.modelengine.api.manager.ModelManager com.ticxo.modelengine.api.ModelEngineAPI.getModelManager()'
at com.xSavior_of_God.ArmorStandLimiter.externals.ModelEngine.onArmorStandRemove(ModelEngine.java:19) ~[ArmorStand-Limiter.v1.6.jar:?]
at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor1295.execute(Unknown Source) ~[?:?]
at org.bukkit.plugin.EventExecutor$2.execute(EventExecutor.java:77) ~[paper-api-1.19.3-R0.1-SNAPSHOT.jar:?]
at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80) ~[paper-api-1.19.3-R0.1-SNAPSHOT.jar:git-Paper-448]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.19.3-R0.1-SNAPSHOT.jar:?]
at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) ~[paper-1.19.3.jar:git-Paper-448]
at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:126) ~[paper-1.19.3.jar:git-Paper-448]
at com.xSavior_of_God.ArmorStandLimiter.Utilis$1.run(Utilis.java:80) ~[ArmorStand-Limiter.v1.6.jar:?]
at org.bukkit.craftbukkit.v1_19_R2.scheduler.CraftTask.run(CraftTask.java:101) ~[paper-1.19.3.jar:git-Paper-448]
at org.bukkit.craftbukkit.v1_19_R2.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:483) ~[paper-1.19.3.jar:git-Paper-448]
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1473) ~[paper-1.19.3.jar:git-Paper-448]
at net.minecraft.server.dedicated.DedicatedServer.tickChildren(DedicatedServer.java:447) ~[paper-1.19.3.jar:git-Paper-448]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1397) ~[paper-1.19.3.jar:git-Paper-448]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1173) ~[paper-1.19.3.jar:git-Paper-448]
at net.minecraft.server.MinecraftServer.lambda$spin
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.