How to delete dropped 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 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!

Injoyed

Member
May 18, 2025
17
0
1
I need a skript to delete certain items off the ground my og code has no errors but doesn't work:
every 1 tick:
loop all dropped items:
if loop-dropped item is dirt:
delete loop-dropped item

EDIT:
This code works (i have no spacing when I paste it)
every 1 second:
loop dropped items:
if loop-dropped item is dropped wooden sword:
kill loop-dropped item

My new issue is I want to check if dropped item is unbreakable!
 
Last edited:
maybe this?
Python:
every 1 tick:
    loop all dropped items in all worlds:
        delete loop-entity
 
every 1 second:
loop dropped items:
if loop-dropped item is dropped wooden sword:
kill loop-dropped item

this works but I want to check if dropped item is unbreakable how would I do that?
 
I dont really know, I haven't done much with looping dropped entites. reading the docs is my best suggestion right now.
 

Attachments

  • Screenshot 2025-05-19 233640.png
    Screenshot 2025-05-19 233640.png
    81.5 KB · Views: 115
I use 1,21,4 and I made this!



Code:
#Made By Lynxszn

every 80 real seconds:
    broadcast "&4The map will clear in 10 seconds"

every 90 real seconds:
    loop all entities:
        delete dropped items
 
I use 1,21,4 and I made this!



Code:
#Made By Lynxszn

every 80 real seconds:
    broadcast "&4The map will clear in 10 seconds"

every 90 real seconds:
    loop all entities:
        delete dropped items
let me try this
 
I use 1,21,4 and I made this!



Code:
#Made By Lynxszn

every 80 real seconds:
    broadcast "&4The map will clear in 10 seconds"

every 90 real seconds:
    loop all entities:
        delete dropped items
It works it just that my new issue and this might a problem with skript is I cannot check if the dropped item has data so I am checking if a dropped wooden sword is unbreakable but there seems to be no way to do it