cancel event is not working when throwing stacks of items

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

PantherBoy

Active Member
Jul 20, 2017
74
0
6
24
Hello, i have an issue with this code:
Code:
on drop:
    player is holding lapis block named "<cyan><bold>Mana":
        cancel event
If i press q (the key that drops the items), the code works perfectly, and nothing happens.
If i press ctrl+q, all of the lapis drops to the ground, so the code doesn't work.
If in the inventory i hover the lapis block and press q, the code removes 1 lapis block.
If in the inventory i hover the lapis block and press ctrl+q, the code removes all of the lapis.

I want to prevent dorping the block, but the code doesn't work properly.

Skript Version: Skript v2.6-beta2
Minecraft Version: 1.17
 
Hello there, you can try:

Code:
on drop:
    event-item is a lapis block named "<cyan><bold>Mana":
        cancel event
 
It's almost the same, but now if in the inventory i hover the lapis block and press ctrl+q, all the lapis drops to the ground.
 
Status
Not open for further replies.