Skip to content
This repository has been archived by the owner on Apr 20, 2023. It is now read-only.

Commit

Permalink
Fix mixin warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Earthcomputer committed Aug 25, 2020
1 parent fbd6207 commit 7951978
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ private Iterator<Block> redirectBlockRegistryIterator(DefaultedRegistry<Block> r
}

@SuppressWarnings({"unchecked", "UnresolvedMixinReference"})
@Redirect(method = "method_4736", at = @At(value = "INVOKE", target = "Lnet/minecraft/util/registry/DefaultedRegistry;get(Lnet/minecraft/util/Identifier;)Ljava/lang/Object;"))
@Redirect(method = "method_4736(Lnet/minecraft/util/Identifier;)Lnet/minecraft/state/StateManager;", at = @At(value = "INVOKE", target = "Lnet/minecraft/util/registry/DefaultedRegistry;get(Lnet/minecraft/util/Identifier;)Ljava/lang/Object;"))
private static <T> T redirectGet(DefaultedRegistry<T> registry, Identifier id) {
DefaultRegistries<T> defaultRegistry = (DefaultRegistries<T>) DefaultRegistries.DEFAULT_REGISTRIES.get(registry);
return defaultRegistry != null ? defaultRegistry.defaultIdToEntry.get(id) : registry.get(id);
Expand Down

0 comments on commit 7951978

Please sign in to comment.