{
	"credit": "Created by FreshLX for Patrix",
	"textureSize": [64, 32],
	"models": [
		{
			"part": "head",
			"id": "head",
			"invertAxis": "xy",
			"translate": [-1, -10.5, 7],
			"submodels": [
				{
					"id": "Created_by_FreshLX_for_Patrix",
					"invertAxis": "xy",
					"translate": [0, 0, 0]
				}
			],
			"animations": [
				{
					"var.testing": "0",
					"var.r": "random(id)*pi*4",
					"var.t": "(time*pi*2)/6",
					"var.b": "var.r +(var.t*if(is_child, 1.5, 1))/8",
					"var.ls": "limb_swing/if(is_child, 1.8, 1)/1.1",
					"var.swim": "var.r +(var.t*if(is_child, 1.5, 1)+limb_swing/if(is_child, 1.5, 1))/2.5",
					"var.tail": "if(is_tamed, health/max_health, 0)",
					"var.run": "clamp(if(is_aggressive||limb_speed>=if(is_child, 0.45, 0.87 -0.17*clamp(sin(var.r+var.t/60)*90, 0, 1)), min(20, var.run +0.1 *frame_time*20), max(0, var.run -0.1 *frame_time*20)), 0, if(is_child, 1.2, 1))",
					"var.walk": "clamp(1-var.run, 0, 1)",
					"var.count_sleep": " clamp(if(!is_riding && is_sitting && limb_speed<=0.03 && !is_hurt, min(20, var.count_sleep  +0.00005+0.001*random(id) *frame_time*20), max(0, var.count_sleep  -0.005 *frame_time*20)), 0, 1)",
					"var.sleep": "(0.5-0.5*cos( clamp(var.count_sleep*60 -59, 0, clamp(1 +(1.44-sin(var.r+(var.t-(limb_swing/6))/370)*1.6)*50, 0, 1) )*pi ))",
					"var.count_sleep2": "clamp(if(var.sleep==1 && head_pitch==0 && head_yaw==0            , min(20, var.count_sleep2 +0.002                    *frame_time*20), max(0, var.count_sleep2 -0.01  *frame_time*20)), 0, 1)",
					"var.h": "clamp(if(head_pitch!=0 && var.sleep>0, min(20, var.h +0.1 *frame_time*20), max(0, var.h -0.1 *frame_time*20)), 0, 1)"
				},
				{
					"body.rx": "body.rx*(1-var.testing) +if(is_riding&&!is_sitting, -torad(45), is_sitting, -torad(45)*var.sleep +pi/4*var.testing, pi/2*var.testing)",
					"body_rotation.rx": "if(is_sitting||is_riding, torad(-20 +110*var.sleep), 0) +if(!is_on_ground&&is_in_water, sin(var.swim)/10, (torad(-5) +sin(torad(20)+var.ls)/7)*limb_speed*var.run ) +cos(var.b)/60*(1-var.sleep)",
					"body_rotation.ry": "                                                       if(!is_on_ground&&is_in_water, 0, sin(torad( 45)+var.ls)/15*clamp(limb_speed*6, 0, 1)*var.walk )",
					"body_rotation.rz": "      if(is_sitting||is_riding, torad(75 +sin(var.b))*var.sleep, -torad(head_yaw)/6*clamp(1-limb_speed*3, 0, 1)) +if(!is_on_ground&&is_in_water, 0, sin(torad( 45)+var.ls)/20*clamp(limb_speed*6, 0, 1)*var.walk )",
					"body_rotation.tx": "      if(is_sitting||is_riding, 2*var.sleep +sin(var.sleep*pi)*2, 0)",
					"body_rotation.ty": "-9.5 +if(is_sitting||is_riding, -sin(var.b)/10*(1-var.sleep) -0.5*var.sleep +if(is_riding, 1, 0), 0)",
					"body_rotation.tz": "if(!is_on_ground&&is_in_water, -2, (0.5 -sin(var.ls))*limb_speed*var.run -cos(var.ls*2)/3*clamp(limb_speed*6, 0, 1)*var.walk ) +if(is_sitting||is_riding, sin(var.b)/10*(1-var.sleep) +(2)*var.sleep +if(is_riding, -1, 0), -sin(var.b)/6) +2 -limb_speed",
					"mane2.rx": "if(is_sitting||is_riding, torad(30 +(-30 +sin(var.b)*2)*var.sleep  )        , 0) +if(!is_on_ground&&is_in_water, -cos(var.swim)/10, (torad(5) -sin(var.ls)/4)*limb_speed*var.run ) -cos(var.b)/60",
					"mane2.ry": "if(is_sitting||is_riding, torad(   -75                             )*var.sleep, -sin(pi/4+var.ls)/15*limb_speed*var.run -cos(pi/4+var.ls)/8*clamp(limb_speed*6, 0, 1)*var.walk )",
					"mane2.rz": "if(is_sitting||is_riding, torad(    (    -sin(var.b)*2)*var.sleep -sin(var.sleep*pi)*25) +clamp(-torad(head_yaw)/8, torad(-10), torad(10)), -torad(head_yaw)/8 )*clamp(1-limb_speed*3, 0, 1) -sin(torad( 45)+var.ls)/10*clamp(limb_speed*6, 0, 1)*var.walk",
					"mane_shake.ry": "mane.rz -body.rz +clamp(torad(head_yaw)/6, torad(-15), torad(15))*clamp(1-limb_speed*3, 0, 1)",
					"mane_shake.rz": "mane.rz +if(is_sitting||is_riding, torad(-8)*var.sleep, 0)",
					"mane2.tx": "     if(is_sitting||is_riding,    -1.25*var.sleep, 0)",
					"mane2.ty": "-2  +if(is_sitting||is_riding,      0.7*var.sleep, 0) +limb_speed/2",
					"mane2.tz": "1.2 +if(is_sitting||is_riding,   1 -1.8*var.sleep, 0)",
					"body.ty": "14   +if(is_sitting||is_riding, 3.5 +3.5*var.sleep +if(is_riding, -1.5, 0), 0)"
				}
			]
		},
		{
			"part": "body",
			"id": "body",
			"invertAxis": "xy",
			"translate": [0, -10, -2],
			"submodels": [
				{
					"id": "body_rotation",
					"invertAxis": "xy",
					"translate": [0, 10, 2],
					"rotate": [-90, 0, 0],
					"submodels": [
						{
							"id": "mane2",
							"invertAxis": "xy",
							"translate": [0, 2, 1.5],
							"submodels": [
								{
									"id": "mane_shake",
									"invertAxis": "xy",
									"translate": [0, 1, -1.5],
									"boxes": [
										{
											"coordinates": [-4, -1, -3, 8, 6, 7],
											"uvNorth": [31, 7, 39, 13],
											"uvEast": [24, 7, 31, 13],
											"uvSouth": [46, 7, 54, 13],
											"uvWest": [39, 7, 46, 13],
											"uvUp": [39, 7, 31, 0],
											"uvDown": [47, 0, 39, 7]
										}
									]
								}
							]
						}
					]
				}
			]
		},
		{
			"part": "leg1",
			"id": "leg1",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		},
		{
			"part": "leg2",
			"id": "leg2",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		},
		{
			"part": "leg3",
			"id": "leg3",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		},
		{
			"part": "leg4",
			"id": "leg4",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		},
		{
			"part": "mane",
			"id": "mane",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		},
		{
			"part": "tail",
			"id": "tail",
			"invertAxis": "xy",
			"translate": [0, 0, 0]
		}
	]
}