WTFGeeks / Natural-Magic

This is the Official repository for the Natural Magic Modpack designed by Lewis WTFGeeks!
https://www.youtube.com/user/WTFG33ks
13 stars 7 forks source link

Ore dictionary equivalent ingots can have different EMC2 values #279

Closed Mawootad closed 6 years ago

Mawootad commented 6 years ago

It seems like ProjectE does not check the ore dictionary for equivalent objects when calculating EMC2 values of objects. As a result, you can end up with ingots/blocks/etc that can be exchanged using any standard ore dictionary converter but have different EMC2 values, leading to powerful infinite EMC2 loops extremely early into the game.

For an example, I have a local instance of DNS Techpack v10.3.0.4 which contains Mekanism and Thermal Expansion, both of which add steel ingots. The ingots match up via the ore dictionary, but the Thermal Expansion ingot has an EMC value of 256 while the Mekanism ingot has an EMC value of 512. Because of this, I can create a Thermal Expansion steel ingot at the transmutation table, convert it to a Mekanism steel ingot via an ore dictionary converter, and then exchange it at the transmutation table for a profit of 256 EMC. Doing this with a full stack of ingots results in a profit of 16k EMC.

To solve this problem, when calculating EMC for an object, ProjectE should check if there are any ore dictionary aliases for the object. If there are and any have a lower EMC value ProjectE should use that EMC value in place of the item's EMC value as calculated from its parts. This could also be used to resolve issues where sometimes an object will not have an EMC value, but ore dictionary aliases will (to see an example of this check Railcraft saltpeter and Thermal Expansion niter in the same modpack).

Mawootad commented 6 years ago

Whoops, wrong GitHub