{ "format_version": "1.10.0", "animation_controllers": { "controller.animation.sheep.move": { "states": { "default": { "animations": [ { "walk": "query.modified_move_speed" } ], "transitions": [ { "grazing": "query.is_grazing" } ] }, "grazing": { "animations": [ "grazing" ], "transitions": [ { "default": "query.all_animations_finished" } ] } } } } }
"controller.animation.tiger.move": { "states": { "default": { "animations": [ "base_pose", "walk" ], "transitions": [ { "angry": "query.is_angry" } // transition to angry state if query.is_angry returns true ], "blend_transition": 0.2 // when transitioning away from this state, cross-fade over 0.2 seconds }, "angry": { "animations": [ "roar", "extend_claws" ], "transitions": [ { "default": "query.any_animation_finished" } // transition back to default state when either the roar animation or extend_claws animation finishes ] } } }
"<controller_name>": { "states": { "<state_name>": { ... "transitions": [ // Evaluate the below expressions in order. // The first to return non-zero is the state to transition to. // If all are zero, then don't transition. { "<target_state_name_A>", "<expression>" }, { "<target_state_name_B>", "<expression>" }, ... ] } }, ... }For example:
"controller.animation.tiger.move": { "states": { "default": { "animations": [ "base_pose", "walk" ], "transitions": [ { "angry": "query.is_angry" }, // transition to angry state if query.is_angry returns true { "tired": "variable.is_tired" } // transition to tired state if variable.is_tired returns true ] }, "angry": { "animations": [ "roar", "extend_claws" ], "transitions": [ { "default": "query.any_animation_finished" } // transition back to default state when either the roar animation or extend_claws animation finishes ] }, "tired": { "animations": [ "yawn", "stretch" ], "transitions": [ { "default": "query.all_animation_finished" } // transition back to default state when the yawn and stretch animations have both finished ] } } }
``` { "format_version": "1.10.0", "animation_controllers": { "controller.animation.sheep.move": { "states": { "default": { "variables": { "ground_speed_curve": { "input": "query.ground_speed", "remap_curve": { "0.0": 0.2, "1.0": 0.7 } } }, "animations": [ "wiggle_nose", { "walk": "variable.ground_speed_curve" } ] } } } } } ```
"controller.animation.tiger.move": { "states": { "default": { "animations": [ //animations are ADDITIVE unless otherwise specified //in this case, base_pose will always be playing in the default state //walk will play as well if Entity.foo is greater than 0.0 "base_pose", { "walk": "variable.foo > 0.0" } ] } } }
{ "custom:tiger":{ "scripts":{ "pre_animation": { "variable.foo = math.sin(query.life_time)" } } } }
``` <animation_name>": { // optional "loop": <bool> // default = false. Should the animation loop back to t=0.0 when it finishes? "blend_weight": <expression> // default = "1.0". How much this animation is blended with the others. 0.0 = off. 1.0 = fully apply all transforms. Can be an expression - see the Animation Controller section below "animation_length": <float> // default = time of last key frame. At what time does the system consider this animation finished? "override_previous_animation": <bool> // default = false. Should the animation pose of the bone be set to the bind pose before applying this animation, thereby overriding any previous animations to this point? // required "bones": [ { "<bone_name>": { // must match the name of the bone specified in the geometry skeleton // various flavours of setting data // omitting a channel skips that channel for this animation of this bone // any number of floats below can be replaced by a string expression as described above; you don't have to replace all the floats on a line with expressions, only the ones you want to be expression-based "position": 1.0, // set x, y, and z to 1 "position": [1.0], // set x, y, and z to 1 "position": [1.0, 2.0, 3.0], // set x=1 , y=2 , and z=3 "rotation": 45.0, // set x, y, and z to 45 degrees "rotation": [45.0], // set x, y, and z to 45 degrees "rotation": [30.0, 0.0, 45.0], // set x, y, and z to the respective values (in degrees) // note: only uniform scaling is supported at this time "scale": 2.0, // scales the bone by 2.0 "scale": [2.0], // scales the bone by 2.0 // Key frame data is described below // Note that any of the above styles of values will work for "pre" and "post", and "pre" does not have to have the same format as "post" "rotation": { "0.0": [80.0, 0.0, 0.0], "0.1667": [-80.0, 0.0, 0.0], "0.333": [80.0, 0.0, 0.0] } // For discontinuous channel curve, you can specify a different value when interpolating to/from this key frame "rotation": { "0.3": { // the key field is the time stamp for this key frame: the value can be any of the above examples "pre": [30.0, 0.0, 45.0], // when interpolating towards this key frame from the previous, use this value "post": "180.0 * Math.Sin(global.key_frame_lerp_time)" // when at interpolating away from this key frame to the next, use this value } } // another example "rotation": { "0.0": [80.0, 0.0, 0.0], // start at an x rotation of 80 degrees "0.4": { "pre": [80.0, 0.0, 0.0], // stay at 80 until 0.4 seconds have elapsed "post": [0.0, 0.0, 0.0], // discontinuously pop the x rotation to 0.0 degrees }, "0.8": [-80.0, 0.0, 0.0] // using the previous frame's lerp mode, lerp to a x rotation of -80 degrees by 0.8 seconds } } ] } ```
{ "format_version": "1.10.0", "animation_controllers": { "controller.animation.my_mob.move": { "initial_state": "moving", "states": { "moving": { "animations": [ "wag_tail", "wiggle_ears", { "walk": "query.modified_move_speed" } ], "transitions": [ { "grazing": "query.is_grazing" } ] }, "grazing": { "animations": [ "grazing" ], "transitions": [ { "moving": "query.all_animations_finished" } ] } } } } }
"rotation": [90.0, 0.0, 0.0]
"rotation": ["cos(query.anim_pos * 38.17) * 80.0 * query.anim_speed", 0.0, 0.0]
{ "format_version": "1.8.0", "animations": { "animation.quadruped.walk": { "anim_time_update": "query.modified_distance_moved", "loop": true, "bones": { "leg0": { "rotation": [ "Math.cos(query.anim_time * 38.17) * 80.0", 0.0, 0.0 ] }, "leg1": { "rotation": [ "Math.cos(query.anim_time * 38.17) * -80.0", 0.0, 0.0 ] }, "leg2": { "rotation": [ "Math.cos(query.anim_time * 38.17) * -80.0", 0.0, 0.0 ] }, "leg3": { "rotation": [ "Math.cos(query.anim_time * 38.17) * 80.0", 0.0, 0.0 ] } } } } }
{ "format_version": "1.10.0", "minecraft:client_entity": { "description": { "identifier": "minecraft:pig", "min_engine_version": "1.8.0", "materials": { "default": "pig" }, "textures": { "default": "textures/entity/pig/pig", "saddled": "textures/entity/pig/pig_saddle" }, "geometry": { "default": "geometry.pig.v1.8" }, "animations": { "setup": "animation.pig.setup", "walk": "animation.quadruped.walk", "look_at_target": "animation.common.look_at_target", "baby_transform": "animation.pig.baby_transform" }, "scripts": { "animate": [ "setup", { "walk": "query.modified_move_speed" }, "look_at_target", { "baby_transform": "query.is_baby" } ] }, "render_controllers": [ "controller.render.pig" ], "spawn_egg": { "texture": "spawn_egg", "texture_index": 2 } } } }
"head": { "rotation": { "0.0":[0, 0, 0], "0.5": [ 0, 180, 0], "1.0": [0, 360, 0] } }
"head": { "scale": { "0.5": { "pre": [1, 1, 1], "post": 2.0 } "1.0": [ 1.0 ] } }
"arrays": { "geometries": { "Array.geos": ["Geometry.default", "Geometry.sheared"] } }, "geometry": "Array.geos[query.is_sheared]",Example Array for materials from the spider JSON
"arrays": { "materials": { "Array.materials": ["Material.default", "Material.invisible"] } }, "materials": [{ "*": "Array.materials[query.is_invisible]" }],Example Array for textures from the villager JSON
"arrays": { "textures": { "Array.skins": ["Texture.farmer", "Texture.librarian", "Texture.priest", "Texture.smith", "Texture.butcher"] } }, "textures": ["Array.skins[query.variant]"]Example with color for tinting of parts from Armor 1.0 render controller JSON:
"format_version": "1.8.0", "render_controllers": { "controller.render.armor.chest.v1.0": { "arrays": { "materials": { "array.armor_material": [ "material.armor", "material.armor_enchanted", "material.armor_leather", "material.armor_leather_enchanted" ] }, "textures": { "array.armor_texture": [ "texture.leather", "texture.chain", "texture.iron", "texture.diamond", "texture.gold" ] } }, "geometry": "geometry.armor", "materials" : [ { "body": "array.armor_material[query.armor_material_slot(1)]" }, { "leftarm": "array.armor_material[query.armor_material_slot(1)]" }, { "rightarm": "array.armor_material[query.armor_material_slot(1)]" } ], "part_visibility" : [ { "*": 0 }, { "body": "query.has_armor_slot(1)" }, { "leftarm": "query.has_armor_slot(1)" }, { "rightarm": "query.has_armor_slot(1)" } ], "color": { "r": "query.armor_color_slot(1, 0)", "g": "query.armor_color_slot(1, 1)", "b": "query.armor_color_slot(1, 2)", "a": "query.armor_color_slot(1, 3)" }, "textures": ["array.armor_texture[query.armor_texture_slot(1)]", "texture.enchanted"] } }Example with overlay_color from Wither Boss render controller JSON:
"format_version": "1.8.0", "render_controllers": { "controller.render.wither_boss": { "arrays": { "textures": { "Array.wither_state": ["Texture.invulnerable", "Texture.default"] } }, "geometry" : "Geometry.default", "materials" : [{ "*": "Material.default" }], "textures" : ["Array.wither_state[variable.display_normal_skin]"], "overlay_color" : { "r": "variable.is_invulnerable ? 1.0 : this", "g": "variable.is_invulnerable ? 1.0 : this", "b": "variable.is_invulnerable ? 1.0 : this", "a": "variable.is_invulnerable ? query.overlay_alpha : this" } } }Example with part_visibility for turning on and off visibility of parts from Llama JSON:
"format_version": "1.8.0", "render_controllers": { "controller.render.llama": { "arrays": { "textures": { "Array.base": ["Texture.creamy", "Texture.white", "Texture.brown", "Texture.gray"], "Array.decor": ["Texture.decor_none", "Texture.decor_white", "Texture.decor_orange", "Texture.decor_magenta", "Texture.decor_light_blue", "Texture.decor_yellow", "Texture.decor_lime", "Texture.decor_pink", "Texture.decor_gray", "Texture.decor_silver", "Texture.decor_cyan", "Texture.decor_purple", "Texture.decor_blue", "Texture.decor_brown", "Texture.decor_green", "Texture.decor_red", "Texture.decor_black"] } }, "geometry": "Geometry.default", "part_visibility": [{ "chest*": "query.is_chested" }], "materials": [{ "*": "Material.default" }], "textures": [ "Array.base[query.variant]", "Array.decor[variable.decor_texture_index]", "Texture.decor_none" ] } }Material array example from Horse render controllers. Saddle will override Mane, which will override TailA, etc.:
"materials": [ { "*": "Material.default" }, { "TailA": "Material.horse_hair" }, { "Mane": "Material.horse_hair" }, { "*Saddle*": "Material.horse_saddle" } ],
"format_version": "1.8.0", "render_controllers": { "controller.render.ocelot": { "arrays": { "textures": { "Array.skins": ["Texture.wild", "Texture.black", "Texture.red", "Texture.siamese"] } }, "geometry": "Geometry.default", "materials": [{ "*": "Material.default" }], "textures": ["Array.skins[query.variant]"] } }
"scale": [2.0, 2.0, 2.0] "scale": 2.0 "scale": [2.0]
This website is not affiliated with Mojang Studios or Microsoft