Added convenience Function

This commit is contained in:
Frank 2022-01-21 13:48:46 +01:00
parent db082ef1be
commit ba89751ea8

View file

@ -380,6 +380,10 @@ public class TagAPI {
public TagLocation(ResourceLocation location) { public TagLocation(ResourceLocation location) {
super(location.getNamespace(), location.getPath()); super(location.getNamespace(), location.getPath());
} }
public static<R> TagLocation<R> of(Tag.Named<R> tag){
return new TagLocation<R>(tag.getName());
}
} }
private abstract static class CommonDelegate<T> implements TagNamed<T> { private abstract static class CommonDelegate<T> implements TagNamed<T> {