ModelBakery.java 文件源码

java
阅读 19 收藏 0 点赞 0 评论 0

项目:BaseClient 作者:
private void loadItemModels()
{
    this.registerVariantNames();

    for (Item item : Item.itemRegistry)
    {
        for (String s : this.getVariantNames(item))
        {
            ResourceLocation resourcelocation = this.getItemLocation(s);
            this.itemLocations.put(s, resourcelocation);

            if (this.models.get(resourcelocation) == null)
            {
                try
                {
                    ModelBlock modelblock = this.loadModel(resourcelocation);
                    this.models.put(resourcelocation, modelblock);
                }
                catch (Exception exception)
                {
                    LOGGER.warn((String)("Unable to load item model: \'" + resourcelocation + "\' for item: \'" + Item.itemRegistry.getNameForObject(item) + "\'"), (Throwable)exception);
                }
            }
        }
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号