Entity picks up item event set to a specific item only?

Started by Hijitori on

Topic category: Help with Minecraft modding (Java Edition)

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Entity picks up item event set to a specific item only?

I want my item to play a sound when player picks it up.

I created a Procedure, set Trigger Event to "Entity picks up item" and saved the Procedure in my specific item's "When in inventory tick".

Then when I have the item in my inventory, any item which I pick makes the sound, so I need to specify somehow the item which I want to make the sound. How?

Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Another idea is to make the…
Mon, 11/23/2020 - 18:19

Another idea is to make the sound play when player has it in inventory. To not make it sound constantly try with the repeat blocks. Hope it helps!

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Use: if provided itemstack …
Mon, 11/23/2020 - 19:37

Use:

  • if provided itemstack = [custom item]:
    • {play the sound}
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I think you mean repeating…
Mon, 11/23/2020 - 21:22

I think you mean repeating command block, but I am not sure how can I use that in this way.

Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I meant this:  
Mon, 11/23/2020 - 21:50

I meant this:

 Procedure

Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'm not 100% sure if it will…
Mon, 11/23/2020 - 21:50

I'm not 100% sure if it will work but it should

Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
For me it works, idk abt you
Mon, 11/23/2020 - 21:55

For me it works, idk abt you

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Unfortunately it still doesn…
Mon, 11/23/2020 - 22:35

Unfortunately it still doesn't work.
I mean with trigger "entity picks up item" - if I have the apple - all items make the sound.
Without trigger "entity picks up item" - if I have the apple - sound spams every tick once again.

Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I have tried many ways (I…
Mon, 11/23/2020 - 22:44

I have tried many ways (I have spent almost 1 hour) and I don't find a solution. The only way I found is using repeat blocks but if it doesn't work for you then it's not a solution. (While I was writing this came to mind: how about do the same as I putted in the photo but on extra trigger do player tick update. You should try it, maybe it works.)

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
  However my procedure has …
Mon, 11/23/2020 - 22:44

procedure

 

However my procedure has "Has provided entity in inventory" because I couldn't find the "Event/target entity"
I don't know if that's the problem

Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Still doesn't work with…
Mon, 11/23/2020 - 23:02

Still doesn't work with event trigger "On player tick update" and with being in item's "When item in inventory tick".
I hope there is some way to specify only one item event trigger and not all.