Don't drop some tools on death

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

    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!

penqs

Member
Mar 24, 2021
2
0
1
I'm trying to make a Skript where you don't drop pickaxes, sword, axes, and armor when you die.
Here's my code;

on death:
attacker is a player:
victim is a player:
drop all items in victim's inventory at victim
remove all swords and all pickaxes and all axes and all armor from the drops

This system returns no errors, but simply drops every item.
Thanks for the help :emoji_slight_smile:
 
I would create list of drops and then just remove all items you dont want to drop, so something like this.
Code:
on death of player:
    set {_drops::*} to drops
    remove player's helmet from {_drops::*}
    remove player's chestplate from {_drops::*}
etc.. and then just drop
Code:
{_drops::*}
thats how i would do it, but there is more ways how to do it ig.