Пример #1
0
        public static void Tab()
        {
            Prefab.MenuArea(new Rect(0, 0, 466, 436), "AIMBOT", () =>
            {
                GUILayout.BeginHorizontal();
                GUILayout.BeginVertical(GUILayout.Width(230));
                Prefab.Toggle("Enabled", ref AimbotOptions.Enabled);

                if (!AimbotOptions.Enabled)
                {
                    GUILayout.EndVertical();
                    GUILayout.EndHorizontal();
                    return;
                }

                Prefab.Toggle("Use Gun Distance", ref AimbotOptions.UseGunDistance);
                Prefab.Toggle("Smooth", ref AimbotOptions.Smooth);
                Prefab.Toggle($"Use Key ({HotkeyUtilities.GetHotkeyString("Aimbot", "_AimbotKey")})", ref AimbotOptions.OnKey);

                if (!AimbotOptions.OnKey)
                {
                    Prefab.Toggle($"Use Release Key ({HotkeyUtilities.GetHotkeyString("Aimbot", "_AimbotReleaseKey")})", ref AimbotOptions.UseReleaseAimKey);
                }

                Prefab.Toggle("Aim Through Walls", ref AimbotOptions.AimThroughWalls);
                GUILayout.Space(3);
                if (AimbotOptions.Smooth)
                {
                    GUILayout.Label("Aim Speed: " + AimbotOptions.AimSpeed, Prefab._TextStyle);
                    AimbotOptions.AimSpeed = (int)Prefab.Slider(1, AimbotOptions.MaxSpeed, AimbotOptions.AimSpeed, 200);
                }

                if (AimbotOptions.TargetMode == Misc.Enums.TargetMode.FOV)
                {
                    GUILayout.Label("FOV: " + AimbotOptions.FOV, Prefab._TextStyle);
                    AimbotOptions.FOV = (int)Prefab.Slider(1, 180, AimbotOptions.FOV, 200);
                    Prefab.Toggle("Target Closest in FOV", ref AimbotOptions.ClosestInFOV);
                }

                GUILayout.Label("Distance: " + AimbotOptions.Distance, Prefab._TextStyle);
                AimbotOptions.Distance  = (int)Prefab.Slider(50, 1000, AimbotOptions.Distance, 200);
                GUIContent[] TargetMode =
                {
                    new GUIContent("Distance"),
                    new GUIContent("FOV")
                };

                if (Prefab.List(200, "_TargetMode", new GUIContent("Target Mode: " + TargetMode[(int)AimbotOptions.TargetMode].text), TargetMode))
                {
                    AimbotOptions.TargetMode = (TargetMode)DropDown.Get("_TargetMode").ListIndex;
                }

                GUILayout.EndVertical();
                GUILayout.EndHorizontal();
            });
        }
Пример #2
0
        // Token: 0x060002CC RID: 716 RVA: 0x0001C8E0 File Offset: 0x0001AAE0
        public static void PlayerFlight()
        {
            Player mainPlayer = OptimizationVariables.MainPlayer;
            bool   flag       = !MiscOptions.PlayerFlight;
            bool   flag2      = flag;

            if (flag2)
            {
                ItemCloudAsset itemCloudAsset = mainPlayer.equipment.asset as ItemCloudAsset;
                mainPlayer.movement.itemGravityMultiplier = ((itemCloudAsset != null) ? itemCloudAsset.gravity : 1f);
            }
            else
            {
                mainPlayer.movement.itemGravityMultiplier = 0f;
                float flightSpeedMultiplier = MiscOptions.FlightSpeedMultiplier;
                bool  flag3 = HotkeyUtilities.IsHotkeyHeld("_FlyUp");
                bool  flag4 = flag3;
                if (flag4)
                {
                    mainPlayer.transform.position += mainPlayer.transform.up / 5f * flightSpeedMultiplier;
                }
                bool flag5 = HotkeyUtilities.IsHotkeyHeld("_FlyDown");
                bool flag6 = flag5;
                if (flag6)
                {
                    mainPlayer.transform.position -= mainPlayer.transform.up / 5f * flightSpeedMultiplier;
                }
                bool flag7 = HotkeyUtilities.IsHotkeyHeld("_FlyLeft");
                bool flag8 = flag7;
                if (flag8)
                {
                    mainPlayer.transform.position -= mainPlayer.transform.right / 5f * flightSpeedMultiplier;
                }
                bool flag9  = HotkeyUtilities.IsHotkeyHeld("_FlyRight");
                bool flag10 = flag9;
                if (flag10)
                {
                    mainPlayer.transform.position += mainPlayer.transform.right / 5f * flightSpeedMultiplier;
                }
                bool flag11 = HotkeyUtilities.IsHotkeyHeld("_FlyForward");
                bool flag12 = flag11;
                if (flag12)
                {
                    mainPlayer.transform.position += mainPlayer.transform.forward / 5f * flightSpeedMultiplier;
                }
                bool flag13 = HotkeyUtilities.IsHotkeyHeld("_FlyBackward");
                bool flag14 = flag13;
                if (flag14)
                {
                    mainPlayer.transform.position -= mainPlayer.transform.forward / 5f * flightSpeedMultiplier;
                }
            }
        }
 // Token: 0x06000170 RID: 368 RVA: 0x00002B12 File Offset: 0x00000D12
 public static IEnumerator AimToObject()
 {
     for (;;)
     {
         bool flag  = !DrawUtilities.ShouldRun() || !AimbotOptions.Enabled;
         bool flag4 = flag;
         if (flag4)
         {
             yield return(new WaitForSeconds(0.1f));
         }
         else
         {
             bool flag2 = AimbotCoroutines.LockedObject != null && AimbotCoroutines.LockedObject.transform != null && ESPComponent.MainCamera != null;
             bool flag5 = flag2;
             if (flag5)
             {
                 bool flag3 = HotkeyUtilities.IsHotkeyHeld("_AimbotKey") || !AimbotOptions.OnKey;
                 bool flag6 = flag3;
                 if (flag6)
                 {
                     AimbotCoroutines.IsAiming = true;
                     bool smooth = AimbotOptions.Smooth;
                     bool flag7  = smooth;
                     if (flag7)
                     {
                         AimbotCoroutines.SmoothAim(AimbotCoroutines.LockedObject);
                     }
                     else
                     {
                         AimbotCoroutines.Aim(AimbotCoroutines.LockedObject);
                     }
                 }
                 else
                 {
                     AimbotCoroutines.IsAiming = false;
                 }
             }
             else
             {
                 AimbotCoroutines.IsAiming = false;
             }
             yield return(new WaitForEndOfFrame());
         }
     }
     yield break;
 }
Пример #4
0
 public void Update()
 {
     HotkeyUtilities.Initialize();
     if (!HotkeyOptions.UnorganizedHotkeys.ContainsKey("_Menu"))
     {
         HotkeyUtilities.AddHotkey("Прочее", "Активация меню", "_MenuComponent", new KeyCode[]
         {
             KeyCode.F1
         });
     }
     if ((HotkeyOptions.UnorganizedHotkeys["_MenuComponent"].Keys.Length == 0 && Input.GetKeyDown(MenuComponent.MenuKey)) || HotkeyUtilities.IsHotkeyDown("_MenuComponent"))
     {
         MenuComponent.IsInMenu = !MenuComponent.IsInMenu;
         if (MenuComponent.IsInMenu)
         {
             SectionTab.CurrentSectionTab = null;
         }
     }
 }
Пример #5
0
        // Token: 0x060002B2 RID: 690 RVA: 0x0001BAA0 File Offset: 0x00019CA0
        public void Update()
        {
            bool needsKeys = HotkeyComponent.NeedsKeys;
            bool flag      = needsKeys;

            if (flag)
            {
                List <KeyCode> currentKeys = HotkeyComponent.CurrentKeys.ToList <KeyCode>();
                HotkeyComponent.CurrentKeys.Clear();
                foreach (KeyCode keyCode in HotkeyComponent.Keys)
                {
                    bool key   = Input.GetKey(keyCode);
                    bool flag2 = key;
                    if (flag2)
                    {
                        HotkeyComponent.CurrentKeys.Add(keyCode);
                    }
                }
                bool flag3 = HotkeyComponent.CurrentKeys.Count < HotkeyComponent.CurrentKeyCount && HotkeyComponent.CurrentKeyCount > 0;
                bool flag4 = flag3;
                if (flag4)
                {
                    HotkeyComponent.CurrentKeys = currentKeys;
                    HotkeyComponent.StopKeys    = true;
                }
                HotkeyComponent.CurrentKeyCount = HotkeyComponent.CurrentKeys.Count;
            }
            bool isInMenu = MenuComponent.IsInMenu;
            bool flag5    = !isInMenu;

            if (flag5)
            {
                foreach (KeyValuePair <string, Newtonsoft.Json.Serialization.Action> keyValuePair in HotkeyComponent.ActionDict)
                {
                    bool flag6 = HotkeyUtilities.IsHotkeyDown(keyValuePair.Key);
                    bool flag7 = flag6;
                    if (flag7)
                    {
                        keyValuePair.Value();
                    }
                }
            }
        }
Пример #6
0
        public static void Tab()
        {
            Prefab.MenuArea(new Rect(0, 0, 466, 436), "MORE MISC", () =>
            {
                GUILayout.BeginHorizontal();
                GUILayout.BeginVertical(GUILayout.Width(230));
                GUILayout.Space(2);
                Prefab.Toggle("Auto Item Pickup", ref ItemOptions.AutoItemPickup);

                if (ItemOptions.AutoItemPickup)
                {
                    GUILayout.Space(5);
                    GUILayout.Label("Delay: " + ItemOptions.ItemPickupDelay + "ms", Prefab._TextStyle);
                    GUILayout.Space(2);
                    ItemOptions.ItemPickupDelay = (int)Prefab.Slider(0, 3000, ItemOptions.ItemPickupDelay, 175);
                }

                GUILayout.Space(5);

                Prefab.Toggle("Oof on Death", ref WeaponOptions.OofOnDeath);

                GUILayout.Space(5);

                ItemUtilities.DrawFilterTab(ItemOptions.ItemFilterOptions);

                GUILayout.Space(5);

                GUIContent[] SpyMethods =
                {
                    new GUIContent("Remove All Visuals"),
                    new GUIContent("Random Image in Folder"),
                    new GUIContent("Send No Image"),
                    new GUIContent("No Anti-Spy")
                };

                GUILayout.Label("Anti-Spy Method:", Prefab._TextStyle);
                if (Prefab.List(200, "_SpyMethods",
                                new GUIContent(SpyMethods[MiscOptions.AntiSpyMethod].text),
                                SpyMethods))
                {
                    MiscOptions.AntiSpyMethod = DropDown.Get("_SpyMethods").ListIndex;
                }

                if (MiscOptions.AntiSpyMethod == 1)
                {
                    GUILayout.Space(2);
                    GUILayout.Label("Anti-Spy Image Folder:", Prefab._TextStyle);
                    MiscOptions.AntiSpyPath = Prefab.TextField(MiscOptions.AntiSpyPath, "", 225);
                }

                GUILayout.Space(2);
                Prefab.Toggle("Alert on Spy", ref MiscOptions.AlertOnSpy);

                GUILayout.Space(2);
                GUILayout.Label($"Min Time Between Spy: {Math.Round(MiscOptions.MinTimeBetweenSpy, 2)}s", Prefab._TextStyle);
                GUILayout.Space(2);
                MiscOptions.MinTimeBetweenSpy = Prefab.Slider(0, 10, MiscOptions.MinTimeBetweenSpy, 200);

                GUILayout.Space(4);
                Prefab.Toggle("Punch Killaura", ref MiscOptions.PunchAura);

                GUILayout.Space(5);
                Prefab.Toggle("Spinbot", ref MiscOptions.Spinbot);

                if (MiscOptions.Spinbot)
                {
                    GUILayout.Space(2);
                    Prefab.Toggle("Static Pitch", ref MiscOptions.StaticSpinbotPitch);
                    GUILayout.Space(2);
                    GUILayout.Label($"Spinbot Pitch {(!MiscOptions.StaticSpinbotPitch ? "Incr." : "")}: " + MiscOptions.SpinbotPitch, Prefab._TextStyle);
                    GUILayout.Space(2);
                    MiscOptions.SpinbotPitch = Prefab.Slider(0, 180, MiscOptions.SpinbotPitch, 200);
                    GUILayout.Space(2);
                    Prefab.Toggle("Static Yaw", ref MiscOptions.StaticSpinbotYaw);
                    GUILayout.Space(2);
                    GUILayout.Label($"Spinbot Yaw {(!MiscOptions.StaticSpinbotYaw ? "Incr." : "")}: " + MiscOptions.SpinbotYaw, Prefab._TextStyle);
                    GUILayout.Space(2);
                    MiscOptions.SpinbotYaw = Prefab.Slider(0, 360, MiscOptions.SpinbotYaw, 200);
                }

                /*GUILayout.Space(3);
                 * Prefab.Toggle("Spam Join Server", ref MiscOptions.AutoJoin);
                 * GUILayout.Space(5);
                 * MiscOptions.AutoJoinIP = Prefab.TextField(MiscOptions.AutoJoinIP, "IP:Port", 200);*/

                GUILayout.EndVertical();
                GUILayout.BeginVertical();

                GUILayout.Label("Time Acceleration: " + MiscOptions.TimeAcceleration + "x", Prefab._TextStyle);
                GUILayout.Space(2);

                MiscOptions.TimeAcceleration = (int)Prefab.Slider(1, 4, MiscOptions.TimeAcceleration, 200);

                int n = MiscOptions.TimeAcceleration;
                int v = n;

                v--;
                v |= v >> 1;
                v |= v >> 2;
                v |= v >> 4;
                v |= v >> 8;
                v |= v >> 16;
                v++;            // next power of 2

                int x = v >> 1; // previous power of 2
                MiscOptions.TimeAcceleration = (v - n) > (n - x) ? x : v;
                GUILayout.Space(5);

                Prefab.Toggle("Extended Pickup Range", ref MiscOptions.IncreaseNearbyItemDistance);

                if (MiscOptions.IncreaseNearbyItemDistance)
                {
                    GUILayout.Space(2);
                    GUILayout.Label("Range: " + MiscOptions.NearbyItemDistance, Prefab._TextStyle);
                    GUILayout.Space(2);
                    MiscOptions.NearbyItemDistance = (float)Math.Round(Prefab.Slider(0, 20, MiscOptions.NearbyItemDistance, 200), 2);
                }

                GUILayout.Space(5);

                Prefab.Toggle("Voicechat Key Pressed", ref MiscOptions.PerpetualVoiceChat);

                GUILayout.Space(5);

                Prefab.Toggle($"Zoom on Hotkey ({HotkeyUtilities.GetHotkeyString("Misc", "_Zoom")})", ref MiscOptions.ZoomOnHotkey);

                if (MiscOptions.ZoomOnHotkey)
                {
                    GUILayout.Space(2);
                    Prefab.Toggle("Zoom Instantly", ref MiscOptions.InstantZoom);
                    GUILayout.Space(2);
                    GUILayout.Label("Zoom FOV: " + MiscOptions.ZoomFOV, Prefab._TextStyle);
                    GUILayout.Space(2);
                    MiscOptions.ZoomFOV = (int)Prefab.Slider(0, 32, MiscOptions.ZoomFOV, 200);
                }

                GUILayout.Space(5);

                Prefab.Toggle("Message on Kill", ref MiscOptions.MessageOnKill);

                if (MiscOptions.MessageOnKill)
                {
                    GUILayout.Space(2);
                    MiscOptions.KillMessage = Prefab.TextField(MiscOptions.KillMessage, "Message: ", 175);
                }

                GUILayout.EndVertical();
                GUILayout.EndHorizontal();
            });
        }
 public void Update()
 {
     if (HotkeyComponent.NeedsKeys)
     {
         List <KeyCode> currentKeys = HotkeyComponent.CurrentKeys.ToList <KeyCode>();
         HotkeyComponent.CurrentKeys.Clear();
         foreach (KeyCode keyCode in HotkeyComponent.Keys)
         {
             if (Input.GetKey(keyCode))
             {
                 HotkeyComponent.CurrentKeys.Add(keyCode);
             }
         }
         if (HotkeyComponent.CurrentKeys.Count < HotkeyComponent.CurrentKeyCount && HotkeyComponent.CurrentKeyCount > 0)
         {
             HotkeyComponent.CurrentKeys = currentKeys;
             HotkeyComponent.StopKeys    = true;
         }
         HotkeyComponent.CurrentKeyCount = HotkeyComponent.CurrentKeys.Count;
     }
     if (!MenuComponent.IsInMenu)
     {
         foreach (KeyValuePair <string, Newtonsoft.Json.Serialization.Action> keyValuePair in HotkeyComponent.ActionDict)
         {
             if ((!MiscOptions.PanicMode || keyValuePair.Key == "_PanicButton") && HotkeyUtilities.IsHotkeyDown(keyValuePair.Key))
             {
                 keyValuePair.Value.Invoke();
             }
         }
         return;
     }
 }
    public static void VehicleFlight()
    {
        InteractableVehicle vehicle = OptimizationVariables.MainPlayer.movement.getVehicle();
        bool flag = vehicle == null;

        if (!flag)
        {
            Rigidbody component = vehicle.GetComponent <Rigidbody>();
            bool      flag2     = component == null;
            if (!flag2)
            {
                bool vehicleFly = MiscOptions.VehicleFly;
                if (vehicleFly)
                {
                    float num = MiscOptions.VehicleUseMaxSpeed ? (vehicle.asset.speedMax * Time.fixedDeltaTime) : (MiscOptions.SpeedMultiplier / 3f);
                    component.useGravity  = false;
                    component.isKinematic = true;
                    Transform transform = vehicle.transform;
                    bool      flag3     = HotkeyUtilities.IsHotkeyHeld("_VFStrafeUp");
                    if (flag3)
                    {
                        transform.position += new Vector3(0f, num * 0.65f, 0f);
                    }
                    bool flag4 = HotkeyUtilities.IsHotkeyHeld("_VFStrafeDown");
                    if (flag4)
                    {
                        transform.position -= new Vector3(0f, num * 0.65f, 0f);
                    }
                    bool flag5 = HotkeyUtilities.IsHotkeyHeld("_VFStrafeLeft");
                    if (flag5)
                    {
                        component.MovePosition(transform.position - transform.right * num);
                    }
                    bool flag6 = HotkeyUtilities.IsHotkeyHeld("_VFStrafeRight");
                    if (flag6)
                    {
                        component.MovePosition(transform.position + transform.right * num);
                    }
                    bool flag7 = HotkeyUtilities.IsHotkeyHeld("_VFMoveForward");
                    if (flag7)
                    {
                        component.MovePosition(transform.position + transform.forward * num);
                    }
                    bool flag8 = HotkeyUtilities.IsHotkeyHeld("_VFMoveBackward");
                    if (flag8)
                    {
                        component.MovePosition(transform.position - transform.forward * num);
                    }
                    bool flag9 = HotkeyUtilities.IsHotkeyHeld("_VFRotateRight");
                    if (flag9)
                    {
                        transform.Rotate(0f, 1f, 0f);
                    }
                    bool flag10 = HotkeyUtilities.IsHotkeyHeld("_VFRotateLeft");
                    if (flag10)
                    {
                        transform.Rotate(0f, -1f, 0f);
                    }
                    bool flag11 = HotkeyUtilities.IsHotkeyHeld("_VFRollLeft");
                    if (flag11)
                    {
                        transform.Rotate(0f, 0f, 2f);
                    }
                    bool flag12 = HotkeyUtilities.IsHotkeyHeld("_VFRollRight");
                    if (flag12)
                    {
                        transform.Rotate(0f, 0f, -2f);
                    }
                    bool flag13 = HotkeyUtilities.IsHotkeyHeld("_VFRotateUp");
                    if (flag13)
                    {
                        vehicle.transform.Rotate(-2f, 0f, 0f);
                    }
                    bool flag14 = HotkeyUtilities.IsHotkeyHeld("_VFRotateDown");
                    if (flag14)
                    {
                        vehicle.transform.Rotate(2f, 0f, 0f);
                    }
                }
                else
                {
                    component.useGravity  = true;
                    component.isKinematic = false;
                }
            }
        }
    }
Пример #9
0
        public static void Tab()
        {
            Prefab.MenuArea(new Rect(0, 0, 466, 436), "SILENT AIM", () =>
            {
                GUILayout.Space(2);
                Prefab.Toggle("Enabled", ref RaycastOptions.Enabled);

                if (!RaycastOptions.Enabled)
                {
                    return;
                }

                GUILayout.Space(5);

                Prefab.Toggle($"Hold Key ({HotkeyUtilities.GetHotkeyString("SilentAim", "_SilentAimKey")})", ref RaycastOptions.HoldKey);

                GUILayout.Space(5);

                GUILayout.Space(10);

                Prefab.Toggle("Sphere position prediction", ref SphereOptions.SpherePrediction);
                GUILayout.Space(5);

                if (!SphereOptions.SpherePrediction)
                {
                    GUILayout.Label("Sphere Radius: " + Math.Round(SphereOptions.SphereRadius, 2) + "m", Prefab._TextStyle);
                    Prefab.Slider(0, 16, ref SphereOptions.SphereRadius, 200);
                }

                GUILayout.Label("Recursion Level: " + SphereOptions.RecursionLevel, Prefab._TextStyle);
                SphereOptions.RecursionLevel = (int)Prefab.Slider(0, 4, SphereOptions.RecursionLevel, 200);

                GUILayout.Space(10);

                string[] TargetPriorities =
                {
                    "Players",
                    "Zombies",
                    "Sentries",
                    "Beds",
                    "Claim Flags",
                    "Storage",
                    "Vehicles"
                };

                for (int i = 0; i < TargetPriorities.Length; i++)
                {
                    TargetPriority target = (TargetPriority)i;
                    bool enabled          = RaycastOptions.Targets.Contains(target);
                    bool wasEnabled       = enabled;

                    Prefab.Toggle("Include " + TargetPriorities[i], ref enabled);
                    if (enabled && !wasEnabled)
                    {
                        RaycastOptions.Targets.Add(target);
                    }

                    else if (!enabled && wasEnabled)
                    {
                        RaycastOptions.Targets.Remove(target);
                    }
                }

                GUILayout.Space(15);

                Prefab.Toggle("Select Player", ref RaycastOptions.EnablePlayerSelection);
                if (RaycastOptions.EnablePlayerSelection)
                {
                    GUILayout.Space(2);
                    GUILayout.Label("Selection FOV: " + RaycastOptions.SelectedFOV, Prefab._TextStyle);
                    RaycastOptions.SelectedFOV = Prefab.Slider(1, 180, RaycastOptions.SelectedFOV, 200);
                    Prefab.Toggle("Only Shoot Selected", ref RaycastOptions.OnlyShootAtSelectedPlayer);
                }
                GUILayout.Space(2);
                Prefab.Toggle("Use FOV", ref RaycastOptions.SilentAimUseFOV);

                if (RaycastOptions.SilentAimUseFOV)
                {
                    GUILayout.Space(2);
                    GUILayout.Label("Aim FOV: " + RaycastOptions.SilentAimFOV, Prefab._TextStyle);
                    RaycastOptions.SilentAimFOV = Prefab.Slider(1, 180, RaycastOptions.SilentAimFOV, 200);
                }
            });
        }
Пример #10
0
        public void OV_ballistics()
        {
            Useable PlayerUse = OptimizationVariables.MainPlayer.equipment.useable;
            
            if (Provider.isServer)
            {
                OverrideUtilities.CallOriginal(PlayerUse);
                return;
            }
            
            if (Time.realtimeSinceStartup - PlayerLifeUI.hitmarkers[0].lastHit > PlayerUI.HIT_TIME)
            {
                PlayerLifeUI.hitmarkers[0].hitBuildImage.isVisible = false;
                PlayerLifeUI.hitmarkers[0].hitCriticalImage.isVisible = false;
                PlayerLifeUI.hitmarkers[0].hitEntitiyImage.isVisible = false;
            }

            ItemGunAsset PAsset = (ItemGunAsset)OptimizationVariables.MainPlayer.equipment.asset;
            PlayerLook Look = OptimizationVariables.MainPlayer.look;

            if (PAsset.projectile != null)
                return;

            List<BulletInfo> Bullets = (List<BulletInfo>)BulletsField.GetValue(PlayerUse);

            if (Bullets.Count == 0)
                return;

            RaycastInfo ri = null;
            
            if (RaycastOptions.Enabled && (!RaycastOptions.HoldKey || HotkeyUtilities.IsHotkeyHeld("_SilentAimKey")))
                RaycastUtilities.GenerateRaycast(out ri);
            
            if (Provider.modeConfigData.Gameplay.Ballistics)
            {
                if (ri == null)
                {
                    if (WeaponOptions.NoDrop && ri == null)
                    {
                        for (int i = 0; i < Bullets.Count; i++)
                        {
                            BulletInfo bulletInfo = Bullets[i];
                            Ray ray = new Ray(bulletInfo.pos, bulletInfo.dir);
                            RaycastInfo rayInfo =
                                DamageTool.raycast(ray, PAsset.ballisticTravel, RayMasks.DAMAGE_CLIENT);

                            if (IsRaycastInvalid(rayInfo))
                                bulletInfo.pos += bulletInfo.dir * PAsset.ballisticTravel;

                            else
                            {
                                EPlayerHit playerHit = CalcHitMarker(PAsset, ref rayInfo);
                                PlayerUI.hitmark(0, Vector3.zero, false, playerHit);
                                OptimizationVariables.MainPlayer.input.sendRaycast(rayInfo);
                                bulletInfo.steps = 254;
                            }
                        }

                        for (int i = Bullets.Count - 1; i >= 0; i--)
                        {
                            BulletInfo bulletInfo = Bullets[i];
                            bulletInfo.steps += 1;

                            if (bulletInfo.steps >= PAsset.ballisticSteps)
                                Bullets.RemoveAt(i);
                        }

                        return;
                    }

                    if (ri == null)
                    {
                        OverrideUtilities.CallOriginal(PlayerUse);
                        return;
                    }
                }
                for (int i = 0; i < Bullets.Count; i++)
                {
                    BulletInfo bulletInfo = Bullets[i];
                    double distance = VectorUtilities.GetDistance(OptimizationVariables.MainPlayer.transform.position, ri.point);

                    if (bulletInfo.steps * PAsset.ballisticTravel < distance)
                        continue;

                    EPlayerHit eplayerhit = CalcHitMarker(PAsset, ref ri);
                    PlayerUI.hitmark(0, Vector3.zero, false, eplayerhit);
                    OptimizationVariables.MainPlayer.input.sendRaycast(ri);
                    bulletInfo.steps = 254;
                }


                for (int k = Bullets.Count - 1; k >= 0; k--)
                {
                    BulletInfo bulletInfo = Bullets[k];
                    bulletInfo.steps += 1;
                    if (bulletInfo.steps >= PAsset.ballisticSteps)
                        Bullets.RemoveAt(k);
                }
            }
            else
            {
                if (ri != null)
                {
                    for (int i = 0; i < Bullets.Count; i++)
                    {
                        EPlayerHit eplayerhit = CalcHitMarker(PAsset, ref ri);
                        PlayerUI.hitmark(0, Vector3.zero, false, eplayerhit);
                        OptimizationVariables.MainPlayer.input.sendRaycast(ri);
                    }
                    
                    Bullets.Clear();
                }
                else
                    OverrideUtilities.CallOriginal(PlayerUse);
            }
        }
    public static void Initialize()
    {
        HotkeyUtilities.AddHotkey("АИМБОТ", "Аимбот On/Off", "_ToggleAimbot", new KeyCode[]
        {
            KeyCode.Keypad3
        });
        HotkeyUtilities.AddHotkey("АИМБОТ", "Аимбот по кнопке On/Off", "_AimbotOnKey", new KeyCode[]
        {
            KeyCode.Keypad4
        });
        HotkeyUtilities.AddHotkey("АИМБОТ", "Кнопка Аимбота", "_AimbotKey", new KeyCode[]
        {
            KeyCode.F
        });
        HotkeyUtilities.AddHotkey("ОРУЖИЕ", "Триггербот On/Off", "_ToggleTriggerbot", new KeyCode[]
        {
            KeyCode.Keypad5
        });
        HotkeyUtilities.AddHotkey("ОРУЖИЕ", "Без отдачи On/Off", "_ToggleNoRecoil", new KeyCode[]
        {
            KeyCode.Keypad6
        });
        HotkeyUtilities.AddHotkey("ОРУЖИЕ", "Без разброса On/Off", "_ToggleNoSpread", new KeyCode[]
        {
            KeyCode.Keypad7
        });
        HotkeyUtilities.AddHotkey("ОРУЖИЕ", "Без увода On/Off", "_ToggleNoSway", new KeyCode[]
        {
            KeyCode.Keypad8
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Полёт машины On/Off", "_VFToggle", new KeyCode[]
        {
            KeyCode.Slash
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Вверх", "_VFStrafeUp", new KeyCode[]
        {
            KeyCode.RightControl
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Вниз", "_VFStrafeDown", new KeyCode[]
        {
            KeyCode.LeftControl
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Влево", "_VFStrafeLeft", new KeyCode[]
        {
            KeyCode.LeftBracket
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Вправо", "_VFStrafeRight", new KeyCode[]
        {
            KeyCode.RightBracket
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Движение вперёд", "_VFMoveForward", new KeyCode[]
        {
            KeyCode.W
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Движение назад", "_VFMoveBackward", new KeyCode[]
        {
            KeyCode.S
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Поворот налево", "_VFRotateLeft", new KeyCode[]
        {
            KeyCode.A
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Поворот направо", "_VFRotateRight", new KeyCode[]
        {
            KeyCode.D
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Поворот вверх", "_VFRotateUp", new KeyCode[]
        {
            KeyCode.Space
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Поворот вниз", "_VFRotateDown", new KeyCode[]
        {
            KeyCode.LeftShift
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Вращаться влево", "_VFRollLeft", new KeyCode[]
        {
            KeyCode.Q
        });
        HotkeyUtilities.AddHotkey("Полёт Машины", "Вращаться вправо", "_VFRollRight", new KeyCode[]
        {
            KeyCode.E
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Вверх", "_FlyUp", new KeyCode[]
        {
            KeyCode.Space
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Вниз", "_FlyDown", new KeyCode[]
        {
            KeyCode.LeftControl
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Влево", "_FlyLeft", new KeyCode[]
        {
            KeyCode.A
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Вправо", "_FlyRight", new KeyCode[]
        {
            KeyCode.D
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Движение вперёд", "_FlyForward", new KeyCode[]
        {
            KeyCode.W
        });
        HotkeyUtilities.AddHotkey("Полёт игрока", "Движение назад", "_FlyBackward", new KeyCode[]
        {
            KeyCode.S
        });

        HotkeyUtilities.AddHotkey("Прочее", "Паник-кей", "_PanicButton", new KeyCode[]
        {
            KeyCode.Keypad0
        });
        HotkeyUtilities.AddHotkey("Прочее", "Свободная камера On/Off", "_ToggleFreecam", new KeyCode[]
        {
            KeyCode.Keypad2
        });
        HotkeyUtilities.AddHotkey("Прочее", "Выбор игрока", "_SelectPlayer", new KeyCode[]
        {
            KeyCode.LeftAlt
        });
        HotkeyUtilities.AddHotkey("Прочее", "Мгновенное отключение", "_InstantDisconnect", new KeyCode[]
        {
            KeyCode.F5
        });
        AddHotkey("Прочее", "Авто подбор вещей", "_AutoPickUp", new KeyCode[]
        {
            KeyCode.Mouse2
        });

        AddHotkey("Прочее", "Команда 1", "_Com1", new KeyCode[]
        {
            KeyCode.F8
        });
        AddHotkey("Прочее", "Команда 2", "_Com2", new KeyCode[]
        {
            KeyCode.F9
        });
        AddHotkey("Прочее", "Команда 3", "_Com3", new KeyCode[]
        {
            KeyCode.F10
        });
        AddHotkey("Прочее", "Команда 4", "_Com4", new KeyCode[]
        {
            KeyCode.F11
        });
        AddHotkey("Прочее", "Команда 5", "_Com5", new KeyCode[]
        {
            KeyCode.F12
        });
    }