Kill reward

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

KAVKAZIE

Active Member
Feb 27, 2017
146
0
16
Hey, How i can add item to player's inventory and if its full it will drop on the ground thanks.
 
Hey, How i can add item to player's inventory and if its full it will drop on the ground thanks.
It is not tested, but something like that I would do it.
code_language.skript:
on death:
    if victim is a player:
       if attacker is a player:
            set {_reward.item} to DIAMOND BLOCK named "&a&ki&c&ki&b Magic Block &c&ki&a&ki&f"
            set line 2 of lore of {_reward.item} to "&cText"
            set line 3 of lore of {_reward.item} to "&4More text"
            if attacker's inventory has enough space for 1 of {_reward.item}:
                add 1 of {_reward.item} to attacker's inventory
            else:
                drop 1 of {_reward.item} to victim's location
As I said before, it has not been tested so I do not guarantee it works, but it's worth trying.