Jump to content

[1.16.1] Using Advancements GUI


DavidQF555

Recommended Posts

I need to build a skill tree like gui, so I looked at the advancements, and realized that I might as well make it look the same because it has basically all the required functionality that I need. I want to use a different screen though because I feel no one really looks at the advancements screen and most the advancements are really useless. So I was just going to create advancements and add them to a custom AdvancementScreen. I'm pretty sure I just need to pass in a different ClientAdvancementManager with a different read() method into the Screen to make it work, but I'm confused how to specify which advancements to read. It seems that all the AdvancementManagers all just use the parameters in their read/apply methods, so where are these parameters passed in the first place? I just want to have a completely different AdvancementScreen with different tabs and also remove my custom Advancements from the vanilla one. I'm pretty sure the handling of completing advancements also requires the advancements to be registered/loaded, so I could not just not add my custom advancements' JSONs in the correct directory. I need to know where the read/apply methods get their parameters, which are just JSON elements, so that I could hopefully change them to only display the ones that I want. 

Link to comment
Share on other sites

2 hours ago, DavidQF555 said:

I need to build a skill tree like gui, so I looked at the advancements

I really wouldn't look at the advancements as a reference to a skill tree type thing. The system works completely different from that of skills.

2 hours ago, DavidQF555 said:

I'm pretty sure the handling of completing advancements also requires the advancements to be registered/loaded, so I could not just not add my custom advancements' JSONs in the correct directory.

Well yes, you can only have an advancement that's loaded into the game. But, you're also missing how advancements determine whether to unlock in this case. That's handled and stored somewhere completely different.

2 hours ago, DavidQF555 said:

I need to know where the read/apply methods get their parameters, which are just JSON elements, so that I could hopefully change them to only display the ones that I want. 

It grabs them from the files they are reading. Simple as that.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.