{
    "format_version": "1.21.60",
    "minecraft:block": {
        "description": {
            "identifier": "farmersdelight:jungle_cabinet",
            "menu_category": {
                "category": "items",
                "group": "farmersdelight:itemGroup.name.cabinet"
            },
            "states": {
                "farmersdelight:cabinet_is_open": [
                    false,
                    true
                ]
            },
            "traits": {
                "minecraft:placement_direction": {
                    "enabled_states": [
                        "minecraft:cardinal_direction"
                    ],
                    "y_rotation_offset": 180.0
                }
            }
        },
        "permutations": [
            {
                "condition": "query.block_state('minecraft:cardinal_direction') == 'north'",
                "components": {
                    "minecraft:transformation": {
                        "rotation": [
                            0,
                            180,
                            0
                        ]
                    }
                }
            },
            {
                "condition": "query.block_state('minecraft:cardinal_direction') == 'south'",
                "components": {
                    "minecraft:transformation": {
                        "rotation": [
                            0,
                            0,
                            0
                        ]
                    }
                }
            },
            {
                "condition": "query.block_state('minecraft:cardinal_direction') == 'west'",
                "components": {
                    "minecraft:transformation": {
                        "rotation": [
                            0,
                            270,
                            0
                        ]
                    }
                }
            },
            {
                "condition": "query.block_state('minecraft:cardinal_direction') == 'east'",
                "components": {
                    "minecraft:transformation": {
                        "rotation": [
                            0,
                            90,
                            0
                        ]
                    }
                }
            },
            {
                "condition": "query.block_state('farmersdelight:cabinet_is_open') == false",
                "components": {
                    "minecraft:material_instances": {
                        "*": {
                            "texture": "jungle_cabinet_side"
                        },
                        "up": {
                            "texture": "jungle_cabinet_top"
                        },
                        "down": {
                            "texture": "jungle_cabinet_top"
                        },
                        "south": {
                            "texture": "jungle_cabinet_front"
                        }
                    }
                }
            },
            {
                "condition": "query.block_state('farmersdelight:cabinet_is_open') == true",
                "components": {
                    "minecraft:material_instances": {
                        "*": {
                            "texture": "jungle_cabinet_side"
                        },
                        "up": {
                            "texture": "jungle_cabinet_top"
                        },
                        "down": {
                            "texture": "jungle_cabinet_top"
                        },
                        "south": {
                            "texture": "jungle_cabinet_front_open"
                        }
                    }
                }
            }
        ],
        "components": {
            "minecraft:destructible_by_mining": {
                "seconds_to_destroy": 1
            },
            "minecraft:destructible_by_explosion": {
                "explosion_resistance": 36
            },
            "minecraft:geometry": "geometry.block",
            "tag:wood": {},
            "tag:farmersdelight:cabinet": {}
        }
    }
}