Give player item upon death not working

  • 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!


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


New Member
Apr 8, 2023
United States
I'm coding this really long script for an SMP I'm making with my friends. It's supposed to assign you a custom sword (I haven't coded abilities yet), and give you it. They have Curse of Vanishing so when you die, it doesn't drop. When you respawn, it's supposed to give you the sword back, but for some reason, it's not working.
On line 23, I made a subcommand that gives a certain player their assigned sword, and that seems to work. I made it so that when you die (Using the on death event), it runs the same subcommand from the console, but it doesn't seem to work. I tried switching the on death event to the on respawn event, but it still doesn't work. If anyone knows why, please tell me.
Did you try parsing this? You need to use player not victim in your respawn event.