/*
 * Copyright (c) 2026 盐灯水母
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at https://mozilla.org/MPL/2.0/.
 */

package com.remains_cave.item.client;

import com.remains_cave.item.custom.BoneStatelyItem;
import software.bernie.geckolib.cache.object.GeoBone;
import software.bernie.geckolib.model.GeoModel;
import software.bernie.geckolib.renderer.GeoArmorRenderer;

import javax.annotation.Nullable;

public class BoneStatelyRenderer extends GeoArmorRenderer<BoneStatelyItem> {
    public BoneStatelyRenderer() {
        super(new BoneStatelyModel());
    }

    // 重写获取头部骨骼的方法，返回模型中名为 "head" 的骨骼
    @Override
    @Nullable
    public GeoBone getHeadBone(GeoModel<BoneStatelyItem> model) {
        return model.getBone("head").orElse(null);
    }
}