mcdex 0.1.0.dev0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mcdex/__init__.py +281 -0
- mcdex/advancements/__init__.py +16 -0
- mcdex/advancements/_mc_advancements.py +3558 -0
- mcdex/advancements/advancements.json +12101 -0
- mcdex/attributes/__init__.py +16 -0
- mcdex/attributes/_mc_attributes.py +83 -0
- mcdex/attributes/attributes.json +289 -0
- mcdex/banner_patterns/__init__.py +16 -0
- mcdex/banner_patterns/_mc_banner_patterns.py +86 -0
- mcdex/banner_patterns/banner_patterns.json +310 -0
- mcdex/base/__init__.py +146 -0
- mcdex/base/_advancement_id.py +22 -0
- mcdex/base/_attribute_id.py +22 -0
- mcdex/base/_banner_pattern_id.py +26 -0
- mcdex/base/_biome_id.py +22 -0
- mcdex/base/_block_entity_id.py +22 -0
- mcdex/base/_block_id.py +35 -0
- mcdex/base/_cat_sound_variant_id.py +23 -0
- mcdex/base/_cat_variant_id.py +22 -0
- mcdex/base/_catalogue_meta.py +38 -0
- mcdex/base/_chicken_sound_variant_id.py +23 -0
- mcdex/base/_chicken_variant_id.py +23 -0
- mcdex/base/_cow_sound_variant_id.py +23 -0
- mcdex/base/_cow_variant_id.py +22 -0
- mcdex/base/_damage_type_id.py +21 -0
- mcdex/base/_dimension_id.py +21 -0
- mcdex/base/_effect_id.py +21 -0
- mcdex/base/_enchantment_id.py +22 -0
- mcdex/base/_entity_id.py +35 -0
- mcdex/base/_equipment_slot.py +34 -0
- mcdex/base/_frog_variant_id.py +22 -0
- mcdex/base/_game_id.py +88 -0
- mcdex/base/_game_rule_id.py +21 -0
- mcdex/base/_item_id.py +98 -0
- mcdex/base/_mc_thing.py +289 -0
- mcdex/base/_mc_version.py +140 -0
- mcdex/base/_music_id.py +25 -0
- mcdex/base/_not_in_version.py +68 -0
- mcdex/base/_painting_variant_id.py +23 -0
- mcdex/base/_particle_id.py +21 -0
- mcdex/base/_pig_sound_variant_id.py +23 -0
- mcdex/base/_pig_variant_id.py +22 -0
- mcdex/base/_potion_id.py +25 -0
- mcdex/base/_potion_modifier.py +30 -0
- mcdex/base/_sound_id.py +21 -0
- mcdex/base/_statistic_id.py +22 -0
- mcdex/base/_structure_id.py +21 -0
- mcdex/base/_trim_material_id.py +26 -0
- mcdex/base/_trim_pattern_id.py +25 -0
- mcdex/base/_version.py +188 -0
- mcdex/base/_villager_profession_id.py +24 -0
- mcdex/base/_villager_type_id.py +25 -0
- mcdex/base/_wolf_sound_variant_id.py +23 -0
- mcdex/base/_wolf_variant_id.py +22 -0
- mcdex/base/_zombie_nautilus_variant_id.py +23 -0
- mcdex/biomes/__init__.py +16 -0
- mcdex/biomes/_mc_biomes.py +137 -0
- mcdex/biomes/biomes.json +652 -0
- mcdex/block_entities/__init__.py +16 -0
- mcdex/block_entities/_mc_block_entities.py +95 -0
- mcdex/block_entities/block_entities.json +331 -0
- mcdex/blocks/__init__.py +16 -0
- mcdex/blocks/_mc_blocks.py +1338 -0
- mcdex/blocks/blocks.json +7770 -0
- mcdex/cat_sound_variants/__init__.py +16 -0
- mcdex/cat_sound_variants/_mc_cat_sound_variants.py +47 -0
- mcdex/cat_sound_variants/cat_sound_variants.json +25 -0
- mcdex/cat_variants/__init__.py +16 -0
- mcdex/cat_variants/_mc_cat_variants.py +54 -0
- mcdex/cat_variants/cat_variants.json +91 -0
- mcdex/chicken_sound_variants/__init__.py +17 -0
- mcdex/chicken_sound_variants/_mc_chicken_sound_variants.py +48 -0
- mcdex/chicken_sound_variants/chicken_sound_variants.json +24 -0
- mcdex/chicken_variants/__init__.py +16 -0
- mcdex/chicken_variants/_mc_chicken_variants.py +47 -0
- mcdex/chicken_variants/chicken_variants.json +30 -0
- mcdex/cow_sound_variants/__init__.py +16 -0
- mcdex/cow_sound_variants/_mc_cow_sound_variants.py +47 -0
- mcdex/cow_sound_variants/cow_sound_variants.json +24 -0
- mcdex/cow_variants/__init__.py +16 -0
- mcdex/cow_variants/_mc_cow_variants.py +47 -0
- mcdex/cow_variants/cow_variants.json +30 -0
- mcdex/damage_types/__init__.py +16 -0
- mcdex/damage_types/_mc_damage_types.py +94 -0
- mcdex/damage_types/damage_types.json +317 -0
- mcdex/dimensions/__init__.py +16 -0
- mcdex/dimensions/_mc_dimensions.py +46 -0
- mcdex/dimensions/dimensions.json +29 -0
- mcdex/effects/__init__.py +16 -0
- mcdex/effects/_mc_effects.py +83 -0
- mcdex/effects/effects.json +251 -0
- mcdex/enchantments/__init__.py +16 -0
- mcdex/enchantments/_mc_enchantments.py +86 -0
- mcdex/enchantments/enchantments.json +270 -0
- mcdex/entities/__init__.py +16 -0
- mcdex/entities/_mc_entities.py +206 -0
- mcdex/entities/entities.json +1042 -0
- mcdex/frog_variants/__init__.py +16 -0
- mcdex/frog_variants/_mc_frog_variants.py +47 -0
- mcdex/frog_variants/frog_variants.json +29 -0
- mcdex/game_rules/__init__.py +16 -0
- mcdex/game_rules/_mc_game_rules.py +110 -0
- mcdex/game_rules/game_rules.json +436 -0
- mcdex/items/__init__.py +16 -0
- mcdex/items/_mc_items.py +1842 -0
- mcdex/items/items.json +20060 -0
- mcdex/music/__init__.py +16 -0
- mcdex/music/_music.py +65 -0
- mcdex/music/music.json +143 -0
- mcdex/painting_variants/__init__.py +16 -0
- mcdex/painting_variants/_mc_painting_variants.py +96 -0
- mcdex/painting_variants/painting_variants.json +369 -0
- mcdex/particles/__init__.py +16 -0
- mcdex/particles/_mc_particles.py +184 -0
- mcdex/particles/particles.json +917 -0
- mcdex/pig_sound_variants/__init__.py +16 -0
- mcdex/pig_sound_variants/_mc_pig_sound_variants.py +48 -0
- mcdex/pig_sound_variants/pig_sound_variants.json +30 -0
- mcdex/pig_variants/__init__.py +16 -0
- mcdex/pig_variants/_mc_pig_variants.py +46 -0
- mcdex/pig_variants/pig_variants.json +30 -0
- mcdex/potions/__init__.py +20 -0
- mcdex/potions/_mc_potions.py +101 -0
- mcdex/potions/_modified_potion.py +129 -0
- mcdex/potions/potions.json +297 -0
- mcdex/py.typed +0 -0
- mcdex/sounds/__init__.py +16 -0
- mcdex/sounds/_mc_sounds.py +2395 -0
- mcdex/sounds/sounds.json +13077 -0
- mcdex/statistics/__init__.py +16 -0
- mcdex/statistics/_mc_statistics.py +123 -0
- mcdex/statistics/statistics.json +521 -0
- mcdex/structures/__init__.py +16 -0
- mcdex/structures/_mc_structures.py +99 -0
- mcdex/structures/structures.json +367 -0
- mcdex/trim_materials/__init__.py +16 -0
- mcdex/trim_materials/_mc_trim_materials.py +54 -0
- mcdex/trim_materials/trim_materials.json +77 -0
- mcdex/trim_patterns/__init__.py +16 -0
- mcdex/trim_patterns/_mc_trim_patterns.py +61 -0
- mcdex/trim_patterns/trim_patterns.json +119 -0
- mcdex/villager_professions/__init__.py +17 -0
- mcdex/villager_professions/_mc_villager_professions.py +61 -0
- mcdex/villager_professions/villager_professions.json +125 -0
- mcdex/villager_types/__init__.py +16 -0
- mcdex/villager_types/_mc_villager_types.py +52 -0
- mcdex/villager_types/villager_types.json +54 -0
- mcdex/wolf_sound_variants/__init__.py +17 -0
- mcdex/wolf_sound_variants/_mc_wolf_sound_variants.py +53 -0
- mcdex/wolf_sound_variants/wolf_sound_variants.json +54 -0
- mcdex/wolf_variants/__init__.py +16 -0
- mcdex/wolf_variants/_mc_wolf_variants.py +53 -0
- mcdex/wolf_variants/wolf_variants.json +66 -0
- mcdex/zombie_nautilus_variants/__init__.py +17 -0
- mcdex/zombie_nautilus_variants/_mc_zombie_nautilus_variants.py +48 -0
- mcdex/zombie_nautilus_variants/zombie_nautilus_variants.json +23 -0
- mcdex-0.1.0.dev0.dist-info/METADATA +1285 -0
- mcdex-0.1.0.dev0.dist-info/RECORD +161 -0
- mcdex-0.1.0.dev0.dist-info/WHEEL +5 -0
- mcdex-0.1.0.dev0.dist-info/licenses/LICENSE +201 -0
- mcdex-0.1.0.dev0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"""
|
|
2
|
+
The 'mcdex.attributes' package provides the attributes of the game: the
|
|
3
|
+
'MCAttributes' catalogue, an enumeration of every attribute of the data file
|
|
4
|
+
'attributes.json' that ships with the package.
|
|
5
|
+
|
|
6
|
+
- MCAttributes
|
|
7
|
+
"""
|
|
8
|
+
# Apache-2.0 license
|
|
9
|
+
# Copyright (c) 2026 Asger Jon Vistisen
|
|
10
|
+
from __future__ import annotations
|
|
11
|
+
|
|
12
|
+
from ._mc_attributes import MCAttributes
|
|
13
|
+
|
|
14
|
+
__all__ = (
|
|
15
|
+
'MCAttributes',
|
|
16
|
+
)
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"""
|
|
2
|
+
MCAttributes is the catalogue of the game's attributes: an enumeration with one
|
|
3
|
+
member for every attribute of the data file that ships with mcdex, each the
|
|
4
|
+
same attribute in every version, with the id each version knows it by:
|
|
5
|
+
the name an entity's data gives it, and from 1.16 what /attribute takes.
|
|
6
|
+
"""
|
|
7
|
+
# Apache-2.0 license
|
|
8
|
+
# Copyright (c) 2026 Asger Jon Vistisen
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
from worktoy.keenum import Kee
|
|
12
|
+
|
|
13
|
+
from ..base import AttributeId, MCThing
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class MCAttributes(MCThing):
|
|
17
|
+
"""
|
|
18
|
+
The catalogue of the game's attributes, each a member, found by its name in
|
|
19
|
+
capitals, in any case, or by its unique name:
|
|
20
|
+
|
|
21
|
+
maxHealth = MCAttributes.MAX_HEALTH
|
|
22
|
+
maxHealth is MCAttributes['max_health'] # True
|
|
23
|
+
maxHealth['1.15.2'] # AttributeId('max_health', 'generic.maxHealth')
|
|
24
|
+
len(MCAttributes)
|
|
25
|
+
|
|
26
|
+
Implementation
|
|
27
|
+
--------------
|
|
28
|
+
|
|
29
|
+
All of it is 'MCThing's, reading 'attributes.json' beside this module.
|
|
30
|
+
mcdex's tools write the members, one for every name of that file.
|
|
31
|
+
"""
|
|
32
|
+
|
|
33
|
+
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
34
|
+
# NAMESPACE # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
35
|
+
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
36
|
+
|
|
37
|
+
# Class Variables
|
|
38
|
+
__data_file__ = 'attributes.json'
|
|
39
|
+
__data_key__ = 'attributes'
|
|
40
|
+
__id_class__ = AttributeId
|
|
41
|
+
__kind__ = 'attribute'
|
|
42
|
+
|
|
43
|
+
# Members, one for every name of 'attributes.json'
|
|
44
|
+
AIR_DRAG_MODIFIER = Kee[str]('air_drag_modifier')
|
|
45
|
+
ARMOR = Kee[str]('armor')
|
|
46
|
+
ARMOR_TOUGHNESS = Kee[str]('armor_toughness')
|
|
47
|
+
ATTACK_DAMAGE = Kee[str]('attack_damage')
|
|
48
|
+
ATTACK_KNOCKBACK = Kee[str]('attack_knockback')
|
|
49
|
+
ATTACK_SPEED = Kee[str]('attack_speed')
|
|
50
|
+
BELOW_NAME_DISTANCE = Kee[str]('below_name_distance')
|
|
51
|
+
BLOCK_BREAK_SPEED = Kee[str]('block_break_speed')
|
|
52
|
+
BLOCK_INTERACTION_RANGE = Kee[str]('block_interaction_range')
|
|
53
|
+
BOUNCINESS = Kee[str]('bounciness')
|
|
54
|
+
BURNING_TIME = Kee[str]('burning_time')
|
|
55
|
+
CAMERA_DISTANCE = Kee[str]('camera_distance')
|
|
56
|
+
ENTITY_INTERACTION_RANGE = Kee[str]('entity_interaction_range')
|
|
57
|
+
EXPLOSION_KNOCKBACK_RESISTANCE = Kee[str]('explosion_knockback_resistance')
|
|
58
|
+
FALL_DAMAGE_MULTIPLIER = Kee[str]('fall_damage_multiplier')
|
|
59
|
+
FLYING_SPEED = Kee[str]('flying_speed')
|
|
60
|
+
FOLLOW_RANGE = Kee[str]('follow_range')
|
|
61
|
+
FRICTION_MODIFIER = Kee[str]('friction_modifier')
|
|
62
|
+
GRAVITY = Kee[str]('gravity')
|
|
63
|
+
JUMP_STRENGTH = Kee[str]('jump_strength')
|
|
64
|
+
KNOCKBACK_RESISTANCE = Kee[str]('knockback_resistance')
|
|
65
|
+
LUCK = Kee[str]('luck')
|
|
66
|
+
MAX_ABSORPTION = Kee[str]('max_absorption')
|
|
67
|
+
MAX_HEALTH = Kee[str]('max_health')
|
|
68
|
+
MINING_EFFICIENCY = Kee[str]('mining_efficiency')
|
|
69
|
+
MOVEMENT_EFFICIENCY = Kee[str]('movement_efficiency')
|
|
70
|
+
MOVEMENT_SPEED = Kee[str]('movement_speed')
|
|
71
|
+
NAME_TAG_DISTANCE = Kee[str]('name_tag_distance')
|
|
72
|
+
OXYGEN_BONUS = Kee[str]('oxygen_bonus')
|
|
73
|
+
SAFE_FALL_DISTANCE = Kee[str]('safe_fall_distance')
|
|
74
|
+
SCALE = Kee[str]('scale')
|
|
75
|
+
SNEAKING_SPEED = Kee[str]('sneaking_speed')
|
|
76
|
+
SPAWN_REINFORCEMENTS = Kee[str]('spawn_reinforcements')
|
|
77
|
+
STEP_HEIGHT = Kee[str]('step_height')
|
|
78
|
+
SUBMERGED_MINING_SPEED = Kee[str]('submerged_mining_speed')
|
|
79
|
+
SWEEPING_DAMAGE_RATIO = Kee[str]('sweeping_damage_ratio')
|
|
80
|
+
TEMPT_RANGE = Kee[str]('tempt_range')
|
|
81
|
+
WATER_MOVEMENT_EFFICIENCY = Kee[str]('water_movement_efficiency')
|
|
82
|
+
WAYPOINT_RECEIVE_RANGE = Kee[str]('waypoint_receive_range')
|
|
83
|
+
WAYPOINT_TRANSMIT_RANGE = Kee[str]('waypoint_transmit_range')
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
{
|
|
2
|
+
"covers": [
|
|
3
|
+
"1.7.2",
|
|
4
|
+
"26.3"
|
|
5
|
+
],
|
|
6
|
+
"legend": {
|
|
7
|
+
"": "vanilla has no such attribute in this version"
|
|
8
|
+
},
|
|
9
|
+
"attributes": {
|
|
10
|
+
"air_drag_modifier": {
|
|
11
|
+
"ids": {
|
|
12
|
+
"1.7.2": "",
|
|
13
|
+
"26.2": "minecraft:air_drag_modifier"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"armor": {
|
|
17
|
+
"ids": {
|
|
18
|
+
"1.7.2": "",
|
|
19
|
+
"1.9": "generic.armor",
|
|
20
|
+
"1.16": "minecraft:generic.armor",
|
|
21
|
+
"1.21.2": "minecraft:armor"
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"armor_toughness": {
|
|
25
|
+
"ids": {
|
|
26
|
+
"1.7.2": "",
|
|
27
|
+
"1.9.1": "generic.armorToughness",
|
|
28
|
+
"1.16": "minecraft:generic.armor_toughness",
|
|
29
|
+
"1.21.2": "minecraft:armor_toughness"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"attack_damage": {
|
|
33
|
+
"ids": {
|
|
34
|
+
"1.7.2": "generic.attackDamage",
|
|
35
|
+
"1.16": "minecraft:generic.attack_damage",
|
|
36
|
+
"1.21.2": "minecraft:attack_damage"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"attack_knockback": {
|
|
40
|
+
"ids": {
|
|
41
|
+
"1.7.2": "",
|
|
42
|
+
"1.14": "generic.attackKnockback",
|
|
43
|
+
"1.16": "minecraft:generic.attack_knockback",
|
|
44
|
+
"1.21.2": "minecraft:attack_knockback"
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
"attack_speed": {
|
|
48
|
+
"ids": {
|
|
49
|
+
"1.7.2": "",
|
|
50
|
+
"1.9": "generic.attackSpeed",
|
|
51
|
+
"1.16": "minecraft:generic.attack_speed",
|
|
52
|
+
"1.21.2": "minecraft:attack_speed"
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"below_name_distance": {
|
|
56
|
+
"ids": {
|
|
57
|
+
"1.7.2": "",
|
|
58
|
+
"26.2": "minecraft:below_name_distance"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"block_break_speed": {
|
|
62
|
+
"ids": {
|
|
63
|
+
"1.7.2": "",
|
|
64
|
+
"1.20.5": "minecraft:player.block_break_speed",
|
|
65
|
+
"1.21.2": "minecraft:block_break_speed"
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"block_interaction_range": {
|
|
69
|
+
"ids": {
|
|
70
|
+
"1.7.2": "",
|
|
71
|
+
"1.20.5": "minecraft:player.block_interaction_range",
|
|
72
|
+
"1.21.2": "minecraft:block_interaction_range"
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"bounciness": {
|
|
76
|
+
"ids": {
|
|
77
|
+
"1.7.2": "",
|
|
78
|
+
"26.2": "minecraft:bounciness"
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"burning_time": {
|
|
82
|
+
"ids": {
|
|
83
|
+
"1.7.2": "",
|
|
84
|
+
"1.21": "minecraft:generic.burning_time",
|
|
85
|
+
"1.21.2": "minecraft:burning_time"
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
"camera_distance": {
|
|
89
|
+
"ids": {
|
|
90
|
+
"1.7.2": "",
|
|
91
|
+
"1.21.6": "minecraft:camera_distance"
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
"entity_interaction_range": {
|
|
95
|
+
"ids": {
|
|
96
|
+
"1.7.2": "",
|
|
97
|
+
"1.20.5": "minecraft:player.entity_interaction_range",
|
|
98
|
+
"1.21.2": "minecraft:entity_interaction_range"
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
"explosion_knockback_resistance": {
|
|
102
|
+
"ids": {
|
|
103
|
+
"1.7.2": "",
|
|
104
|
+
"1.21": "minecraft:generic.explosion_knockback_resistance",
|
|
105
|
+
"1.21.2": "minecraft:explosion_knockback_resistance"
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
"fall_damage_multiplier": {
|
|
109
|
+
"ids": {
|
|
110
|
+
"1.7.2": "",
|
|
111
|
+
"1.20.5": "minecraft:generic.fall_damage_multiplier",
|
|
112
|
+
"1.21.2": "minecraft:fall_damage_multiplier"
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
"flying_speed": {
|
|
116
|
+
"ids": {
|
|
117
|
+
"1.7.2": "",
|
|
118
|
+
"1.12": "generic.flyingSpeed",
|
|
119
|
+
"1.16": "minecraft:generic.flying_speed",
|
|
120
|
+
"1.21.2": "minecraft:flying_speed"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"follow_range": {
|
|
124
|
+
"ids": {
|
|
125
|
+
"1.7.2": "generic.followRange",
|
|
126
|
+
"1.16": "minecraft:generic.follow_range",
|
|
127
|
+
"1.21.2": "minecraft:follow_range"
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
"friction_modifier": {
|
|
131
|
+
"ids": {
|
|
132
|
+
"1.7.2": "",
|
|
133
|
+
"26.2": "minecraft:friction_modifier"
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
"gravity": {
|
|
137
|
+
"ids": {
|
|
138
|
+
"1.7.2": "",
|
|
139
|
+
"1.20.5": "minecraft:generic.gravity",
|
|
140
|
+
"1.21.2": "minecraft:gravity"
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"jump_strength": {
|
|
144
|
+
"ids": {
|
|
145
|
+
"1.7.2": "horse.jumpStrength",
|
|
146
|
+
"1.16": "minecraft:horse.jump_strength",
|
|
147
|
+
"1.20.5": "minecraft:generic.jump_strength",
|
|
148
|
+
"1.21.2": "minecraft:jump_strength"
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"knockback_resistance": {
|
|
152
|
+
"ids": {
|
|
153
|
+
"1.7.2": "generic.knockbackResistance",
|
|
154
|
+
"1.16": "minecraft:generic.knockback_resistance",
|
|
155
|
+
"1.21.2": "minecraft:knockback_resistance"
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
"luck": {
|
|
159
|
+
"ids": {
|
|
160
|
+
"1.7.2": "",
|
|
161
|
+
"1.9": "generic.luck",
|
|
162
|
+
"1.16": "minecraft:generic.luck",
|
|
163
|
+
"1.21.2": "minecraft:luck"
|
|
164
|
+
}
|
|
165
|
+
},
|
|
166
|
+
"max_absorption": {
|
|
167
|
+
"ids": {
|
|
168
|
+
"1.7.2": "",
|
|
169
|
+
"1.20.2": "minecraft:generic.max_absorption",
|
|
170
|
+
"1.21.2": "minecraft:max_absorption"
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
"max_health": {
|
|
174
|
+
"ids": {
|
|
175
|
+
"1.7.2": "generic.maxHealth",
|
|
176
|
+
"1.16": "minecraft:generic.max_health",
|
|
177
|
+
"1.21.2": "minecraft:max_health"
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"mining_efficiency": {
|
|
181
|
+
"ids": {
|
|
182
|
+
"1.7.2": "",
|
|
183
|
+
"1.21": "minecraft:player.mining_efficiency",
|
|
184
|
+
"1.21.2": "minecraft:mining_efficiency"
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
"movement_efficiency": {
|
|
188
|
+
"ids": {
|
|
189
|
+
"1.7.2": "",
|
|
190
|
+
"1.21": "minecraft:generic.movement_efficiency",
|
|
191
|
+
"1.21.2": "minecraft:movement_efficiency"
|
|
192
|
+
}
|
|
193
|
+
},
|
|
194
|
+
"movement_speed": {
|
|
195
|
+
"ids": {
|
|
196
|
+
"1.7.2": "generic.movementSpeed",
|
|
197
|
+
"1.16": "minecraft:generic.movement_speed",
|
|
198
|
+
"1.21.2": "minecraft:movement_speed"
|
|
199
|
+
}
|
|
200
|
+
},
|
|
201
|
+
"name_tag_distance": {
|
|
202
|
+
"ids": {
|
|
203
|
+
"1.7.2": "",
|
|
204
|
+
"26.2": "minecraft:name_tag_distance"
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
"oxygen_bonus": {
|
|
208
|
+
"ids": {
|
|
209
|
+
"1.7.2": "",
|
|
210
|
+
"1.21": "minecraft:generic.oxygen_bonus",
|
|
211
|
+
"1.21.2": "minecraft:oxygen_bonus"
|
|
212
|
+
}
|
|
213
|
+
},
|
|
214
|
+
"safe_fall_distance": {
|
|
215
|
+
"ids": {
|
|
216
|
+
"1.7.2": "",
|
|
217
|
+
"1.20.5": "minecraft:generic.safe_fall_distance",
|
|
218
|
+
"1.21.2": "minecraft:safe_fall_distance"
|
|
219
|
+
}
|
|
220
|
+
},
|
|
221
|
+
"scale": {
|
|
222
|
+
"ids": {
|
|
223
|
+
"1.7.2": "",
|
|
224
|
+
"1.20.5": "minecraft:generic.scale",
|
|
225
|
+
"1.21.2": "minecraft:scale"
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
"sneaking_speed": {
|
|
229
|
+
"ids": {
|
|
230
|
+
"1.7.2": "",
|
|
231
|
+
"1.21": "minecraft:player.sneaking_speed",
|
|
232
|
+
"1.21.2": "minecraft:sneaking_speed"
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
"spawn_reinforcements": {
|
|
236
|
+
"ids": {
|
|
237
|
+
"1.7.2": "zombie.spawnReinforcements",
|
|
238
|
+
"1.16": "minecraft:zombie.spawn_reinforcements",
|
|
239
|
+
"1.21.2": "minecraft:spawn_reinforcements"
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
"step_height": {
|
|
243
|
+
"ids": {
|
|
244
|
+
"1.7.2": "",
|
|
245
|
+
"1.20.5": "minecraft:generic.step_height",
|
|
246
|
+
"1.21.2": "minecraft:step_height"
|
|
247
|
+
}
|
|
248
|
+
},
|
|
249
|
+
"submerged_mining_speed": {
|
|
250
|
+
"ids": {
|
|
251
|
+
"1.7.2": "",
|
|
252
|
+
"1.21": "minecraft:player.submerged_mining_speed",
|
|
253
|
+
"1.21.2": "minecraft:submerged_mining_speed"
|
|
254
|
+
}
|
|
255
|
+
},
|
|
256
|
+
"sweeping_damage_ratio": {
|
|
257
|
+
"ids": {
|
|
258
|
+
"1.7.2": "",
|
|
259
|
+
"1.21": "minecraft:player.sweeping_damage_ratio",
|
|
260
|
+
"1.21.2": "minecraft:sweeping_damage_ratio"
|
|
261
|
+
}
|
|
262
|
+
},
|
|
263
|
+
"tempt_range": {
|
|
264
|
+
"ids": {
|
|
265
|
+
"1.7.2": "",
|
|
266
|
+
"1.21.2": "minecraft:tempt_range"
|
|
267
|
+
}
|
|
268
|
+
},
|
|
269
|
+
"water_movement_efficiency": {
|
|
270
|
+
"ids": {
|
|
271
|
+
"1.7.2": "",
|
|
272
|
+
"1.21": "minecraft:generic.water_movement_efficiency",
|
|
273
|
+
"1.21.2": "minecraft:water_movement_efficiency"
|
|
274
|
+
}
|
|
275
|
+
},
|
|
276
|
+
"waypoint_receive_range": {
|
|
277
|
+
"ids": {
|
|
278
|
+
"1.7.2": "",
|
|
279
|
+
"1.21.6": "minecraft:waypoint_receive_range"
|
|
280
|
+
}
|
|
281
|
+
},
|
|
282
|
+
"waypoint_transmit_range": {
|
|
283
|
+
"ids": {
|
|
284
|
+
"1.7.2": "",
|
|
285
|
+
"1.21.6": "minecraft:waypoint_transmit_range"
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"""
|
|
2
|
+
The 'mcdex.banner_patterns' package provides the banner patterns of the game:
|
|
3
|
+
the 'MCBannerPatterns' catalogue, an enumeration of every banner pattern of the
|
|
4
|
+
data file 'banner_patterns.json' that ships with the package.
|
|
5
|
+
|
|
6
|
+
- MCBannerPatterns
|
|
7
|
+
"""
|
|
8
|
+
# Apache-2.0 license
|
|
9
|
+
# Copyright (c) 2026 Asger Jon Vistisen
|
|
10
|
+
from __future__ import annotations
|
|
11
|
+
|
|
12
|
+
from ._mc_banner_patterns import MCBannerPatterns
|
|
13
|
+
|
|
14
|
+
__all__ = (
|
|
15
|
+
'MCBannerPatterns',
|
|
16
|
+
)
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"""
|
|
2
|
+
MCBannerPatterns is the catalogue of the game's banner patterns: an enumeration
|
|
3
|
+
with one member for every banner pattern of the data file that ships with
|
|
4
|
+
mcdex, each the same banner pattern in every version, with the id each version
|
|
5
|
+
knows it by: what a banner's pattern takes.
|
|
6
|
+
"""
|
|
7
|
+
# Apache-2.0 license
|
|
8
|
+
# Copyright (c) 2026 Asger Jon Vistisen
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
from worktoy.keenum import Kee
|
|
12
|
+
|
|
13
|
+
from ..base import BannerPatternId, MCThing
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class MCBannerPatterns(MCThing):
|
|
17
|
+
"""
|
|
18
|
+
The catalogue of the game's banner patterns, each a member, found by its name
|
|
19
|
+
in capitals, in any case, or by its unique name:
|
|
20
|
+
|
|
21
|
+
squareBottomLeft = MCBannerPatterns.SQUARE_BOTTOM_LEFT
|
|
22
|
+
squareBottomLeft is MCBannerPatterns['square_bottom_left'] # True
|
|
23
|
+
squareBottomLeft['1.8'] # BannerPatternId('square_bottom_left', 'bl')
|
|
24
|
+
len(MCBannerPatterns)
|
|
25
|
+
|
|
26
|
+
Implementation
|
|
27
|
+
--------------
|
|
28
|
+
|
|
29
|
+
All of it is 'MCThing's, reading 'banner_patterns.json' beside this module.
|
|
30
|
+
mcdex's tools write the members, one for every name of that file.
|
|
31
|
+
"""
|
|
32
|
+
|
|
33
|
+
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
34
|
+
# NAMESPACE # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
35
|
+
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
|
36
|
+
|
|
37
|
+
# Class Variables
|
|
38
|
+
__data_file__ = 'banner_patterns.json'
|
|
39
|
+
__data_key__ = 'banner_patterns'
|
|
40
|
+
__id_class__ = BannerPatternId
|
|
41
|
+
__kind__ = 'banner pattern'
|
|
42
|
+
|
|
43
|
+
# Members, one for every name of 'banner_patterns.json'
|
|
44
|
+
BASE = Kee[str]('base')
|
|
45
|
+
BORDER = Kee[str]('border')
|
|
46
|
+
BRICKS = Kee[str]('bricks')
|
|
47
|
+
CIRCLE = Kee[str]('circle')
|
|
48
|
+
CREEPER = Kee[str]('creeper')
|
|
49
|
+
CROSS = Kee[str]('cross')
|
|
50
|
+
CURLY_BORDER = Kee[str]('curly_border')
|
|
51
|
+
DIAGONAL_LEFT = Kee[str]('diagonal_left')
|
|
52
|
+
DIAGONAL_RIGHT = Kee[str]('diagonal_right')
|
|
53
|
+
DIAGONAL_UP_LEFT = Kee[str]('diagonal_up_left')
|
|
54
|
+
DIAGONAL_UP_RIGHT = Kee[str]('diagonal_up_right')
|
|
55
|
+
FLOW = Kee[str]('flow')
|
|
56
|
+
FLOWER = Kee[str]('flower')
|
|
57
|
+
GLOBE = Kee[str]('globe')
|
|
58
|
+
GRADIENT = Kee[str]('gradient')
|
|
59
|
+
GRADIENT_UP = Kee[str]('gradient_up')
|
|
60
|
+
GUSTER = Kee[str]('guster')
|
|
61
|
+
HALF_HORIZONTAL = Kee[str]('half_horizontal')
|
|
62
|
+
HALF_HORIZONTAL_BOTTOM = Kee[str]('half_horizontal_bottom')
|
|
63
|
+
HALF_VERTICAL = Kee[str]('half_vertical')
|
|
64
|
+
HALF_VERTICAL_RIGHT = Kee[str]('half_vertical_right')
|
|
65
|
+
MOJANG = Kee[str]('mojang')
|
|
66
|
+
PIGLIN = Kee[str]('piglin')
|
|
67
|
+
RHOMBUS = Kee[str]('rhombus')
|
|
68
|
+
SKULL = Kee[str]('skull')
|
|
69
|
+
SMALL_STRIPES = Kee[str]('small_stripes')
|
|
70
|
+
SQUARE_BOTTOM_LEFT = Kee[str]('square_bottom_left')
|
|
71
|
+
SQUARE_BOTTOM_RIGHT = Kee[str]('square_bottom_right')
|
|
72
|
+
SQUARE_TOP_LEFT = Kee[str]('square_top_left')
|
|
73
|
+
SQUARE_TOP_RIGHT = Kee[str]('square_top_right')
|
|
74
|
+
STRAIGHT_CROSS = Kee[str]('straight_cross')
|
|
75
|
+
STRIPE_BOTTOM = Kee[str]('stripe_bottom')
|
|
76
|
+
STRIPE_CENTER = Kee[str]('stripe_center')
|
|
77
|
+
STRIPE_DOWNLEFT = Kee[str]('stripe_downleft')
|
|
78
|
+
STRIPE_DOWNRIGHT = Kee[str]('stripe_downright')
|
|
79
|
+
STRIPE_LEFT = Kee[str]('stripe_left')
|
|
80
|
+
STRIPE_MIDDLE = Kee[str]('stripe_middle')
|
|
81
|
+
STRIPE_RIGHT = Kee[str]('stripe_right')
|
|
82
|
+
STRIPE_TOP = Kee[str]('stripe_top')
|
|
83
|
+
TRIANGLE_BOTTOM = Kee[str]('triangle_bottom')
|
|
84
|
+
TRIANGLE_TOP = Kee[str]('triangle_top')
|
|
85
|
+
TRIANGLES_BOTTOM = Kee[str]('triangles_bottom')
|
|
86
|
+
TRIANGLES_TOP = Kee[str]('triangles_top')
|