set_peffect() throwing CastExceptions when passing variable
LadyCailinBot opened this issue ยท 2 comments
CMDHELPER-2913 - Reported by Dustin.Blake
@p = player()
set_peffect(@p, 10, 1, 0)
Please report this error to the developers, and be sure to include the version numbers: Server version: 1.6.4-R2.1-SNAPSHOT; CommandHelper version: 3.3.1-SNAPSHOT:2582-068be01,master. Here's the stacktrace:
java.lang.ClassCastException: java.util.HashMap cannot be cast to [Lorg.bukkit.potion.PotionEffectType;
at com.laytonsmith.abstraction.bukkit.BukkitMCLivingEntity.getMaxEffect(BukkitMCLivingEntity.java:249)
at com.laytonsmith.core.functions.PlayerManagement$set_peffect.exec(PlayerManagement.java:1989)
at com.laytonsmith.core.Script.eval(Script.java:332)
at com.laytonsmith.core.Script.eval(Script.java:301)
at com.laytonsmith.core.functions.DataHandling$foreach.execs(DataHandling.java:581)
at com.laytonsmith.core.Script.eval(Script.java:291)
at com.laytonsmith.core.functions.BasicLogic$ifelse.execs(BasicLogic.java:671)
at com.laytonsmith.core.Script.eval(Script.java:291)
at com.laytonsmith.core.Script.eval(Script.java:301)
at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1692)
at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1652)
at com.laytonsmith.core.Script.run(Script.java:185)
at com.laytonsmith.core.AliasCore.alias(AliasCore.java:166)
at com.laytonsmith.commandhelper.CommandHelperListener.runAlias(CommandHelperListener.java:86)
at com.laytonsmith.commandhelper.CommandHelperListener.onPlayerCommandPreprocess(CommandHelperListener.java:131)
at sun.reflect.GeneratedMethodAccessor110.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:435)
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
at org.bukkit.plugin.TimedRegisteredListener.callEvent(TimedRegisteredListener.java:48)
at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:479)
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:464)
at net.minecraft.network.NetServerHandler.func_72566_d(NetServerHandler.java:1386)
at net.minecraft.network.NetServerHandler.chat(NetServerHandler.java:1269)
at net.minecraft.network.NetServerHandler.func_72481_a(NetServerHandler.java:1201)
at net.minecraft.network.packet.Packet3Chat.func_73279_a(Packet3Chat.java:68)
at net.minecraft.network.TcpConnection.func_74428_b(TcpConnection.java:470)
at net.minecraft.network.NetServerHandler.func_72570_d(NetServerHandler.java:233)
at net.minecraft.network.NetworkListenThread.func_71747_b(NetworkListenThread.java:54)
at net.minecraft.server.dedicated.DedicatedServerListenThread.func_71747_b(DedicatedServerListenThread.java:34)
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:910)
at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:330)
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:777)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:659)
at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16)
Server version MCPC+ 1.6.4 Build-243
Comment by EntityReborn
This doesn't seem to be the case any more, can you update to the latest server and CH, and verify?