Jump to content

[1.7.10] Achievements?


TheSgtPunishment

Recommended Posts

I'm trying to add achievements to an established mod (Soul Shards: Reborn by Moze_Intel) I've got crafting a shard/cage achievements already in the bag, but I'm trying to add an achievement for each tier of shard you can level up (Maximum 5) But I have no idea how to grab the NBT data to be used for said achievements, all the code is visible at github

 

I'm not asking to be spoonfed any code, just would like it if someone could point me in the right direction.

 

Thank you for your time.

Link to comment
Share on other sites

Basically a soul shard is a single item, when you craft it you get an 'unbound' shard, you have to kill something to bind the shard to that mob type, and you level it by killing more mobs of the same type e.g. Zombie, you need a default of 1024 kills to reach level 5 (Maximum level) but I know I'm not very good at java (I'm surprised I've managed to maintain / contribute to the mod at all)

Link to comment
Share on other sites

Looks like right here https://github.com/SgtPunishment/Soul-Shards-Reborn/blob/master/src/main/java/moze_intel/ssr/utils/Utils.java#L74 is where the shards tier levels up, it also looks like it can return the same tier as it was before, so you'd need to do a check to see if the previous tier is higher than the current route.

 

Actually, if I look at that page you linked (Thank you by the way) a bit futher down (#L92) looks like that would be a better choice as it will return a byte value between 0 and 5... Now to hook into that to fire off the achievements (And figure out why an achievement I have already made is auto-giving)

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.