-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Robert Quinn
committed
Jun 8, 2021
1 parent
2877c12
commit 1be90d9
Showing
11 changed files
with
785 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio Version 16 | ||
VisualStudioVersion = 16.0.31321.278 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Aurium", "Aurium\Aurium.csproj", "{562C2BE9-6687-4837-AD88-4AF1DE412231}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{562C2BE9-6687-4837-AD88-4AF1DE412231}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{562C2BE9-6687-4837-AD88-4AF1DE412231}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{562C2BE9-6687-4837-AD88-4AF1DE412231}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{562C2BE9-6687-4837-AD88-4AF1DE412231}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
GlobalSection(ExtensibilityGlobals) = postSolution | ||
SolutionGuid = {6B2070F6-4BAD-43BF-9025-F5E0113414F8} | ||
EndGlobalSection | ||
EndGlobal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<configuration> | ||
<startup> | ||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" /> | ||
</startup> | ||
</configuration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProjectGuid>{562C2BE9-6687-4837-AD88-4AF1DE412231}</ProjectGuid> | ||
<OutputType>Exe</OutputType> | ||
<RootNamespace>Aurium</RootNamespace> | ||
<AssemblyName>Aurium</AssemblyName> | ||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion> | ||
<FileAlignment>512</FileAlignment> | ||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> | ||
<Deterministic>true</Deterministic> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<PlatformTarget>AnyCPU</PlatformTarget> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
<DefineConstants>DEBUG;TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<PlatformTarget>AnyCPU</PlatformTarget> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<DefineConstants>TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<ApplicationIcon>Aurium.ico</ApplicationIcon> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Windows.Forms" /> | ||
<Reference Include="System.Xml.Linq" /> | ||
<Reference Include="System.Data.DataSetExtensions" /> | ||
<Reference Include="Microsoft.CSharp" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Net.Http" /> | ||
<Reference Include="System.Xml" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="Beam.cs" /> | ||
<Compile Include="Display.cs" /> | ||
<Compile Include="DLLImports.cs" /> | ||
<Compile Include="Hotkeys.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
<Compile Include="Tables.cs" /> | ||
<Compile Include="Variables.cs" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<None Include="App.config" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Content Include="Aurium.ico" /> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
</Project> |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
using System; | ||
using System.Threading; | ||
using System.Windows.Forms; | ||
using static Aurium.Variables; | ||
|
||
namespace Aurium | ||
{ | ||
class Recoil | ||
{ | ||
private static bool IsKeyDown(Keys key) | ||
{ return 0 != (DLLImports.GetAsyncKeyState((int)key) & 0x8000); } | ||
|
||
public static void RecoilLoop() | ||
{ | ||
while (true) | ||
{ | ||
if (Variables.Menu.isEnabled() && !string.IsNullOrEmpty(Weapon.getName())) | ||
{ | ||
while (IsKeyDown(Keys.RButton) && IsKeyDown(Keys.LButton)) | ||
{ | ||
for (int i = 0; i <= Weapon.getAmmo() - 1; i++) | ||
{ | ||
if (!IsKeyDown(Keys.LButton)) break; | ||
Smoothing(Weapon.isMuzzleBoost(Weapon.getShootingMilliSec()), | ||
Weapon.isMuzzleBoost(Weapon.getShotDelay(i)), | ||
(int)((((Weapon.getRecoilX(i) + GetRandomNumber(0.0, Weapon.getRandomness())) / 4) / Settings.getSensitivity()) * Weapon.getScopeMulitplier() * Weapon.getBarrelMultiplier()), | ||
(int)((((Weapon.getRecoilY(i) + GetRandomNumber(0.0, Weapon.getRandomness())) / 4) / Settings.getSensitivity()) * Weapon.getScopeMulitplier() * Weapon.getBarrelMultiplier())); | ||
DLLImports.mouse_event(0x0001, 0, 0, 0, 0); | ||
} | ||
} | ||
} | ||
Thread.Sleep(1); | ||
} | ||
} | ||
|
||
private static double GetRandomNumber(double minimum, double maximum) | ||
{ | ||
Random random = new Random(); | ||
return random.NextDouble() * (maximum - minimum) + minimum; | ||
} | ||
|
||
static private void Smoothing(double MS, double ControlledTime, int X, int Y) | ||
{ | ||
int oldX = 0, oldY = 0, oldT = 0; | ||
for (int i = 1; i <= (int)ControlledTime; ++i) | ||
{ | ||
int newX = i * X / (int)ControlledTime; | ||
int newY = i * Y / (int)ControlledTime; | ||
int newTime = i * (int)ControlledTime / (int)ControlledTime; | ||
DLLImports.mouse_event(1, newX - oldX, newY - oldY, 0, 0); | ||
PerciseSleep(newTime - oldT); | ||
oldX = newX; oldY = newY; oldT = newTime; | ||
} | ||
PerciseSleep((int)MS - (int)ControlledTime); | ||
} | ||
|
||
static private void PerciseSleep(int ms) | ||
{ | ||
DLLImports.QueryPerformanceFrequency(out long timerResolution); | ||
timerResolution /= 1000; | ||
|
||
DLLImports.QueryPerformanceCounter(out long currentTime); | ||
long wantedTime = currentTime / timerResolution + ms; | ||
currentTime = 0; | ||
while (currentTime < wantedTime) | ||
{ | ||
DLLImports.QueryPerformanceCounter(out currentTime); | ||
currentTime /= timerResolution; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using System; | ||
using System.Runtime.InteropServices; | ||
|
||
namespace Aurium | ||
{ | ||
class DLLImports | ||
{ | ||
[DllImport("user32.dll")] public static extern void mouse_event(int dwFlags, int dx, int dy, int dwData, int dwExtraInfo); | ||
[DllImport("user32.dll")] public static extern short GetAsyncKeyState(int vKey); | ||
[DllImport("Kernel32.dll")] public static extern bool QueryPerformanceCounter(out long lpPerformanceCount); | ||
[DllImport("Kernel32.dll")] public static extern bool QueryPerformanceFrequency(out long lpFrequency); | ||
[DllImport("user32.dll")] public static extern bool RegisterHotKey(IntPtr hWnd, int id, uint fsModifiers, uint vk); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
using System; | ||
|
||
namespace Aurium | ||
{ | ||
class Display | ||
{ | ||
private static void InitializeWindow() | ||
{ | ||
Console.SetWindowSize(50, 40); | ||
Console.SetBufferSize(50, 40); | ||
Console.Title = "Aurium"; | ||
PrintHeader(); | ||
} | ||
|
||
public static void PrintHeader() | ||
{ | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.WriteLine(@" _ _ "); | ||
Console.WriteLine(@" / \ _ _ _ __(_)_ _ _ __ ___ "); | ||
Console.WriteLine(@" / _ \| | | | '__| | | | | '_ ` _ \ "); | ||
Console.WriteLine(@" / ___ \ |_| | | | | |_| | | | | | |"); | ||
Console.WriteLine(@" /_/ \_\__,_|_| |_|\__,_|_| |_| |_|"); | ||
Console.WriteLine(); | ||
Console.WriteLine(" -------------------------------------------------"); | ||
Console.ResetColor(); | ||
Console.WriteLine(" Sensitivity Randomness"); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.Write(" "); | ||
Console.Write("{0:0.0}", Variables.Settings.getSensitivity()); | ||
Console.Write(" "); | ||
Console.Write("{0:0}", Variables.Weapon.getRandomness()); | ||
Console.WriteLine(); | ||
Console.ResetColor(); | ||
Console.WriteLine(); | ||
Console.Write(" Script Enabled: "); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.Write(Variables.Menu.isEnabled() + "\n"); | ||
Console.ResetColor(); | ||
|
||
Console.Write(" Current Weapon: "); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.Write(Variables.Weapon.getName() + "\n"); | ||
Console.ResetColor(); | ||
|
||
Console.Write(" Scope Attachment: "); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.Write(Variables.Weapon.getActiveScope() + "\n"); | ||
Console.ResetColor(); | ||
|
||
Console.Write(" Muzzle Attachment: "); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.Write(Variables.Weapon.getActiveBarrel() + "\n"); | ||
Console.WriteLine(); | ||
Console.WriteLine(" -------------------------------------------------"); | ||
Console.ResetColor(); | ||
Console.WriteLine(" CTRL + Number Pad:"); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
|
||
Console.WriteLine(); | ||
Console.WriteLine(" 0: Enable/Disable"); | ||
Console.WriteLine(); | ||
Console.WriteLine(" 1: Assault Rifle"); | ||
Console.WriteLine(" 2: Custom SMG"); | ||
Console.WriteLine(" 3: LR-300 Assault Rifle"); | ||
Console.WriteLine(" 4: M39"); | ||
Console.WriteLine(" 5: M92"); | ||
Console.WriteLine(" 6: M249"); | ||
Console.WriteLine(" 7: MP5A4"); | ||
Console.WriteLine(" 8: Semi-Automatic Rifle"); | ||
Console.WriteLine(" 9: Thompson"); | ||
Console.WriteLine(); | ||
Console.WriteLine(" +: Cycle Sights [None/Simple/Holo/8x/16x]"); | ||
Console.WriteLine(" Enter: Cycle Barrels [None/Silencer/Boost/Break]"); | ||
Console.WriteLine(); | ||
Console.ResetColor(); | ||
Console.WriteLine(" CTRL + Arrow Key:"); | ||
Console.WriteLine(); | ||
Console.ForegroundColor = ConsoleColor.DarkYellow; | ||
Console.WriteLine(" Randomness: [← Decrease] [→ Increase]"); | ||
Console.WriteLine(" In-game Sensitivity: [↓ Decrease] [↑ Increase]"); | ||
} | ||
|
||
static void Main(string[] args) | ||
{ | ||
InitializeWindow(); | ||
Hotkeys.Initiate.InitiateHotKeys(); | ||
Recoil.RecoilLoop(); | ||
} | ||
} | ||
} |
Oops, something went wrong.