NautilusAnimation .java

net.minecraft.client.animation.definitions.NautilusAnimation (class): members: SWIMMING. strings: "inner_mouth", "lower_mouth", "upper_mouth", "body".

net.minecraft.client.animation.definitionsclass82 linesclient4.4 KB

API Surface (0)

No public/protected methods detected (fields or constants only).

Fields & Constants (1)

SWIMMING

String literals (4)

"body"
"upper_mouth"
"inner_mouth"
"lower_mouth"

Code Graph: Dependencies (4)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

NautilusAnimation.java82 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.client.animation.definitions;
2
3
import net.fabricmc.api.EnvType;
4
import net.fabricmc.api.Environment;
5
import net.minecraft.client.animation.AnimationChannel;
6
import net.minecraft.client.animation.AnimationDefinition;
7
import net.minecraft.client.animation.Keyframe;
8
import net.minecraft.client.animation.KeyframeAnimations;
9
10
@Environment(EnvType.CLIENT)
11
public class NautilusAnimation {
12
	public static final AnimationDefinition SWIMMING = AnimationDefinition.Builder.withLength(1.0F)
13
		.looping()
14
		.addAnimation(
15
			"body",
16
			new AnimationChannel(
17
				AnimationChannel.Targets.SCALE,
18
				new Keyframe(0.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
19
				new Keyframe(0.5F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.2F), AnimationChannel.Interpolations.LINEAR),
20
				new Keyframe(0.75F, KeyframeAnimations.scaleVec(1.0, 1.0, 0.9F), AnimationChannel.Interpolations.LINEAR),
21
				new Keyframe(0.875F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
22
				new Keyframe(1.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR)
23
			)
24
		)
25
		.addAnimation(
26
			"upper_mouth",
27
			new AnimationChannel(
28
				AnimationChannel.Targets.ROTATION,
29
				new Keyframe(0.0F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
30
				new Keyframe(0.5F, KeyframeAnimations.degreeVec(30.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
31
				new Keyframe(0.75F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
32
				new Keyframe(0.875F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
33
				new Keyframe(1.0F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR)
34
			)
35
		)
36
		.addAnimation(
37
			"upper_mouth",
38
			new AnimationChannel(
39
				AnimationChannel.Targets.SCALE,
40
				new Keyframe(0.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
41
				new Keyframe(0.5F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.4F), AnimationChannel.Interpolations.LINEAR),
42
				new Keyframe(0.75F, KeyframeAnimations.scaleVec(1.0, 1.0, 0.9F), AnimationChannel.Interpolations.LINEAR),
43
				new Keyframe(0.875F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
44
				new Keyframe(1.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR)
45
			)
46
		)
47
		.addAnimation(
48
			"inner_mouth",
49
			new AnimationChannel(
50
				AnimationChannel.Targets.SCALE,
51
				new Keyframe(0.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
52
				new Keyframe(0.5F, KeyframeAnimations.scaleVec(0.8F, 0.8F, 1.0), AnimationChannel.Interpolations.LINEAR),
53
				new Keyframe(0.75F, KeyframeAnimations.scaleVec(1.0, 1.0, 0.9F), AnimationChannel.Interpolations.LINEAR),
54
				new Keyframe(0.875F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
55
				new Keyframe(1.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR)
56
			)
57
		)
58
		.addAnimation(
59
			"lower_mouth",
60
			new AnimationChannel(
61
				AnimationChannel.Targets.ROTATION,
62
				new Keyframe(0.0F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
63
				new Keyframe(0.5F, KeyframeAnimations.degreeVec(-30.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
64
				new Keyframe(0.75F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
65
				new Keyframe(0.875F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR),
66
				new Keyframe(1.0F, KeyframeAnimations.degreeVec(0.0F, 0.0F, 0.0F), AnimationChannel.Interpolations.LINEAR)
67
			)
68
		)
69
		.addAnimation(
70
			"lower_mouth",
71
			new AnimationChannel(
72
				AnimationChannel.Targets.SCALE,
73
				new Keyframe(0.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
74
				new Keyframe(0.5F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.4F), AnimationChannel.Interpolations.LINEAR),
75
				new Keyframe(0.75F, KeyframeAnimations.scaleVec(1.0, 1.0, 0.9F), AnimationChannel.Interpolations.LINEAR),
76
				new Keyframe(0.875F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR),
77
				new Keyframe(1.0F, KeyframeAnimations.scaleVec(1.0, 1.0, 1.0), AnimationChannel.Interpolations.LINEAR)
78
			)
79
		)
80
		.build();
81
}
82

Decompiled Minecraft 26.3 source of NautilusAnimation (net/minecraft/client/animation/definitions/NautilusAnimation.java) with Mojang official mappings, stored verbatim on the site.