Подписывайтесь на наш Telegram и не пропускайте важные новости! Перейти

Часть функционала SlothAC Rotation 360 3.1 Base

Начинающий
Начинающий
Статус
Оффлайн
Регистрация
23 Июн 2025
Сообщения
43
Реакции
0
Выберите загрузчик игры
  1. Vanilla
Код:
Expand Collapse Copy
           case "Ai" -> {
                yawDelta = MathHelper.wrapDegrees(yawToTarget - rotateVector.x);
                pitchDelta = MathHelper.wrapDegrees(pitchToTarget - rotateVector.y);

                float distance = (float) Math.hypot(yawDelta, pitchDelta);
                float smoothExp = MathHelper.clamp(distance / 15f, 0.15f, 0.75f);

                float jitterYaw = (float) ((Math.random() - 0.5) * 1.2f);

                float jitterPitch = (float) ((Math.random() - 0.5) * 0.3f);

                float nextYaw = rotateVector.x + (yawDelta * (smoothExp * 1f)) + jitterYaw;
                float nextPitch = rotateVector.y + (pitchDelta * (smoothExp * 0.6f)) + jitterPitch;
                
                float gcd = SensUtils.getGCDValue();
                nextYaw -= (nextYaw - rotateVector.x) % gcd;
                nextPitch -= (nextPitch - rotateVector.y) % gcd;
                
                rotateVector = new Vector2f(nextYaw, MathHelper.clamp(nextPitch, -90, 90));
            }
 
Код:
Expand Collapse Copy
           case "Ai" -> {
                yawDelta = MathHelper.wrapDegrees(yawToTarget - rotateVector.x);
                pitchDelta = MathHelper.wrapDegrees(pitchToTarget - rotateVector.y);

                float distance = (float) Math.hypot(yawDelta, pitchDelta);
                float smoothExp = MathHelper.clamp(distance / 15f, 0.15f, 0.75f);

                float jitterYaw = (float) ((Math.random() - 0.5) * 1.2f);

                float jitterPitch = (float) ((Math.random() - 0.5) * 0.3f);

                float nextYaw = rotateVector.x + (yawDelta * (smoothExp * 1f)) + jitterYaw;
                float nextPitch = rotateVector.y + (pitchDelta * (smoothExp * 0.6f)) + jitterPitch;
               
                float gcd = SensUtils.getGCDValue();
                nextYaw -= (nextYaw - rotateVector.x) % gcd;
                nextPitch -= (nextPitch - rotateVector.y) % gcd;
               
                rotateVector = new Vector2f(nextYaw, MathHelper.clamp(nextPitch, -90, 90));
            }
ротка в 20 строк? сс бы хоть показал но топчик +rep
 
Код:
Expand Collapse Copy
           case "Ai" -> {
                yawDelta = MathHelper.wrapDegrees(yawToTarget - rotateVector.x);
                pitchDelta = MathHelper.wrapDegrees(pitchToTarget - rotateVector.y);

                float distance = (float) Math.hypot(yawDelta, pitchDelta);
                float smoothExp = MathHelper.clamp(distance / 15f, 0.15f, 0.75f);

                float jitterYaw = (float) ((Math.random() - 0.5) * 1.2f);

                float jitterPitch = (float) ((Math.random() - 0.5) * 0.3f);

                float nextYaw = rotateVector.x + (yawDelta * (smoothExp * 1f)) + jitterYaw;
                float nextPitch = rotateVector.y + (pitchDelta * (smoothExp * 0.6f)) + jitterPitch;
               
                float gcd = SensUtils.getGCDValue();
                nextYaw -= (nextYaw - rotateVector.x) % gcd;
                nextPitch -= (nextPitch - rotateVector.y) % gcd;
               
                rotateVector = new Vector2f(nextYaw, MathHelper.clamp(nextPitch, -90, 90));
            }
тебе не нужен интернет
 
Назад
Сверху Снизу