ghast-data 0.2.2

Static Minecraft Java Edition game data for the ghast client library: blocks, block states, collision shapes, items, entities, biomes, enchantments, foods (generated from PrismarineJS minecraft-data)
Documentation
//! Enchantments.
//!
//! @generated by `cargo run -p ghast-codegen-data` from PrismarineJS minecraft-data 3.119.0 — do not edit.
//! Sources: pc/1.8/enchantments.json.

#![allow(clippy::all, clippy::pedantic, clippy::nursery, missing_docs)]

use crate::common::{EnchantCost, EnchantmentInfo};

pub(crate) static ENCHANTMENTS: [EnchantmentInfo; 25] = [
    EnchantmentInfo { id: 0, name: "protection", display_name: "Protection", max_level: 4, min_cost: EnchantCost { a: 11, b: -10 }, max_cost: EnchantCost { a: 11, b: 1 }, exclude: &["blast_protection", "fire_protection", "projectile_protection"], category: "armor", weight: 10, treasure_only: false, curse: false },
    EnchantmentInfo { id: 1, name: "fire_protection", display_name: "Fire Protection", max_level: 4, min_cost: EnchantCost { a: 8, b: 2 }, max_cost: EnchantCost { a: 8, b: 10 }, exclude: &["blast_protection", "protection", "projectile_protection"], category: "armor", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 2, name: "feather_falling", display_name: "Feather Falling", max_level: 4, min_cost: EnchantCost { a: 6, b: -1 }, max_cost: EnchantCost { a: 6, b: 5 }, exclude: &[], category: "armor_feet", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 3, name: "blast_protection", display_name: "Blast Protection", max_level: 4, min_cost: EnchantCost { a: 8, b: -3 }, max_cost: EnchantCost { a: 8, b: 5 }, exclude: &["fire_protection", "protection", "projectile_protection"], category: "armor", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 4, name: "projectile_protection", display_name: "Projectile Protection", max_level: 4, min_cost: EnchantCost { a: 6, b: -3 }, max_cost: EnchantCost { a: 6, b: 3 }, exclude: &["protection", "blast_protection", "fire_protection"], category: "armor", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 5, name: "respiration", display_name: "Respiration", max_level: 3, min_cost: EnchantCost { a: 10, b: 0 }, max_cost: EnchantCost { a: 10, b: 30 }, exclude: &[], category: "armor_head", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 6, name: "aqua_affinity", display_name: "Aqua Affinity", max_level: 1, min_cost: EnchantCost { a: 0, b: 1 }, max_cost: EnchantCost { a: 0, b: 41 }, exclude: &[], category: "armor_head", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 7, name: "thorns", display_name: "Thorns", max_level: 3, min_cost: EnchantCost { a: 20, b: -10 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "armor_chest", weight: 1, treasure_only: false, curse: false },
    EnchantmentInfo { id: 8, name: "depth_strider", display_name: "Depth Strider", max_level: 3, min_cost: EnchantCost { a: 10, b: 0 }, max_cost: EnchantCost { a: 10, b: 15 }, exclude: &["frost_walker"], category: "armor_feet", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 16, name: "sharpness", display_name: "Sharpness", max_level: 5, min_cost: EnchantCost { a: 11, b: -10 }, max_cost: EnchantCost { a: 11, b: 10 }, exclude: &["smite", "bane_of_arthropods"], category: "weapon", weight: 10, treasure_only: false, curse: false },
    EnchantmentInfo { id: 17, name: "smite", display_name: "Smite", max_level: 5, min_cost: EnchantCost { a: 8, b: -3 }, max_cost: EnchantCost { a: 8, b: 17 }, exclude: &["sharpness", "bane_of_arthropods"], category: "weapon", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 18, name: "bane_of_arthropods", display_name: "Bane of Arthropods", max_level: 5, min_cost: EnchantCost { a: 8, b: -3 }, max_cost: EnchantCost { a: 8, b: 17 }, exclude: &["smite", "sharpness"], category: "weapon", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 19, name: "knockback", display_name: "Knockback", max_level: 2, min_cost: EnchantCost { a: 20, b: -15 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "weapon", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 20, name: "fire_aspect", display_name: "Fire Aspect", max_level: 2, min_cost: EnchantCost { a: 20, b: -10 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "weapon", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 21, name: "looting", display_name: "Looting", max_level: 3, min_cost: EnchantCost { a: 9, b: 6 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "weapon", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 32, name: "efficiency", display_name: "Efficiency", max_level: 5, min_cost: EnchantCost { a: 10, b: -9 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "digger", weight: 10, treasure_only: false, curse: false },
    EnchantmentInfo { id: 33, name: "silk_touch", display_name: "Silk Touch", max_level: 1, min_cost: EnchantCost { a: 0, b: 15 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &["fortune"], category: "digger", weight: 1, treasure_only: false, curse: false },
    EnchantmentInfo { id: 34, name: "unbreaking", display_name: "Unbreaking", max_level: 3, min_cost: EnchantCost { a: 8, b: -3 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "breakable", weight: 5, treasure_only: false, curse: false },
    EnchantmentInfo { id: 35, name: "fortune", display_name: "Fortune", max_level: 3, min_cost: EnchantCost { a: 9, b: 6 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &["silk_touch"], category: "digger", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 48, name: "power", display_name: "Power", max_level: 5, min_cost: EnchantCost { a: 10, b: -9 }, max_cost: EnchantCost { a: 10, b: 6 }, exclude: &[], category: "bow", weight: 10, treasure_only: false, curse: false },
    EnchantmentInfo { id: 49, name: "punch", display_name: "Punch", max_level: 2, min_cost: EnchantCost { a: 20, b: -8 }, max_cost: EnchantCost { a: 20, b: 17 }, exclude: &[], category: "bow", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 50, name: "flame", display_name: "Flame", max_level: 1, min_cost: EnchantCost { a: 0, b: 20 }, max_cost: EnchantCost { a: 0, b: 50 }, exclude: &[], category: "bow", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 51, name: "infinity", display_name: "Infinity", max_level: 1, min_cost: EnchantCost { a: 0, b: 20 }, max_cost: EnchantCost { a: 0, b: 50 }, exclude: &["mending"], category: "bow", weight: 1, treasure_only: false, curse: false },
    EnchantmentInfo { id: 61, name: "luck_of_the_sea", display_name: "Luck of the Sea", max_level: 3, min_cost: EnchantCost { a: 9, b: 6 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "fishing_rod", weight: 2, treasure_only: false, curse: false },
    EnchantmentInfo { id: 62, name: "lure", display_name: "Lure", max_level: 3, min_cost: EnchantCost { a: 9, b: 6 }, max_cost: EnchantCost { a: 10, b: 51 }, exclude: &[], category: "fishing_rod", weight: 2, treasure_only: false, curse: false },
];

pub(crate) static ENCHANTMENT_NAMES: [(&str, u16); 25] = [
    ("aqua_affinity", 6),
    ("bane_of_arthropods", 18),
    ("blast_protection", 3),
    ("depth_strider", 8),
    ("efficiency", 32),
    ("feather_falling", 2),
    ("fire_aspect", 20),
    ("fire_protection", 1),
    ("flame", 50),
    ("fortune", 35),
    ("infinity", 51),
    ("knockback", 19),
    ("looting", 21),
    ("luck_of_the_sea", 61),
    ("lure", 62),
    ("power", 48),
    ("projectile_protection", 4),
    ("protection", 0),
    ("punch", 49),
    ("respiration", 5),
    ("sharpness", 16),
    ("silk_touch", 33),
    ("smite", 17),
    ("thorns", 7),
    ("unbreaking", 34),
];