Closed Gafn3r closed 3 years ago
logs/latest.log
and your plugins/Citizens/saves.yml
files.I have a same problem when I use cooldowns for ncp commands.
Sorry for the late reponse... I know that the problem is not the version of paper because i've already tried in the lastest version 1.16.5 and i've got the same problem.
I can't post the .yml so i've just copy it in a .txt. Is that ok ?
@fullwall this error appears to be a mistake in the reify
update. I believe what happens is:
^ Field is type Map<String, PlayerNPCCommand>
^ That code will generate a persistence loader for the field, which will initially take the field.getType() as Map
, then recognize it as parameterized, and thus take the first param, which is String
, and produce a persistence loader for that.
It, of course, needs to generate a loader for the value rather than the key in this case.
The stack trace reported in the original issue:
java.lang.ClassCastException: java.lang.String cannot be cast to net.citizensnpcs.trait.CommandTrait$PlayerNPCCommand
at net.citizensnpcs.trait.CommandTrait$1$3.run(CommandTrait.java:223) ~[?:?]
at net.citizensnpcs.trait.CommandTrait$1.runCommand(CommandTrait.java:242) ~[?:?]
at net.citizensnpcs.trait.CommandTrait$1.run(CommandTrait.java:212) ~[?:?]
at net.citizensnpcs.trait.CommandTrait.dispatch(CommandTrait.java:249) ~[?:?]
Full latest log properly pasted: https://paste.denizenscript.com/View/80833
Relevant saves.yml
section:
commands:
'0':
command: server lobbypractice
hand: RIGHT
player: true
op: false
cooldown: 0
globalcooldown: 0
n: -1
delay: 0
'1':
command: clearinventory
hand: RIGHT
player: true
op: false
cooldown: 0
globalcooldown: 0
n: -1
delay: 0
cooldowns:
92e5742e-c437-4887-9a08-b4adb4a94eaa:
lastUsedId: 1
Can you help me with discord ? : Gafner#2850 I'm not good enought to understand your answer sorry...
@Gafn3r the issue was a bug in Citizens itself, all the information I wrote was just tracking down the details so fullwall could fix it.
Which he now fixed via https://github.com/CitizensDev/CitizensAPI/commit/f4235450d7e588dfd342d058f79436be326189da and the fix is available in build 2269+ from https://ci.citizensnpcs.co/job/Citizens2/
Hello, I'm new with plugins but i have a serious bug that i can't solve. This bug may happend when there is a oder player in the server.
Version server : This server is running Paper version git-Paper-416 (MC: 1.16.4) (Implementing API version 1.16.4-R0.1-SNAPSHOT) You are running the latest version
version citizens: Citizens version 2.0.27-SNAPSHOT (build 2263) Website: http://www.citizensnpcs.co Author: [fullwall]
bug 11.02.2021.txt
Thank you to check this bug and have a nice day :)