Exception when dropping an item

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

pepper82

Member
Jan 26, 2017
272
1
18
41
Hi all,
I get an exception when dropping an item at victim's location ... makes no sense:


Code:
on death:
    if victim is a polar bear:
        set {_drop} to apple named "test"
        drop 1 of {_drop} at victim's location

Code:
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! [Skript] Severe Error:
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! Something went horribly wrong with Skript.
[10:51:14] [Server thread/ERROR]: #!#! This issue is NOT your fault! You probably can't fix it yourself, either.
[10:51:14] [Server thread/ERROR]: #!#! You're running outdated version of Skript! Please try updating it NOW; it might fix this.
[10:51:14] [Server thread/ERROR]: #!#! Run /sk update check to get a download link to latest Skript!
[10:51:14] [Server thread/ERROR]: #!#! You will be given instructions how to report this error if it persists after update.
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! Stack trace:
[10:51:14] [Server thread/ERROR]: #!#! java.lang.ClassCastException: org.bukkit.inventory.ItemStack cannot be cast to ch.njol.skript.aliases.ItemType
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.effects.EffDrop.execute(EffDrop.java:89)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.lang.Effect.run(Effect.java:52)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:61)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:89)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.lang.Trigger.execute(Trigger.java:57)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.SkriptEventHandler.check(SkriptEventHandler.java:152)
[10:51:14] [Server thread/ERROR]: #!#!     at ch.njol.skript.SkriptEventHandler$1.execute(SkriptEventHandler.java:110)
[10:51:14] [Server thread/ERROR]: #!#!     at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80)
[10:51:14] [Server thread/ERROR]: #!#!     at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:66)
[10:51:14] [Server thread/ERROR]: #!#!     at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:520)
[10:51:14] [Server thread/ERROR]: #!#!     at org.bukkit.craftbukkit.v1_13_R2.event.CraftEventFactory.callEntityDeathEvent(CraftEventFactory.java:607)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.EntityLiving.die(EntityLiving.java:1243)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.EntityLiving.damageEntity(EntityLiving.java:1088)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.EntityHuman.attack(EntityHuman.java:1082)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.EntityPlayer.attack(EntityPlayer.java:1492)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.PlayerConnection.a(PlayerConnection.java:2010)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.PacketPlayInUseEntity.a(PacketPlayInUseEntity.java:49)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.PacketPlayInUseEntity.a(PacketPlayInUseEntity.java:6)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.PlayerConnectionUtils.lambda$ensureMainThread$0(PlayerConnectionUtils.java:15)
[10:51:14] [Server thread/ERROR]: #!#!     at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
[10:51:14] [Server thread/ERROR]: #!#!     at java.util.concurrent.FutureTask.run(Unknown Source)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.SystemUtils.a(SystemUtils.java:108)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.MinecraftServer.b(MinecraftServer.java:1018)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.DedicatedServer.b(DedicatedServer.java:439)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.MinecraftServer.a(MinecraftServer.java:940)
[10:51:14] [Server thread/ERROR]: #!#!     at net.minecraft.server.v1_13_R2.MinecraftServer.run(MinecraftServer.java:837)
[10:51:14] [Server thread/ERROR]: #!#!     at java.lang.Thread.run(Unknown Source)
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! Current node: null
[10:51:14] [Server thread/ERROR]: #!#! Current item: drop [[long:1]] of {_drop}(as java.lang.Object) at the location of (the attacked entity >> ch.njol.skript.classes.data.DefaultConverters$10@a4fcdc9: org.bukkit.entity.Entity->org.bukkit.Location)
[10:51:14] [Server thread/ERROR]: #!#! Current trigger: death (death/spawn) (test.sk, line 9)
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! Thread: Server thread
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! Language: english
[10:51:14] [Server thread/ERROR]: #!#! Link parse mode: STRICT
[10:51:14] [Server thread/ERROR]: #!#!
[10:51:14] [Server thread/ERROR]: #!#! End of Error.
[10:51:14] [Server thread/ERROR]: #!#!
 
Status
Not open for further replies.