clickism / clickvillagers Goto Github PK
View Code? Open in Web Editor NEWA simple 1.20 plugin that makes handling villagers a lot easier.
License: Other
A simple 1.20 plugin that makes handling villagers a lot easier.
License: Other
Title. Villagers picked up while shift+right click do not save their data and just become villagers. The hopper works fine.
Picked up villagers are stored at a hard-coded location in the Overworld (1,-70,1
). If this location is not currently loaded when a villager head is placed then the stored villager will not be retrieved and a new one is spawned in and placed instead.
This can happen if the server's spawn is far enough away from chunk 0,0
.
This means that you lose the villager with the profession and trades you were expecting.
ClickVillagers/src/main/java/me/clickism/clickvillagers/ClickVillagers.java
Lines 148 to 160 in 90afe95
Bukkit.getEntity(uuid)
appears to only get an entity if it is loaded, otherwise it returns null.
Possible ways to fix:
Current workaround is to force load the chunk: /forceload add 0 0
Placing down villagers works, but picking them up throws an error and the villager disappears.
Could not pass event PlayerInteractEntityEvent to ClickVillagers.
Players on server is duping hoppers in 0.4.1.
Placing villager hopper and braking them spits out 2 hoppers.
i put this plugin in my friend server and first off it was normal but then when i try to put my villager back on to the overworld theres a message saying their data its gone so is there a fix?
the Villager Hopper creates an incompatibility with the HopperSorter plugin.
If you deactivate the Villager hopper, you can no longer place a HopperSorter and if you activate this function, place a HopperSorter and remove it again, the Armorstand with the emerald edge of the Villagerhopper remains.
It would be cool if the function can be completely disabled directly, so that the Villagerhopper does not interfere with the functions of the HopperSorter.
Link: HopperSorter
https://www.spigotmc.org/resources/hoppersorter-1-8-1-20-1-upgradable-item-filter-transfer-item-smelt-multiple-block-linking.80528/
It would be great if a permission is added that you can not steal the Villager from other players.
Maybe as Bentobox, Plotsquared and RedProtect flag.
Greetings
When crouching and right clicking with a shovel, the sound is played but the menu does not appear, instead the trading menu appears. Server is a paper-1.20.1-196.
Getting this in console:
[02:54:38 ERROR]: Could not pass event InventoryClickEvent to ClickVillagers v0.4.1
java.lang.NullPointerException: Cannot invoke "org.bukkit.entity.LivingEntity.getPersistentDataContainer()" because "entity" is null
at me.clickism.clickvillagers.managers.VillagerData.getOwner(VillagerData.java:34) ~[ClickVillagers-0.4.1.jar:?]
at me.clickism.clickvillagers.menu.EditVillagerMenu.getTitle(EditVillagerMenu.java:24) ~[ClickVillagers-0.4.1.jar:?]
at me.clickism.clickvillagers.events.ClickEvent.onClick(ClickEvent.java:60) ~[ClickVillagers-0.4.1.jar:?]
at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor473.execute(Unknown Source) ~[?:?]
at org.bukkit.plugin.EventExecutor$2.execute(EventExecutor.java:77) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:81) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:git-Paper-194]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) ~[paper-1.20.1.jar:git-Paper-194]
at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:126) ~[paper-1.20.1.jar:git-Paper-194]
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:615) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at net.minecraft.server.network.ServerGamePacketListenerImpl.handleContainerClick(ServerGamePacketListenerImpl.java:3237) ~[?:?]
at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:58) ~[?:?]
at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:23) ~[?:?]
at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:51) ~[?:?]
at net.minecraft.server.TickTask.run(TickTask.java:18) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:153) ~[?:?]
at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24) ~[?:?]
at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1338) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:197) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:126) ~[?:?]
at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1315) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1308) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:136) ~[?:?]
at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1286) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1174) ~[paper-1.20.1.jar:git-Paper-194]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:317) ~[paper-1.20.1.jar:git-Paper-194]
at java.lang.Thread.run(Unknown Source) ~[?:?]
Discovered this plugin yesterday and been playing around with it for a bit.
I found an issue where if you break a Villager Hopper that contains villagers, the villagers are gone/voided.
I need land integration, or at least worldguard, for my server. Anyone can take villagers anywhere in any claim... no need to explain the problem ^^.
Is integration with the Lands faction plugin possible?
In your code, you're using inventory titles to check if the villager is a clickvillager. This should be avoided as it can easily be exploitable, (players can easily rename inventories and trick your plugin into thinking it was a click villager)
You should look into inventory holders, and then check if the inventory is an instanceof your custom inventory holder
I'm not sure if you're able to fix this but when I have a villager in my inventory and I place the villager in someone else's claim, it spawns the mob and also puts the villager back into my inventory essentially duping the villager.
Is it possible to add a WorldGuard flag to disable and enable people to kidnap the villagers, players are able to steal villager NPCs from hubs and stuff due to this
For the past two days, I've been experimenting with the plugin. One idea I'd like to explore is incorporating zombie villagers into it, or enabling the ability to place a villager in a minecart using shift right-click. So that they won't run away while getting their brains eaten.
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.