/searchinv #56
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When I try to use /searchinv it says that an internal error occurred. I contacted my server client and they said it was because you're using outdated code. If you could fix that ASAP that'd be great.
Please provide the error from console.Right, getOnlinePlayers. Will fix when I get out of work.
Fixed in
f05110c
It still doesn't work for me. Here's the error
[03:39:10] [Server thread/INFO]: Charzzart issued server command:
/searchinv dirt
[03:39:10] [Server thread/ERROR]: null
org.bukkit.command.CommandException: Unhandled exception executing
command 'searchinv' in plugin OpenInv v3.0.3
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46)
~[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at org.bukkit.command.SimpleCommandMap.dispatch(
SimpleCommandMap.java:140)
~[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at org.bukkit.craftbukkit.v1_11_R1.CraftServer.
dispatchCommand(CraftServer.java:628)
~[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.PlayerConnection.handleCommand(
PlayerConnection.java:1278)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.PlayerConnection.a(
PlayerConnection.java:1138)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.PacketPlayInChat.a(SourceFile:37)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.PacketPlayInChat.a(SourceFile:9)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.PlayerConnectionUtils$1.run(
SourceFile:13)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at java.util.concurrent.Executors$RunnableAdapter.
call(Executors.java:511)
[?:1.8.0_112]
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[?:1.8.0_112]
at net.minecraft.server.v1_11_R1.SystemUtils.a(SourceFile:46)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.MinecraftServer.D(
MinecraftServer.java:695)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.DedicatedServer.D(
DedicatedServer.java:360)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.MinecraftServer.C(
MinecraftServer.java:650)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at net.minecraft.server.v1_11_R1.MinecraftServer.run(
MinecraftServer.java:554)
[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_112]
Caused by: java.lang.NoSuchMethodError:
org.bukkit.Server.getOnlinePlayers()[Lorg/bukkit/entity/Player;
at com.lishid.openinv.commands.SearchInvPluginCommand.onCommand(
SearchInvPluginCommand.java:57)
~[?:?]
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
~[craftbukkit-1.11.jar:git-Bukkit-c8ff651]
... 15 more
On 22 December 2016 at 07:16, Adam notifications@github.com wrote:
The current version of OpenInv is 3.0.4, you appear to be running 3.0.3.
Oh thank you so much. I assume there's no way to make it so that I can
search inventories of offline players? If so, let me know.
I use the plugin so much and it's really useful.
On 26 December 2016 at 01:44, Adam notifications@github.com wrote:
Currently /searchinv and /searchender only search online players. If you do want that as a feature, please open a ticket for it. It's doable, just a bit painful - due to people having vast quantities of offline players, it would have to be done partially asynchronously and partially synchronously, which in turn leads to either difficulty aggregating the results into a single end line (spam) or longer delays. It'd probably be necessary to queue larger batch updates simultaneously or something, but then I'd probably have to add additional configuration to change the value. 1/2 max online players with a minimum of 10 doesn't seem unreasonable, I suppose. Both commands will likely just be completely merged and will search both simultaneously (loading that many players is decently expensive, and unless a server disables ender chests, both searches are likely to be performed consecutively) - they were already so completely identical that all it takes to support both commands in one executor is a single ternary operator.
I was about to open an issue for this, but then found this comment.
It would be a good idea to reword it so that it says its for online players only, on the CurseForge and Bukkit pages as well. I see that this git repo already has it worded correctly in the README.md. 👍