Block Tick Update Procedure not working

Started by MrCrayfisho on

Topic category: Help with Minecraft modding (Java Edition)

Active 4 months ago
Joined Aug 2024
Points:
84

User statistics:

  • Modifications: 0
  • Forum topics: 4
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 6
Block Tick Update Procedure not working

Hi, I want to make a procedure that modifies a NBT value when approaching a block but I can't select the procedure.

 

Here's the images:

 

https://imgur.com/a/xiLShwk

https://imgur.com/a/LYEzGne

Active 1 month ago
Joined May 2013
Points:
907

User statistics:

  • Modifications: 0
  • Forum topics: 25
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 111
Should use blockticks, not…
Sat, 10/12/2024 - 12:44

Should use blockticks, not entity ticks.

Active 4 months ago
Joined Aug 2024
Points:
84

User statistics:

  • Modifications: 0
  • Forum topics: 4
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 6
It doesn't work with my…
Sat, 10/12/2024 - 13:44

It doesn't work with my other procedures.

 

Active 4 months ago
Joined Jul 2022
Points:
537

User statistics:

  • Modifications: 1
  • Forum topics: 2
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 237
Its because on block tick…
Sat, 10/12/2024 - 14:15

Its because on block tick doesnt provide an entity. Although you are searching for an entity in a cube of size 8. There actually is not event/target entity being provided by the trigger.

Instead of using the does entity of type player exist. Instead use entity iterator. Like so:

Then just repeat for your other values. You can either have them stacked or put them in the same if statements like you did in your original procedure. Idk which one will work better, but it depends on your geiger beep effect which I assume is a sound. So probably put them in if statements to be sure.

 

Active 4 months ago
Joined Jul 2022
Points:
537

User statistics:

  • Modifications: 1
  • Forum topics: 2
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 237
Actually for the procedure…
Sat, 10/12/2024 - 14:17

Actually for the procedure above you need a logic to check if entity iterator is the same as entity of type player/server player. Instead of the does entity exist at x y z block.