Advancement trigger for travelling specified distance

Started by krzysiuplYT on

Topic category: Help with modding (Java Edition)

Last seen on 21:16, 21. Apr 2024
Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Advancement trigger for travelling specified distance
Fri, 04/05/2024 - 00:26 (edited)

I was looking everywhere for about an hour for the answer, but it was nowhere to be found nor was close to be found.

Basically, I want to make an advancement that triggers whenever player travels e.g 1000 blocks. It doesn't matter how they travel and in what direction. Just travelling in general.

This doesn't work for some reason:

      "trigger": "minecraft:location",
     "conditions": {
       "player": {
         "distance": {
           "horizontal": 1000
         }
       }
     }

 

 

I am new to making advancements in .JSON format and/or procedures btw so if you can, please answer in the way that a beginner could understand it

Edited by krzysiuplYT on Fri, 04/05/2024 - 00:26
Last seen on 10:38, 22. Apr 2024
Joined May 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You could try referencing…
Sat, 04/06/2024 - 13:23

You could try referencing the player's statistics somehow. If you just want them to travel 1000 blocks from their starting location, you could also just save the starting x/z as a player persistent variable and then trigger the advancement when the difference between that and their current position exceeds 1000. 

Last seen on 21:16, 21. Apr 2024
Joined Oct 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
referencing to player's…
Sun, 04/07/2024 - 12:48

referencing to player's starting x/z I will try doing that, thanks