package com.thebrokenrail.gestus.emote; import net.minecraft.util.math.EulerAngle; import java.util.HashMap; import java.util.Map; public class EmoteFrame { public final Map normal; public final Map mirrored; public EmoteFrame(Map data) { normal = data; mirrored = mirror(data); } private static Map mirror(Map data) { Map result = new HashMap<>(); for (Map.Entry entry : data.entrySet()) { EmotePart newPart = entry.getKey().mirror(); result.put(newPart, new EulerAngle(entry.getValue().getPitch(), -entry.getValue().getYaw(), -entry.getValue().getRoll())); } return result; } }