No way to dynamically assign aspects to an item based on NBT data
cadaverous-eris opened this issue ยท 1 comments
I haven't been able to find a way to dynamically assign aspects to an item based on custom NBT data. I need this functionality since I develop a mod that adds modular tools which don't have an actual tool material and whose stats are determined from NBT data. Currently all of the tools have the same aspects no matter what stats they have or materials they're made from.
Personally, the solution I would prefer would be to add a method to ThaumcraftApi.class like
public static void registerDynamicObjectTag(Object thing, IAspectGetter aspectGetter)
where IAspectGetter is an interface with a method which takes an Object as an argument and returns an AspectList, like so
AspectList getAspects(Object thing);
That way I could use lambdas to keep things clean.