Applied Energistics 2

Applied Energistics 2

156M Downloads

Port (disabled) achievement code over to advancements

GuntherDW opened this issue ยท 2 comments

commented

During the transition from 1.11.2 to 1.12 I had to comment out pretty much all of the Achievement code because those are called "Advancements" now.
We'll have to check how these are implemented and port over where applicable.

  • Minecraft Version: 1.12
  • AE2 Version: rv5-1.12-alpha-0
  • Forge Version:
commented

Most should probably be fine. I cannot recall the current options for advancements, but in most cases there should be no isse to move from crafting to obtaining an item.

The more important ones are the ones who were designed as some sort of tutorial. So the channel used (8) to point to a controller, the storage bus attached to an interface for recursive networks and so on.

Not sure about the used channels currently and if it could be solved.

But something like recursive network could work, if we can define 2 different items to be obtained. It might even be an advantage to link it to "Obtain 1 Storage Bus and 1 Interface". So we can point players immediately to it. Not only the ones who look at achievements (are there any?) or do it by accident.

commented

The used channels one is the one that is currently, without either Forge adding a method to add criteria classes or meddle with advancements more than they currently do not really feasible.

The only option we currently have available to us to actually port that is actively changing the handler class with reflection to add our own. Which will probably cause issues down the road when Forge decides to add their own hooks and features around it.

The other issue is that while the JSON's do get parsed through the CraftingHandler class, you can not use any of the _constants.json stuff in there. That means that I have to hardcode the damagevalue for "ae2:part" and "ae2:material" items in there. That works for now but could cause issues in the future when someone decides to change those values.

I could add the simple ones for now and wait until Forge adds decent hooks, or do we a custom criteria trigger(s) through reflection in preperation for such a hook?