{
	"$schema": "https://json-schema.org/draft/2020-12/schema",
	"$id": "https://schema.stfform.at/stfexp.constraint.parent.schema.json",
	"title": "Parent Constraint",
	"description": "A rigging behaviour that parents itself to its sources.",
	"stfImplementations": {
		"blender": {
			"representingType": "STF component on bpy.types.Object or bpy.types.Bone",
			"link": "https://codeberg.org/stf_format/stf_blender/src/branch/master/stfblender/stf_resources/stfexp/stfexp_constraint_parent.py"
		},
		"godot": {
			"representingType": "CopyTransformModifier3D",
			"link": "https://codeberg.org/stf_format/stf_godot/src/branch/master/addons/stf_godot/resources/stfexp/STFEXP_Constraint_Parent.gd"
		},
		"unity": {
			"representingType": "ParentConstraint or application specific components",
			"link": "https://codeberg.org/stf_format/stf_unity/src/branch/master/Runtime/Resources/Resources_STFEXP/STFEXP_Constraint_Parent.cs",
			"extra_links": {
				"Default Processor": "https://codeberg.org/stf_format/stf_unity/src/branch/master/Runtime/Processors/Processors_STFEXP/STFEXP_Constraint_Parent_Processor.cs",
				"VRChat Constraint Processor": "https://codeberg.org/stf_format/stf_unity/src/branch/master/AVA/AVA_VRChat/Editor/Processors/VRC_STFEXP_Constraint_Parent_Processor.cs"
			}
		}
	},
	"allOf": [{ "$ref": "https://schema.stfform.at/stf.schema.json#/$defs/stf_component_resource" }],
	"properties": {
		"type": {
			"const": "stfexp.constraint.parent"
		},
		"weight": {
			"type": "number",
			"default": 1.0,
			"description": "The total weight of this constraint."
		},
		"rotation_axes": {
			"type": "array",
			"items": {
				"type": "boolean"
			},
			"minItems": 3,
			"maxItems": 3,
			"default": [true, true, true],
			"description": "Which axes are affected by the sources rotation. Must have exactly 3 entries for X, Y, Z."
		},
		"translation_axes": {
			"type": "array",
			"items": {
				"type": "boolean"
			},
			"minItems": 3,
			"maxItems": 3,
			"default": [true, true, true],
			"description": "Which axes are affected by the sources translation. Must have exactly 3 entries for X, Y, Z."
		},
		"sources": {
			"type": "array",
			"items": {
				"type": "object",
				"title": "Constraint Source",
				"properties": {
					"weight": {
						"type": "number",
						"default": 0.5,
						"description": "How much of the sources transform to blend."
					},
					"source": {
						"$ref": "https://schema.stfform.at/stf.schema.json#resource_ref_path",
						"description": "Path to the node to which this node should be parented."
					}
				},
				"required": [
					"source"
				]
			},
			"description": "List of sources to which this node should be parented.",
			"stfExpand": true
		}
	},
	"required": [
		"type"
	],
	"additionalProperties": false
}