eyesniper2 / skRayFall

An addon for skript that adds Citizens support, EffectLib support and other features.
https://sk.rayfall.net/
GNU General Public License v3.0
21 stars 17 forks source link

on chest add #64

Open ARGHONY opened 4 years ago

ARGHONY commented 4 years ago

Describe the bug players are able to add items to the chest even it has to block it, there are 2 ways to still add the item to chest, all is described in the gifts 1st way => if u just click on any number 2nd way => click on item that is already in the chest

Expected Behavior player shouldn't be able to add the item to the chest

Your Script

on chest add:
    if inventory name of player's current inventory contains "&eu're looking in ec..":
        if item is stone sword or stone axe or iron sword or iron axe or bow or chain boots or chain leggings or chain chestplate or fishing rod or iron pickaxe or diamond pickaxe or golden apple or lava bucket:
            cancel event
            message "&cCant store this item."
        else if item is player head:
            if name of item is "&6Golden Head":
                cancel event
                message "&cCant store this item."
        else if item is arrow:
            if name of item is "&7Arrow":
                cancel event
                message "&cCant store this item."

Screenshots / Errors https://gyazo.com/94e50346bb47aec9f187b8de0e5b068e https://gyazo.com/1f03ea0a00a586a306fe83d414612aa3

Server Information Server Version and Type: 1.8 Skript Version: 2.2 dev36 skRayFall Version: 1.9.21 Additional Plugins: skUtilities, SkQuery, SkStuff, Skellet, TuSKe

Additional Information