Compare with dropped item

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

Status
Not open for further replies.

irum

Member
Nov 30, 2020
2
0
1
I want to compare an item with dropped item, but I failed.. (I'm sorry for my English.)

Code:
command /compare:
    trigger:
        loop all dropped items in radius 5 of {location}:
            if loop-entity is emerald:
                send "a"
            else:
                send "b"

skript prints "b"


Minecraft version: 1.12.2
Skript version: 2.4.1
 
You can try debugging. Put this into the loop:
Code:
broadcast "%loop-entity%"
(You can use also "send" of course.) You'll get all the entities' names in the chat. Then you can compare it with your code.
 
You can try debugging. Put this into the loop:
Code:
broadcast "%loop-entity%"
(You can use also "send" of course.) You'll get all the entities' names in the chat. Then you can compare it with your code.
output "dropped item"...
 
Status
Not open for further replies.