微调动画

This commit is contained in:
Atsuihsio 2024-05-22 01:02:21 +08:00
parent 63a88efd46
commit 99269f409a

View file

@ -39,8 +39,8 @@ public class ClientEventHandler {
private static void handleWeaponSway(LivingEntity entity) { private static void handleWeaponSway(LivingEntity entity) {
if (entity.getMainHandItem().is(TargetModTags.Items.GUN)) { if (entity.getMainHandItem().is(TargetModTags.Items.GUN)) {
float fps = Minecraft.getInstance().getFps(); float fps = Minecraft.getInstance().getFps();
if (fps <= 0) { if (fps <= 30) {
fps = 1f; fps = 30f;
} }
float times = 90f / fps; float times = 90f / fps;
double pose; double pose;
@ -67,8 +67,8 @@ public class ClientEventHandler {
private static void handleWeaponMove(LivingEntity entity) { private static void handleWeaponMove(LivingEntity entity) {
if (entity.getMainHandItem().is(TargetModTags.Items.GUN)) { if (entity.getMainHandItem().is(TargetModTags.Items.GUN)) {
float fps = Minecraft.getInstance().getFps(); float fps = Minecraft.getInstance().getFps();
if (fps <= 0) { if (fps <= 30) {
fps = 1f; fps = 30f;
} }
float times = 90f / fps; float times = 90f / fps;