├── vmm.dll
├── FTD3XX.dll
├── VmmFrost.dll
├── dbghelp.dll
├── symsrv.dll
├── tinylz4.dll
├── leechcore.dll
├── vcruntime140.dll
├── resources
├── Maps.bin
├── kek-icon.ico
├── visible.bundle
├── bender.black.otf
├── bender.bold.otf
├── bender.italic.otf
├── bender.light.otf
├── FILE_CRYPT_KEY.bin
├── NeoSansStdBold.otf
├── bender.regular.otf
├── NeoSansStdItalic.otf
├── NeoSansStdMedium.otf
├── NeoSansStdRegular.otf
└── visibilitycheck.bundle
├── eft-dma-radar
├── Maps.bin
├── Tarkov
│ ├── Features
│ │ └── MemoryWrites
│ │ │ ├── Owlmode.cs
│ │ │ ├── RageMode.cs
│ │ │ ├── Nightvision.cs
│ │ │ ├── ThermalVision.cs
│ │ │ ├── AntiAfk.cs
│ │ │ ├── Patches
│ │ │ ├── NoWepMalfPatch.cs
│ │ │ └── FixWildSpawnType.cs
│ │ │ ├── NoVisor.cs
│ │ │ ├── UI
│ │ │ └── AimbotRandomBoneForm.cs
│ │ │ ├── FullBright.cs
│ │ │ ├── MoveSpeed.cs
│ │ │ └── WideLean.cs
│ ├── GameWorld
│ │ ├── Exits
│ │ │ └── IExitPoint.cs
│ │ ├── Explosives
│ │ │ ├── IExplosiveItem.cs
│ │ │ └── MortarProjectile.cs
│ │ ├── Interactive
│ │ │ ├── Trunk.cs
│ │ │ ├── LootableContainer.cs
│ │ │ └── Switches.cs
│ │ └── WorldInteractableManager.cs
│ ├── Loot
│ │ ├── QuestItem.cs
│ │ ├── LootCorpse.cs
│ │ └── LootContainer.cs
│ ├── WebRadar
│ │ └── Data
│ │ │ ├── WebPlayerType.cs
│ │ │ ├── WebRadarUpdate.cs
│ │ │ └── WebRadarPlayer.cs
│ └── EFTPlayer
│ │ ├── BtrOperator.cs
│ │ └── SpecialCollections
│ │ ├── PlayerHistory.cs
│ │ └── PlayerWatchlist.cs
├── UI
│ ├── ESP
│ │ ├── ESP.cs
│ │ ├── IESPEntity.cs
│ │ └── EspForm.Designer.cs
│ ├── LootFilters
│ │ ├── UserLootFilter.cs
│ │ └── LootFilter.cs
│ ├── Radar
│ │ └── IMouseoverEntity.cs
│ ├── ColorPicker
│ │ ├── ColorItem.cs
│ │ ├── Container
│ │ │ └── ContainerColorOption.cs
│ │ └── ColorPicker.cs
│ ├── SKWidgetControl
│ │ └── WidgetClickEvent.cs
│ └── Misc
│ │ ├── InputBox.cs
│ │ └── InputBox.Designer.cs
└── eft-dma-radar.csproj
├── leechcore_driver.dll
├── Directory.Build.props
├── Maps
├── default.json
├── Lighthouse.json
├── Arena_Bowl.json
├── Arena_Fort.json
├── Woods.json
├── Arena_Bay5.json
├── Arena_Block.json
├── Arena_Airpit.json
├── Arena_Sawmill.json
├── Arena_ChopShop.json
├── Arena_Equator.json
├── Arena_Skybridge.json
├── Reserve.json
├── Labs.json
├── Interchange.json
├── Factory.json
├── Shoreline.json
├── default.svg
├── GroundZero.json
├── Customs.json
└── Streets.json
├── arena-dma-radar
├── UI
│ ├── ESP
│ │ ├── ESP.cs
│ │ ├── IESPEntity.cs
│ │ └── EspForm.Designer.cs
│ ├── LootFilters
│ │ ├── UserLootFilter.cs
│ │ └── LootFilter.cs
│ ├── Radar
│ │ └── IMouseoverEntity.cs
│ ├── ColorPicker
│ │ ├── ColorItem.cs
│ │ └── ColorPicker.cs
│ └── SKWidgetControl
│ │ └── WidgetClickEvent.cs
├── Arena
│ ├── Features
│ │ └── MemoryWrites
│ │ │ ├── Patches
│ │ │ └── NoWepMalfPatch.cs
│ │ │ ├── NoVisor.cs
│ │ │ ├── UI
│ │ │ └── AimbotRandomBoneForm.cs
│ │ │ ├── NoRecoil.cs
│ │ │ └── Chams.cs
│ ├── GameWorld
│ │ ├── Interactive
│ │ │ └── ArenaPresetRefillContainer.cs
│ │ └── InteractiveManager.cs
│ ├── Loot
│ │ └── LootContainer.cs
│ └── ArenaPlayer
│ │ ├── LocalPlayer.cs
│ │ └── Plugins
│ │ └── GearManager.cs
└── arena-dma-radar.csproj
├── eft-dma-shared
├── Common
│ ├── Features
│ │ ├── IMemPatchFeature.cs
│ │ ├── IMemWriteFeature.cs
│ │ ├── IFeature.cs
│ │ ├── MemWriteFeature.cs
│ │ └── MemPatchFeature.cs
│ ├── Ballistics
│ │ ├── G1DragModel.cs
│ │ ├── BallisticSimulationOutput.cs
│ │ └── BallisticsInfo.cs
│ ├── Unity
│ │ ├── IWorldEntity.cs
│ │ ├── LowLevel
│ │ │ ├── Types
│ │ │ │ ├── IMonoType.cs
│ │ │ │ ├── MonoByteArray.cs
│ │ │ │ ├── MonoString.cs
│ │ │ │ └── RemoteBytes.cs
│ │ │ ├── LowLevelCache.cs
│ │ │ └── Hooks
│ │ │ │ └── NativeOffsets.cs
│ │ ├── Collections
│ │ │ ├── MemList.cs
│ │ │ ├── MemHashSet.cs
│ │ │ └── MemDictionary.cs
│ │ ├── Bones.cs
│ │ └── UnityOffsets.cs
│ ├── Players
│ │ ├── IPlayer.cs
│ │ └── ILocalPlayer.cs
│ ├── Misc
│ │ ├── Config
│ │ │ ├── IConfig.cs
│ │ │ └── ChamsConfig.cs
│ │ ├── SizeChecker.cs
│ │ ├── MessagePack
│ │ │ ├── Vector2Formatter.cs
│ │ │ ├── Vector3Formatter.cs
│ │ │ └── ResolverGenerator.cs
│ │ ├── Commercial
│ │ │ └── LoneLogging.cs
│ │ ├── SharedPaints.cs
│ │ ├── Native.cs
│ │ ├── Data
│ │ │ ├── TarkovMarket
│ │ │ │ └── FleaTax.cs
│ │ │ └── LootFilterEntry.cs
│ │ ├── FileCrypt.cs
│ │ ├── PrecisionTimer.cs
│ │ ├── Pools
│ │ │ └── IPooledObject.cs
│ │ └── ResourceJanitor.cs
│ ├── Maps
│ │ ├── IMapEntity.cs
│ │ ├── LoneMapParams.cs
│ │ ├── ILoneMap.cs
│ │ └── LoneMapManager.cs
│ ├── DMA
│ │ ├── FpgaAlgo.cs
│ │ ├── ScatterAPI
│ │ │ ├── IScatterEntry.cs
│ │ │ ├── ScatterReadMap.cs
│ │ │ └── ScatterReadRound.cs
│ │ └── MemPointer.cs
│ └── ESP
│ │ ├── ESPPlayerRenderMode.cs
│ │ └── ViewMatrix.cs
└── eft-dma-shared.csproj
├── README.md
├── .github
└── ISSUE_TEMPLATE
│ ├── outage-report.md
│ └── bug_report.md
├── LICENSE
├── eft-dma-radar.sln
└── .gitattributes
/vmm.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/vmm.dll
--------------------------------------------------------------------------------
/FTD3XX.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/FTD3XX.dll
--------------------------------------------------------------------------------
/VmmFrost.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/VmmFrost.dll
--------------------------------------------------------------------------------
/dbghelp.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/dbghelp.dll
--------------------------------------------------------------------------------
/symsrv.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/symsrv.dll
--------------------------------------------------------------------------------
/tinylz4.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/tinylz4.dll
--------------------------------------------------------------------------------
/leechcore.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/leechcore.dll
--------------------------------------------------------------------------------
/vcruntime140.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/vcruntime140.dll
--------------------------------------------------------------------------------
/resources/Maps.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/Maps.bin
--------------------------------------------------------------------------------
/eft-dma-radar/Maps.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/eft-dma-radar/Maps.bin
--------------------------------------------------------------------------------
/leechcore_driver.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/leechcore_driver.dll
--------------------------------------------------------------------------------
/resources/kek-icon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/kek-icon.ico
--------------------------------------------------------------------------------
/resources/visible.bundle:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/visible.bundle
--------------------------------------------------------------------------------
/resources/bender.black.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/bender.black.otf
--------------------------------------------------------------------------------
/resources/bender.bold.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/bender.bold.otf
--------------------------------------------------------------------------------
/resources/bender.italic.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/bender.italic.otf
--------------------------------------------------------------------------------
/resources/bender.light.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/bender.light.otf
--------------------------------------------------------------------------------
/resources/FILE_CRYPT_KEY.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/FILE_CRYPT_KEY.bin
--------------------------------------------------------------------------------
/resources/NeoSansStdBold.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/NeoSansStdBold.otf
--------------------------------------------------------------------------------
/resources/bender.regular.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/bender.regular.otf
--------------------------------------------------------------------------------
/resources/NeoSansStdItalic.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/NeoSansStdItalic.otf
--------------------------------------------------------------------------------
/resources/NeoSansStdMedium.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/NeoSansStdMedium.otf
--------------------------------------------------------------------------------
/resources/NeoSansStdRegular.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/NeoSansStdRegular.otf
--------------------------------------------------------------------------------
/resources/visibilitycheck.bundle:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kek-m8/kek-eft-dma/HEAD/resources/visibilitycheck.bundle
--------------------------------------------------------------------------------
/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 | $(NoWarn);NU1701
4 |
5 |
--------------------------------------------------------------------------------
/Maps/default.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": [ "default" ],
3 | "x": 640,
4 | "y": 360,
5 | "scale": 1.00,
6 | "svgScale": 1.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "default.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Lighthouse.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["lighthouse"],
3 | "x": 544,
4 | "y": 721.5,
5 | "scale": 1,
6 | "svgScale": 3.5,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Lighthouse.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Bowl.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_Bowl"],
3 | "x": 642.5,
4 | "y": 280,
5 | "scale": 7,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Bowl.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Fort.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_Prison"],
3 | "x": 757,
4 | "y": 89,
5 | "scale": 8.9,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Fort.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Woods.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["woods"],
3 | "x": 724,
4 | "y": 463,
5 | "scale": 1.05,
6 | "svgScale": 4.5,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Woods.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Bay5.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_Bay5"],
3 | "x": 377.5,
4 | "y": 730,
5 | "scale": 5.525,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Bay5.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Block.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_Yard"],
3 | "x": 923.5,
4 | "y": 1307.5,
5 | "scale": 9.5,
6 | "svgScale": 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Block.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Airpit.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_AirPit"],
3 | "x": 699.5,
4 | "y": 665.5,
5 | "scale": 6.725,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Airpit.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Sawmill.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_saw"],
3 | "x": 4277.5,
4 | "y": -800,
5 | "scale": 6.65,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Sawmill.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_ChopShop.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_AutoService"],
3 | "x": 6210.5,
4 | "y": 7800,
5 | "scale": 15,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_ChopShop.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Equator.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_equator_TDM_02"],
3 | "x": 633,
4 | "y": 577.5,
5 | "scale": 9.5,
6 | "svgScale" : 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Equator.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/Maps/Arena_Skybridge.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["Arena_RailwayStation"],
3 | "x": 510,
4 | "y": 260,
5 | "scale": 7,
6 | "svgScale": 2.50,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Arena_Skybridge.svg"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/Owlmode.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 |
7 | namespace LonesEFTRadar.Tarkov.Features.MemoryWrites
8 | {
9 | class Owlmode
10 | {
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ESP/ESP.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.Misc;
2 |
3 | namespace eft_dma_radar.UI.ESP
4 | {
5 | internal static class ESP
6 | {
7 | ///
8 | /// ESP Configuration.
9 | ///
10 | public static ESPConfig Config { get; } = Program.Config.ESP;
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/ESP/ESP.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.UI.Misc;
2 |
3 | namespace arena_dma_radar.UI.ESP
4 | {
5 | internal static class ESP
6 | {
7 | ///
8 | /// ESP Configuration.
9 | ///
10 | public static ESPConfig Config { get; } = Program.Config.ESP;
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/RageMode.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Features;
2 |
3 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
4 | {
5 | public sealed class RageMode : MemWriteFeature
6 | {
7 | /// Container to set the Enabled property. Uses default implementation.
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Features/IMemPatchFeature.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Features
2 | {
3 | public interface IMemPatchFeature : IFeature
4 | {
5 | ///
6 | /// Try Apply the MemPatch.
7 | /// Does not throw.
8 | ///
9 | ///
10 | bool TryApply();
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/Maps/Reserve.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["rezervbase"],
3 | "x": 1810,
4 | "y": 1613,
5 | "scale": 5.99,
6 | "svgScale": 1.5,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Reserve.svg"
12 | },
13 | {
14 | "minHeight": null,
15 | "maxHeight": -8,
16 | "filename": "Reserve_-1f.svg"
17 | }
18 | ]
19 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Ballistics/G1DragModel.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Ballistics
2 | {
3 | internal readonly struct G1DragModel
4 | {
5 | public readonly float Mach;
6 | public readonly float Ballist;
7 |
8 | public G1DragModel(float mach, float ballist)
9 | {
10 | Mach = mach;
11 | Ballist = ballist;
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## What is this?
2 | This is an up-to-date build of my version of Lone DMA EFT/Arena Radar. This is a standalone copy of the software with *No Restrictions*.
3 |
4 | ## Arena
5 | - Arena is supported and will be maintained going forward.
6 |
7 | Compiled releases can be found [here](https://github.com/kek-m8/kek-eft-dma/releases)
8 |
9 | If you wish to support me you can do so [here](https://buymeacoffee.com/kekmate)
10 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/LootFilters/UserLootFilter.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 |
3 | namespace eft_dma_radar.UI.LootFilters
4 | {
5 | public sealed class UserLootFilter
6 | {
7 | [JsonPropertyName("enabled")] public bool Enabled { get; set; } = true;
8 |
9 | [JsonInclude]
10 | [JsonPropertyName("entries")]
11 | public List Entries { get; init; } = new();
12 | }
13 | }
--------------------------------------------------------------------------------
/arena-dma-radar/UI/LootFilters/UserLootFilter.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 |
3 | namespace arena_dma_radar.UI.LootFilters
4 | {
5 | public sealed class UserLootFilter
6 | {
7 | [JsonPropertyName("enabled")] public bool Enabled { get; set; } = true;
8 |
9 | [JsonInclude]
10 | [JsonPropertyName("entries")]
11 | public List Entries { get; init; } = new();
12 | }
13 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/IWorldEntity.cs:
--------------------------------------------------------------------------------
1 | using System.Numerics;
2 |
3 | namespace eft_dma_shared.Common.Unity
4 | {
5 | ///
6 | /// Defines an Entity that has a 3D GameWorld Position.
7 | ///
8 | public interface IWorldEntity
9 | {
10 | ///
11 | /// Entity's Unity Position in Local Game World.
12 | ///
13 | ref Vector3 Position { get; }
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Players/IPlayer.cs:
--------------------------------------------------------------------------------
1 | using System.Numerics;
2 |
3 | namespace eft_dma_shared.Common.Players
4 | {
5 | ///
6 | /// Interface defining a Player.
7 | ///
8 | public interface IPlayer
9 | {
10 | ulong Base { get; }
11 | string Name { get; }
12 | ref Vector3 Position { get; }
13 | Vector2 Rotation { get; }
14 | Skeleton Skeleton_ { get; }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Maps/Labs.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": [ "laboratory" ],
3 | "x": 3115,
4 | "y": -1095,
5 | "scale": 8.3,
6 | "svgScale": 2.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": -1,
11 | "filename": "Labs_-1f.svg"
12 | },
13 | {
14 | "minHeight": -1,
15 | "maxHeight": 3,
16 | "filename": "Labs_1f.svg"
17 | },
18 | {
19 | "minHeight": 3,
20 | "maxHeight": null,
21 | "filename": "Labs_2f.svg"
22 | }
23 | ]
24 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Features/IMemWriteFeature.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA.ScatterAPI;
2 |
3 | namespace eft_dma_shared.Common.Features
4 | {
5 | public interface IMemWriteFeature : IFeature
6 | {
7 | ///
8 | /// Apply the MemWrite feature via Scatter Write.
9 | /// Must not throw.
10 | ///
11 | ///
12 | void TryApply(ScatterWriteHandle writes);
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Exits/IExitPoint.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.ESP;
2 | using eft_dma_radar.UI.Radar;
3 | using eft_dma_shared.Common.Maps;
4 | using eft_dma_shared.Common.Unity;
5 |
6 | namespace eft_dma_radar.Tarkov.GameWorld.Exits
7 | {
8 | ///
9 | /// Defines a contract for a point that can be used to exit the map.
10 | ///
11 | public interface IExitPoint : IWorldEntity, IMapEntity, IMouseoverEntity, IESPEntity
12 | {
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Ballistics/BallisticSimulationOutput.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Ballistics
2 | {
3 | public readonly ref struct BallisticSimulationOutput
4 | {
5 | public readonly float DropCompensation;
6 | public readonly float TravelTime;
7 |
8 | public BallisticSimulationOutput(float dropCompensation, float travelTime)
9 | {
10 | DropCompensation = dropCompensation;
11 | TravelTime = travelTime;
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/Maps/Interchange.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["interchange"],
3 | "x": 397,
4 | "y": 494,
5 | "scale": 1.09,
6 | "svgScale": 5.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Interchange.svg"
12 | },
13 | {
14 | "minHeight": 26,
15 | "maxHeight": 31,
16 | "filename": "Interchange_1f.svg"
17 | },
18 | {
19 | "minHeight": 31,
20 | "maxHeight": null,
21 | "filename": "Interchange_2f.svg"
22 | }
23 | ]
24 | }
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Loot/QuestItem.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 |
3 | namespace eft_dma_radar.Tarkov.Loot
4 | {
5 | ///
6 | /// Defines a static/dynamic spawn Quest Item (not normal loot).
7 | ///
8 | public sealed class QuestItem : LootItem
9 | {
10 | public QuestItem(TarkovMarketItem entry) : base(entry)
11 | {
12 | }
13 |
14 | public QuestItem(string id, string name) : base(id, name)
15 | {
16 | }
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Config/IConfig.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Unity.LowLevel;
2 |
3 | namespace eft_dma_shared.Common.Misc.Config
4 | {
5 | public interface IConfig
6 | {
7 | LowLevelCache LowLevelCache { get; }
8 | ChamsConfig ChamsConfig { get; }
9 | bool MemWritesEnabled { get; }
10 | bool AdvancedMemWrites { get; }
11 | int MonitorWidth { get; }
12 | int MonitorHeight { get; }
13 |
14 | void Save();
15 | Task SaveAsync();
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/outage-report.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Outage report
3 | about: Report a major outage (game update,etc.)
4 | title: "[OUTAGE] "
5 | labels: outage
6 | assignees: ''
7 |
8 | ---
9 |
10 | ***Please check if there is another open issue for this already before opening another.***
11 | NO/YES I checked.
12 |
13 | **Is this for EFT or Arena?**
14 | EFT/Arena
15 |
16 | **Was there a recent Launcher/Game update?**
17 | Yes/No
18 |
19 | **What functionality is no longer working?**
20 | Stuck on waiting for raid start, etc.
21 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ESP/IESPEntity.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_shared.Common.Unity;
3 |
4 | namespace eft_dma_radar.UI.ESP
5 | {
6 | ///
7 | /// Defines an entity that can be drawn on Fuser ESP.
8 | ///
9 | public interface IESPEntity : IWorldEntity
10 | {
11 | ///
12 | /// Draw this Entity on Fuser ESP.
13 | ///
14 | /// SKCanvas instance to draw on.
15 | void DrawESP(SKCanvas canvas, LocalPlayer localPlayer);
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/ESP/IESPEntity.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.ArenaPlayer;
2 | using eft_dma_shared.Common.Unity;
3 |
4 | namespace arena_dma_radar.UI.ESP
5 | {
6 | ///
7 | /// Defines an entity that can be drawn on Fuser ESP.
8 | ///
9 | public interface IESPEntity : IWorldEntity
10 | {
11 | ///
12 | /// Draw this Entity on Fuser ESP.
13 | ///
14 | /// SKCanvas instance to draw on.
15 | void DrawESP(SKCanvas canvas, LocalPlayer localPlayer);
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/Types/IMonoType.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Unity.LowLevel.Types
2 | {
3 | public interface IMonoType
4 | {
5 | ///
6 | /// Data for this Mono object. May include padding for Mono interop.
7 | ///
8 | Span Data { get; }
9 |
10 | ///
11 | /// Convert the object to a RemoteBytes object and persists it to Remote Memory.
12 | /// Incurs a Memory Write.
13 | ///
14 | ///
15 | RemoteBytes ToRemoteBytes();
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/Maps/Factory.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": [
3 | "factory4_day",
4 | "factory4_night"
5 | ],
6 | "x": 64.9,
7 | "y": 67,
8 | "scale": 0.994,
9 | "svgScale": 36.00,
10 | "mapLayers": [
11 | {
12 | "minHeight": null,
13 | "maxHeight": null,
14 | "filename": "Factory.svg"
15 | },
16 | {
17 | "minHeight": null,
18 | "maxHeight": -0.8,
19 | "filename": "Factory_-1f.svg"
20 | },
21 | {
22 | "minHeight": 2.8,
23 | "maxHeight": 6.5,
24 | "filename": "Factory_2f.svg"
25 | },
26 | {
27 | "minHeight": 6.5,
28 | "maxHeight": null,
29 | "filename": "Factory_3f.svg"
30 | }
31 | ]
32 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Maps/IMapEntity.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Players;
2 | using eft_dma_shared.Common.Unity;
3 | using SkiaSharp;
4 |
5 | namespace eft_dma_shared.Common.Maps
6 | {
7 | ///
8 | /// Defines an entity that can be drawn on the 2D Radar Map.
9 | ///
10 | public interface IMapEntity : IWorldEntity
11 | {
12 | ///
13 | /// Draw this Entity on the Radar Map.
14 | ///
15 | /// SKCanvas instance to draw on.
16 | void Draw(SKCanvas canvas, LoneMapParams mapParams, ILocalPlayer localPlayer);
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | BSD Zero Clause License
2 |
3 | Copyright (c) 2025 lone-dma
4 |
5 | Permission to use, copy, modify, and/or distribute this software for any
6 | purpose with or without fee is hereby granted.
7 |
8 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
9 | REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10 | AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
11 | INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12 | LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13 | OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14 | PERFORMANCE OF THIS SOFTWARE.
15 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Loot/LootCorpse.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 |
3 | namespace eft_dma_radar.Tarkov.Loot
4 | {
5 | public sealed class LootCorpse : LootContainer
6 | {
7 | public override string Name => PlayerObject?.Name ?? "Body";
8 | ///
9 | /// Constructor.
10 | ///
11 | /// Name of corpse (example: Killa).
12 | public LootCorpse(IReadOnlyList loot) : base(loot)
13 | {
14 | }
15 |
16 | ///
17 | /// Corpse container's associated player object (if any).
18 | ///
19 | public Player PlayerObject { get; init; }
20 | }
21 | }
--------------------------------------------------------------------------------
/eft-dma-radar/UI/Radar/IMouseoverEntity.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_shared.Common.Maps;
3 |
4 | namespace eft_dma_radar.UI.Radar
5 | {
6 | ///
7 | /// Defines a Radar Map Mouseover Entity.
8 | ///
9 | public interface IMouseoverEntity : IMapEntity
10 | {
11 | ///
12 | /// Cached 'Mouseover' Position on the Radar GUI. Used for mouseover events.
13 | /// Uses zoomed coordinates and is refreshed on each render cycle.
14 | ///
15 | Vector2 MouseoverPosition { get; set; }
16 |
17 | void DrawMouseover(SKCanvas canvas, LoneMapParams mapParams, LocalPlayer localPlayer);
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/Radar/IMouseoverEntity.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.ArenaPlayer;
2 | using eft_dma_shared.Common.Maps;
3 |
4 | namespace arena_dma_radar.UI.Radar
5 | {
6 | ///
7 | /// Defines a Radar Map Mouseover Entity.
8 | ///
9 | public interface IMouseoverEntity : IMapEntity
10 | {
11 | ///
12 | /// Cached 'Mouseover' Position on the Radar GUI. Used for mouseover events.
13 | /// Uses zoomed coordinates and is refreshed on each render cycle.
14 | ///
15 | Vector2 MouseoverPosition { get; set; }
16 |
17 |
18 | void DrawMouseover(SKCanvas canvas, LoneMapParams mapParams, LocalPlayer localPlayer);
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/SizeChecker.cs:
--------------------------------------------------------------------------------
1 | using System.Runtime.CompilerServices;
2 |
3 | namespace eft_dma_shared.Common.Misc
4 | {
5 | ///
6 | /// Caches Type Sizes of value types.
7 | ///
8 | /// Type to check.
9 | public static class SizeChecker
10 | {
11 | ///
12 | /// Size of this Type.
13 | ///
14 | public static readonly int Size = GetSize();
15 |
16 | private static int GetSize()
17 | {
18 | if (RuntimeHelpers.IsReferenceOrContainsReferences())
19 | throw new NotSupportedException(typeof(T).ToString());
20 | return Unsafe.SizeOf();
21 | }
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/Maps/Shoreline.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["shoreline"],
3 | "x": 1096,
4 | "y": 648,
5 | "scale": 0.995,
6 | "svgScale": 3.5,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "dimBaseLayer": false,
12 | "filename": "Shoreline.svg"
13 | },
14 | {
15 | "minHeight": null,
16 | "maxHeight": -6,
17 | "filename": "Shoreline_-1f.svg"
18 | },
19 | {
20 | "minHeight": -4,
21 | "maxHeight": -2,
22 | "filename": "Shoreline_1f.svg"
23 | },
24 | {
25 | "minHeight": -1,
26 | "maxHeight": 1,
27 | "filename": "Shoreline_2f.svg"
28 | },
29 | {
30 | "minHeight": 2,
31 | "maxHeight": null,
32 | "filename": "Shoreline_3f.svg"
33 | }
34 | ]
35 | }
--------------------------------------------------------------------------------
/Maps/default.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Explosives/IExplosiveItem.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.ESP;
2 | using eft_dma_shared.Common.Maps;
3 | using eft_dma_shared.Common.Unity;
4 |
5 | namespace eft_dma_radar.Tarkov.GameWorld.Explosives
6 | {
7 | public interface IExplosiveItem : IWorldEntity, IMapEntity, IESPEntity
8 | {
9 | ///
10 | /// Base address of the explosive item.
11 | ///
12 | ulong Addr { get; }
13 | ///
14 | /// True if the explosive is in an active state, otherwise False.
15 | ///
16 | bool IsActive { get; }
17 | ///
18 | /// Refresh the state of the explosive item.
19 | ///
20 | void Refresh();
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ColorPicker/ColorItem.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_radar.UI.ColorPicker
2 | {
3 | ///
4 | /// Defines a Color Menu Item in Color Picker.
5 | ///
6 | /// Backing enum type.
7 | public class ColorItem
8 | where TEnum : Enum
9 | {
10 | public TEnum Option { get; }
11 |
12 | private ColorItem(TEnum option)
13 | {
14 | Option = option;
15 | }
16 |
17 | public override string ToString()
18 | {
19 | return Option.ToString();
20 | }
21 |
22 | public static ColorItem CreateInstance(TEnum option)
23 | {
24 | return new ColorItem(option);
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/ColorPicker/ColorItem.cs:
--------------------------------------------------------------------------------
1 | namespace arena_dma_radar.UI.ColorPicker
2 | {
3 | ///
4 | /// Defines a Color Menu Item in Color Picker.
5 | ///
6 | /// Backing enum type.
7 | public class ColorItem
8 | where TEnum : Enum
9 | {
10 | public TEnum Option { get; }
11 |
12 | private ColorItem(TEnum option)
13 | {
14 | Option = option;
15 | }
16 |
17 | public override string ToString()
18 | {
19 | return Option.ToString();
20 | }
21 |
22 | public static ColorItem CreateInstance(TEnum option)
23 | {
24 | return new ColorItem(option);
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/Maps/GroundZero.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": [
3 | "Sandbox",
4 | "Sandbox_high"
5 | ],
6 | "x": 99.5,
7 | "y": 364.2,
8 | "scale": 1,
9 | "svgScale": 16.00,
10 | "mapLayers": [
11 | {
12 | "minHeight": null,
13 | "maxHeight": null,
14 | "filename": "GroundZero.svg"
15 | },
16 | {
17 | "minHeight": null,
18 | "maxHeight": 16,
19 | "dimBaseLayer": false,
20 | "filename": "GroundZero_-1f.svg"
21 | },
22 | {
23 | "minHeight": 16,
24 | "maxHeight": 26,
25 | "dimBaseLayer": false,
26 | "filename": "GroundZero_1f.svg"
27 | },
28 | {
29 | "minHeight": 26,
30 | "maxHeight": 31,
31 | "filename": "GroundZero_2f.svg"
32 | },
33 | {
34 | "minHeight": 31,
35 | "maxHeight": null,
36 | "filename": "GroundZero_3f.svg"
37 | }
38 | ]
39 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/DMA/FpgaAlgo.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.DMA
2 | {
3 | ///
4 | /// FPGA Read Algorithm
5 | ///
6 | public enum FpgaAlgo : int
7 | {
8 | ///
9 | /// Auto 'fpga' parameter.
10 | ///
11 | Auto = -1,
12 | ///
13 | /// Async Normal Read (default)
14 | ///
15 | AsyncNormal = 0,
16 | ///
17 | /// Async Tiny Read
18 | ///
19 | AsyncTiny = 1,
20 | ///
21 | /// Old Normal Read
22 | ///
23 | OldNormal = 2,
24 | ///
25 | /// Old Tiny Read
26 | ///
27 | OldTiny = 3
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/ESP/ESPPlayerRenderMode.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.ESP
2 | {
3 | public enum ESPPlayerRenderMode : int
4 | {
5 | ///
6 | /// No player bones/box are rendered. Only a dot on 'center of mass'.
7 | ///
8 | None = 0,
9 | ///
10 | /// Full player bones are rendered.
11 | ///
12 | Bones = 1,
13 | ///
14 | /// Box ESP.
15 | ///
16 | Box = 2,
17 | ///
18 | /// Renders a dot showing unit's presence.
19 | ///
20 | Presence = 3,
21 | ///
22 | /// Renders a box with bones inside
23 | ///
24 | BonesNBox = 4
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/Maps/Customs.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": ["bigmap"],
3 | "x": 369,
4 | "y": 265.6,
5 | "scale": 0.992,
6 | "svgScale" : 5.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Customs.svg"
12 | },
13 | {
14 | "minHeight": null,
15 | "maxHeight": -1.8,
16 | "dimBaseLayer": false,
17 | "filename": "Customs_-1f.svg"
18 | },
19 | {
20 | "minHeight": -1.8,
21 | "maxHeight": 1.82,
22 | "dimBaseLayer": false,
23 | "filename": "Customs_1f.svg"
24 | },
25 | {
26 | "minHeight": 1.82,
27 | "maxHeight": 4.7,
28 | "dimBaseLayer": false,
29 | "filename": "Customs_2f.svg"
30 | },
31 | {
32 | "minHeight": 4.7,
33 | "maxHeight": null,
34 | "dimBaseLayer": false,
35 | "filename": "Customs_3f.svg"
36 | }
37 | ]
38 | }
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/bug_report.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Bug report
3 | about: Report any major bugs (no feature requests)
4 | title: "[BUG] "
5 | labels: bug, outage
6 | assignees: ''
7 |
8 | ---
9 |
10 | ***Please check if there is another open issue for this already before opening another.***
11 | NO/YES I checked.
12 |
13 | **Describe the bug**
14 | A clear and concise description of what the bug is.
15 |
16 | **To Reproduce**
17 | Steps to reproduce the behavior.
18 |
19 | **Expected behavior**
20 | A clear and concise description of what you expected to happen.
21 |
22 | **Screenshots**
23 | If applicable, add screenshots to help explain your problem.
24 |
25 | **Desktop (please complete the following information):**
26 | - OS: [e.g. Windows 10]
27 | - Version [e.g. 22h2]
28 |
29 | **Additional context**
30 | Add any other context about the problem here.
31 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/WebRadar/Data/WebPlayerType.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_radar.Tarkov.WebRadar.Data
2 | {
3 | ///
4 | /// Defines Player Unit Type (Player,PMC,Scav,etc.)
5 | ///
6 | public enum WebPlayerType : int
7 | {
8 | ///
9 | /// Bot Player.
10 | ///
11 | Bot = 0,
12 | ///
13 | /// LocalPlayer running the Web Server.
14 | ///
15 | LocalPlayer = 1,
16 | ///
17 | /// Teammate of LocalPlayer.
18 | ///
19 | Teammate = 2,
20 | ///
21 | /// Human-Controlled Player.
22 | ///
23 | Player = 3,
24 | ///
25 | /// Human-Controlled Scav.
26 | ///
27 | PlayerScav = 4
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Maps/LoneMapParams.cs:
--------------------------------------------------------------------------------
1 | using SkiaSharp;
2 |
3 | namespace eft_dma_shared.Common.Maps
4 | {
5 | ///
6 | /// Contains multiple map parameters used by the GUI.
7 | ///
8 | public sealed class LoneMapParams
9 | {
10 | ///
11 | /// Currently loaded Map File.
12 | ///
13 | public LoneMapConfig Map { get; init; }
14 | ///
15 | /// Rectangular 'zoomed' bounds of the Bitmap to display.
16 | ///
17 | public SKRect Bounds { get; init; }
18 | ///
19 | /// Regular -> Zoomed 'X' Scale correction.
20 | ///
21 | public float XScale { get; init; }
22 | ///
23 | /// Regular -> Zoomed 'Y' Scale correction.
24 | ///
25 | public float YScale { get; init; }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/DMA/ScatterAPI/IScatterEntry.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Pools;
2 |
3 | namespace eft_dma_shared.Common.DMA.ScatterAPI
4 | {
5 | public interface IScatterEntry : IPooledObject
6 | {
7 | ///
8 | /// Virtual Address to read from.
9 | ///
10 | ulong Address { get; }
11 | ///
12 | /// Count of bytes to read.
13 | ///
14 | int CB { get; }
15 | ///
16 | /// True if this read has failed, otherwise False.
17 | ///
18 | bool IsFailed { get; set; }
19 |
20 | ///
21 | /// Parse the memory buffer and set the result value.
22 | ///
23 | /// Scatter read handle.
24 | void SetResult(VmmFrost.LeechCore.SCATTER_HANDLE hScatter);
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Features/IFeature.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Concurrent;
2 |
3 | namespace eft_dma_shared.Common.Features
4 | {
5 | public interface IFeature
6 | {
7 | bool CanRun { get; }
8 | void OnApply();
9 | void OnGameStart();
10 | void OnRaidStart();
11 | void OnRaidEnd();
12 | void OnGameStop();
13 |
14 | #region Static Interface
15 | private static readonly ConcurrentBag _features = new();
16 | ///
17 | /// All Memory Write Features.
18 | ///
19 | public static IEnumerable AllFeatures => _features;
20 |
21 | ///
22 | /// Add a feature to the collection.
23 | ///
24 | /// Feature to add.
25 | protected static void Register(IFeature feature) => _features.Add(feature);
26 | #endregion
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/Types/MonoByteArray.cs:
--------------------------------------------------------------------------------
1 | using System.Buffers.Binary;
2 |
3 | namespace eft_dma_shared.Common.Unity.LowLevel.Types
4 | {
5 | public sealed class MonoByteArray : IMonoType
6 | {
7 | private const int _p1 = 0x18;
8 | private const int _p2 = 0x4;
9 | private readonly byte[] _data;
10 |
11 | ///
12 | /// Raw Data for this object. Includes inserted padding and length.
13 | ///
14 | public Span Data => _data;
15 |
16 | public MonoByteArray(byte[] data)
17 | {
18 | _data = new byte[_p1 + 4 + _p2 + data.Length];
19 | BinaryPrimitives.WriteInt32LittleEndian(_data.AsSpan(_p1), data.Length);
20 | data.CopyTo(_data, _p1 + 4 + _p2);
21 | }
22 |
23 | public RemoteBytes ToRemoteBytes()
24 | {
25 | return new RemoteBytes(this);
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/WebRadar/Data/WebRadarUpdate.cs:
--------------------------------------------------------------------------------
1 | using MessagePack;
2 |
3 | namespace eft_dma_radar.Tarkov.WebRadar.Data
4 | {
5 | [MessagePackObject]
6 | public sealed class WebRadarUpdate
7 | {
8 | ///
9 | /// Update version (used for ordering).
10 | ///
11 | [Key(0)]
12 | public uint Version { get; set; } = 0;
13 | ///
14 | /// True if In-Game, otherwise False.
15 | ///
16 | [Key(1)]
17 | public bool InGame { get; set; } = false;
18 | ///
19 | /// Contains the Map ID of the current map.
20 | ///
21 | [Key(2)]
22 | public string MapID { get; set; } = null;
23 | ///
24 | /// All Players currently on the map.
25 | ///
26 | [Key(3)]
27 | public IEnumerable Players { get; set; } = null;
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/SKWidgetControl/WidgetClickEvent.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_radar.UI.SKWidgetControl
2 | {
3 | public enum WidgetClickEvent
4 | {
5 | ///
6 | /// No click event ocurred in this widget.
7 | ///
8 | None,
9 | ///
10 | /// An area of the Widget (including Non-Client area) was clicked.
11 | ///
12 | Clicked,
13 | ///
14 | /// The Title bar was clicked.
15 | ///
16 | ClickedTitleBar,
17 | ///
18 | /// The Client Area of the widget was clicked.
19 | ///
20 | ClickedClientArea,
21 | ///
22 | /// The Minimize Button was clicked.
23 | ///
24 | ClickedMinimize,
25 | ///
26 | /// The Resize Triangle was clicked.
27 | ///
28 | ClickedResize
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/SKWidgetControl/WidgetClickEvent.cs:
--------------------------------------------------------------------------------
1 | namespace arena_dma_radar.UI.SKWidgetControl
2 | {
3 | public enum WidgetClickEvent
4 | {
5 | ///
6 | /// No click event ocurred in this widget.
7 | ///
8 | None,
9 | ///
10 | /// An area of the Widget (including Non-Client area) was clicked.
11 | ///
12 | Clicked,
13 | ///
14 | /// The Title bar was clicked.
15 | ///
16 | ClickedTitleBar,
17 | ///
18 | /// The Client Area of the widget was clicked.
19 | ///
20 | ClickedClientArea,
21 | ///
22 | /// The Minimize Button was clicked.
23 | ///
24 | ClickedMinimize,
25 | ///
26 | /// The Resize Triangle was clicked.
27 | ///
28 | ClickedResize
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Interactive/Trunk.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_radar.Tarkov.GameWorld;
3 | using eft_dma_radar.UI.ESP;
4 | using eft_dma_radar.UI.Misc;
5 | using eft_dma_radar.UI.Radar;
6 | using eft_dma_shared.Common.Misc;
7 | using eft_dma_shared.Common.Misc.Data;
8 | using eft_dma_shared.Common.Players;
9 | using eft_dma_shared.Common.Unity;
10 | using System;
11 | using System.Collections.Generic;
12 | using System.Linq;
13 | using System.Text;
14 | using System.Threading.Tasks;
15 | using static eft_dma_shared.Common.Misc.Data.EftDataManager;
16 |
17 | namespace LonesEFTRadar.Tarkov.GameWorld.Interactive
18 | {
19 | public sealed class Trunk : IESPEntity, IWorldEntity
20 | {
21 | public ref Vector3 Position => throw new NotImplementedException();
22 | public void DrawESP(SKCanvas canvas, LocalPlayer localPlayer)
23 | {
24 | throw new NotImplementedException();
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Interactive/LootableContainer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_radar.Tarkov.GameWorld;
3 | using eft_dma_radar.UI.ESP;
4 | using eft_dma_radar.UI.Misc;
5 | using eft_dma_radar.UI.Radar;
6 | using eft_dma_shared.Common.Misc;
7 | using eft_dma_shared.Common.Misc.Data;
8 | using eft_dma_shared.Common.Players;
9 | using eft_dma_shared.Common.Unity;
10 | using System;
11 | using System.Collections.Generic;
12 | using System.Linq;
13 | using System.Text;
14 | using System.Threading.Tasks;
15 | using static eft_dma_shared.Common.Misc.Data.EftDataManager;
16 |
17 | namespace LonesEFTRadar.Tarkov.GameWorld.Interactive
18 | {
19 | public sealed class LootableContainer : IESPEntity, IWorldEntity
20 | {
21 | public ref Vector3 Position => throw new NotImplementedException();
22 |
23 | public void DrawESP(SKCanvas canvas, LocalPlayer localPlayer)
24 | {
25 | throw new NotImplementedException();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/Maps/Streets.json:
--------------------------------------------------------------------------------
1 | {
2 | "mapID": [ "tarkovstreets" ],
3 | "x": 283,
4 | "y": 534,
5 | "scale": 1.0008,
6 | "svgScale": 4.00,
7 | "mapLayers": [
8 | {
9 | "minHeight": null,
10 | "maxHeight": null,
11 | "filename": "Streets.svg"
12 | },
13 | {
14 | "minHeight": null,
15 | "maxHeight": -0.7,
16 | "dimBaseLayer": false,
17 | "filename": "Streets_-1f.svg"
18 | },
19 | {
20 | "minHeight": -0.7,
21 | "maxHeight": null,
22 | "dimBaseLayer": false,
23 | "filename": "Streets_1f.svg"
24 | },
25 | {
26 | "minHeight": 4.5,
27 | "maxHeight": 7,
28 | "filename": "Streets_2f.svg"
29 | },
30 | {
31 | "minHeight": 7,
32 | "maxHeight": 9.7,
33 | "filename": "Streets_3f.svg"
34 | },
35 | {
36 | "minHeight": 9.7,
37 | "maxHeight": 12.7,
38 | "filename": "Streets_4f.svg"
39 | },
40 | {
41 | "minHeight": 12.7,
42 | "maxHeight": null,
43 | "filename": "Streets_5f.svg"
44 | }
45 | ]
46 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/DMA/MemPointer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc;
2 | using System.Runtime.CompilerServices;
3 |
4 | namespace eft_dma_shared.Common.DMA
5 | {
6 | ///
7 | /// Represents a 64-Bit Unsigned Pointer Address.
8 | ///
9 | public readonly struct MemPointer
10 | {
11 | public static implicit operator MemPointer(ulong x) => x;
12 | public static implicit operator ulong(MemPointer x) => x._pointer;
13 | ///
14 | /// Virtual Address of this Pointer.
15 | ///
16 | #pragma warning disable CS0649
17 | private readonly ulong _pointer;
18 | #pragma warning restore CS0649
19 |
20 | ///
21 | /// Validates the Pointer.
22 | ///
23 | [MethodImpl(MethodImplOptions.AggressiveInlining)]
24 | public readonly void Validate() =>
25 | _pointer.ThrowIfInvalidVirtualAddress();
26 |
27 | public override string ToString() => _pointer.ToString("X");
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/Misc/InputBox.cs:
--------------------------------------------------------------------------------
1 | using DarkModeForms;
2 |
3 | namespace eft_dma_radar.UI.Misc
4 | {
5 | public partial class InputBox : Form
6 | {
7 | private readonly DarkModeCS _darkmode;
8 | ///
9 | /// The text that was entered into the Input Box.
10 | ///
11 | [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
12 | public string Result { get; private set; }
13 |
14 | public InputBox(string title, string prompt)
15 | {
16 | InitializeComponent();
17 | _darkmode = new DarkModeCS(this);
18 | this.Text = title;
19 | label_Prompt.Text = prompt;
20 | this.AcceptButton = button_OK;
21 | this.CenterToScreen();
22 | textBox_Input.Select();
23 | }
24 |
25 | private void button_OK_Click(object sender, EventArgs e)
26 | {
27 | Result = textBox_Input.Text;
28 | this.DialogResult = DialogResult.OK;
29 | }
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/MessagePack/Vector2Formatter.cs:
--------------------------------------------------------------------------------
1 | using MessagePack;
2 | using MessagePack.Formatters;
3 |
4 | namespace eft_dma_shared.Common.Misc.MessagePack
5 | {
6 | public class Vector2Formatter : IMessagePackFormatter
7 | {
8 | public System.Numerics.Vector2 Deserialize(ref MessagePackReader reader, MessagePackSerializerOptions options)
9 | {
10 | options.Security.DepthStep(ref reader);
11 |
12 | ArgumentOutOfRangeException.ThrowIfNotEqual(reader.ReadArrayHeader(), 2, nameof(reader));
13 | System.Numerics.Vector2 result;
14 | result.X = reader.ReadSingle();
15 | result.Y = reader.ReadSingle();
16 |
17 | reader.Depth--;
18 | return result;
19 | }
20 |
21 | public void Serialize(ref MessagePackWriter writer, System.Numerics.Vector2 value, MessagePackSerializerOptions options)
22 | {
23 | writer.WriteArrayHeader(2);
24 | writer.Write(value.X);
25 | writer.Write(value.Y);
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/Types/MonoString.cs:
--------------------------------------------------------------------------------
1 | using System.Buffers.Binary;
2 | using System.Text;
3 |
4 | namespace eft_dma_shared.Common.Unity.LowLevel.Types
5 | {
6 | public sealed class MonoString : IMonoType
7 | {
8 | private const int _p1 = 0x10;
9 | private readonly byte[] _data;
10 |
11 | ///
12 | /// Raw Data for this object. Includes inserted padding and length.
13 | ///
14 | public Span Data => _data;
15 |
16 | ///
17 | /// Create a MonoString from a string.
18 | ///
19 | ///
20 | public MonoString(string data)
21 | {
22 | var dataBytes = Encoding.Unicode.GetBytes(data);
23 | _data = new byte[_p1 + 4 + dataBytes.Length];
24 | BinaryPrimitives.WriteInt32LittleEndian(_data.AsSpan(_p1), data.Length);
25 | dataBytes.CopyTo(_data, _p1 + 4);
26 | }
27 |
28 | public RemoteBytes ToRemoteBytes()
29 | {
30 | return new RemoteBytes(this);
31 | }
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/MessagePack/Vector3Formatter.cs:
--------------------------------------------------------------------------------
1 | using MessagePack;
2 | using MessagePack.Formatters;
3 |
4 | namespace eft_dma_shared.Common.Misc.MessagePack
5 | {
6 | public class Vector3Formatter : IMessagePackFormatter
7 | {
8 | public System.Numerics.Vector3 Deserialize(ref MessagePackReader reader, MessagePackSerializerOptions options)
9 | {
10 | options.Security.DepthStep(ref reader);
11 |
12 | ArgumentOutOfRangeException.ThrowIfNotEqual(reader.ReadArrayHeader(), 3, nameof(reader));
13 | System.Numerics.Vector3 result;
14 | result.X = reader.ReadSingle();
15 | result.Y = reader.ReadSingle();
16 | result.Z = reader.ReadSingle();
17 |
18 | reader.Depth--;
19 | return result;
20 | }
21 |
22 | public void Serialize(ref MessagePackWriter writer, System.Numerics.Vector3 value, MessagePackSerializerOptions options)
23 | {
24 | writer.WriteArrayHeader(3);
25 | writer.Write(value.X);
26 | writer.Write(value.Y);
27 | writer.Write(value.Z);
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/ESP/ViewMatrix.cs:
--------------------------------------------------------------------------------
1 | using System.Numerics;
2 | using System.Runtime.InteropServices;
3 |
4 | namespace eft_dma_shared.Common.ESP
5 | {
6 | ///
7 | /// Defines a transposed Matrix4x4 for ESP Operations (only contains necessary fields).
8 | ///
9 | public sealed class ViewMatrix
10 | {
11 | public float M44;
12 | public float M14;
13 | public float M24;
14 |
15 | public Vector3 Translation;
16 | public Vector3 Right;
17 | public Vector3 Up;
18 |
19 | public ViewMatrix() { }
20 |
21 | public void Update(ref Matrix4x4 matrix)
22 | {
23 | /// Transpose necessary fields
24 | M44 = matrix.M44;
25 | M14 = matrix.M41;
26 | M24 = matrix.M42;
27 | Translation.X = matrix.M14;
28 | Translation.Y = matrix.M24;
29 | Translation.Z = matrix.M34;
30 | Right.X = matrix.M11;
31 | Right.Y = matrix.M21;
32 | Right.Z = matrix.M31;
33 | Up.X = matrix.M12;
34 | Up.Y = matrix.M22;
35 | Up.Z = matrix.M32;
36 | }
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Players/ILocalPlayer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using System.Net.Http.Json;
3 | using System.Reflection;
4 |
5 | namespace eft_dma_shared.Common.Players
6 | {
7 | ///
8 | /// Interface defining a player that is the LocalPlayer running this software.
9 | ///
10 | public interface ILocalPlayer : IPlayer
11 | {
12 | private static ulong _accountId;
13 | ///
14 | /// LocalPlayer's Account Id.
15 | /// New entries will be posted to the Server/API.
16 | ///
17 | public static ulong AccountId
18 | {
19 | set
20 | {
21 | if (value != 0 && value < 0x3B9ACA00ul && value != _accountId)
22 | {
23 | _accountId = value;
24 | }
25 | }
26 | }
27 | ///
28 | /// Current Player State.
29 | ///
30 | public static ulong PlayerState = 0;
31 | ///
32 | /// Current HandsController Instance.
33 | ///
34 | public static ulong HandsController = 0;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Config/ChamsConfig.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Unity.LowLevel;
2 | using SkiaSharp;
3 | using System.Text.Json.Serialization;
4 |
5 | namespace eft_dma_shared.Common.Misc.Config
6 | {
7 | public sealed class ChamsConfig
8 | {
9 | ///
10 | /// True if this feature is enabled.
11 | ///
12 | [JsonPropertyName("enabled")]
13 | public bool Enabled { get; set; } = false;
14 |
15 | ///
16 | /// Last Chams Mode that the player set.
17 | ///
18 | [JsonPropertyName("mode")]
19 | public ChamsManager.ChamsMode Mode { get; set; } = ChamsManager.ChamsMode.Basic;
20 |
21 | ///
22 | /// Visible color for vischeck chams.
23 | ///
24 | [JsonPropertyName("visColor")]
25 | public string VisibleColor { get; set; } = SKColor.Parse("FF32D42D").ToString();
26 |
27 | ///
28 | /// Invisible color for vischeck chams.
29 | ///
30 | [JsonPropertyName("invisColor")]
31 | public string InvisibleColor { get; set; } = SKColor.Parse("FFCD251E").ToString();
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/MessagePack/ResolverGenerator.cs:
--------------------------------------------------------------------------------
1 | using MessagePack.Formatters;
2 | using MessagePack;
3 | using MessagePack.Resolvers;
4 |
5 | namespace eft_dma_shared.Common.Misc.MessagePack
6 | {
7 | public static class ResolverGenerator
8 | {
9 | public static readonly IFormatterResolver Instance;
10 |
11 | static ResolverGenerator()
12 | {
13 | Instance = CompositeResolver.Create(StandardResolver.Instance, CustomResolver.Instance);
14 | }
15 |
16 | private sealed class CustomResolver : IFormatterResolver
17 | {
18 | public static readonly CustomResolver Instance = new();
19 |
20 | private readonly Vector2Formatter _vector2Formatter = new();
21 | private readonly Vector3Formatter _vector3Formatter = new();
22 |
23 | public IMessagePackFormatter GetFormatter()
24 | {
25 | if (_vector2Formatter is IMessagePackFormatter f1)
26 | return f1;
27 | if (_vector3Formatter is IMessagePackFormatter f2)
28 | return f2;
29 |
30 | return null; // No match found
31 | }
32 | }
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Maps/ILoneMap.cs:
--------------------------------------------------------------------------------
1 | using SkiaSharp;
2 | using SkiaSharp.Views.Desktop;
3 | using System.Numerics;
4 |
5 | namespace eft_dma_shared.Common.Maps
6 | {
7 | public interface ILoneMap : IDisposable
8 | {
9 | ///
10 | /// Raw Map ID for this Map.
11 | ///
12 | string ID { get; }
13 |
14 | ///
15 | /// Configuration for this Map.
16 | ///
17 | LoneMapConfig Config { get; }
18 |
19 | ///
20 | /// Draw the Map on the provided Canvas.
21 | ///
22 | ///
23 | ///
24 | ///
25 | ///
26 | void Draw(SKCanvas canvas, float playerHeight, SKRect mapBounds, SKRect windowBounds);
27 |
28 | ///
29 | /// Get Parameters for this map.
30 | ///
31 | ///
32 | ///
33 | ///
34 | ///
35 | LoneMapParams GetParameters(SKGLControl control, int zoom, ref Vector2 localPlayerMapPos);
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Commercial/LoneLogging.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Diagnostics;
3 | using System.IO;
4 | using System.Runtime.CompilerServices;
5 |
6 | namespace eft_dma_shared.Common.Misc.Commercial
7 | {
8 | public static class LoneLogging
9 | {
10 | private static readonly Action _writeLine;
11 |
12 | static LoneLogging()
13 | {
14 | /*string logFilePath = "dma.log";
15 | _writeLine = message =>
16 | {
17 | try
18 | {
19 | File.AppendAllText(logFilePath, $"{DateTime.Now:yyyy-MM-dd HH:mm:ss.fff} - {message}{Environment.NewLine}");
20 | }
21 | catch (Exception ex)
22 | {
23 | Debug.WriteLine($"Logging failed: {ex}");
24 | }
25 | };*/
26 | }
27 |
28 | ///
29 | /// Write a message to the log with a newline.
30 | ///
31 | /// Data to log. Calls .ToString() on the object.
32 | [MethodImpl(MethodImplOptions.AggressiveInlining)]
33 | public static void WriteLine(object data)
34 | {
35 | Debug.WriteLine(data);
36 | _writeLine?.Invoke(data.ToString());
37 | }
38 | }
39 | }
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/Nightvision.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_radar.Tarkov.GameWorld;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Features;
5 | using System;
6 | using System.Collections.Generic;
7 | using System.Linq;
8 | using System.Text;
9 | using System.Threading.Tasks;
10 |
11 | namespace LonesEFTRadar.Tarkov.Features.MemoryWrites
12 | {
13 | public sealed class NightVision : MemWriteFeature
14 | {
15 | public override bool Enabled
16 | {
17 | get => MemWrites.Config.Nightvision;
18 | set => MemWrites.Config.Nightvision = value;
19 | }
20 |
21 | protected override TimeSpan Delay => TimeSpan.FromSeconds(1000);
22 |
23 | public override void TryApply(ScatterWriteHandle writes)
24 | {
25 | try
26 | {
27 | if (!Memory.InRaid)
28 | return;
29 | ulong nightVision = CameraManager.GetNightVision(false);
30 | if (nightVision != 0)
31 | {
32 | writes.AddValueEntry(nightVision + Offsets.NightVision._on, Enabled);
33 | }
34 | }
35 | catch (Exception ex)
36 | {
37 |
38 | }
39 | }
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/ThermalVision.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_radar.Tarkov.GameWorld;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Features;
5 | using System;
6 | using System.Collections.Generic;
7 | using System.Linq;
8 | using System.Text;
9 | using System.Threading.Tasks;
10 |
11 | namespace LonesEFTRadar.Tarkov.Features.MemoryWrites
12 | {
13 | public sealed class ThermalVision : MemWriteFeature
14 | {
15 | public override bool Enabled {
16 | get => MemWrites.Config.ThermalVision;
17 | set => MemWrites.Config.ThermalVision = value;
18 | }
19 |
20 | protected override TimeSpan Delay => TimeSpan.FromSeconds(1000);
21 |
22 | public override void TryApply(ScatterWriteHandle writes)
23 | {
24 | try
25 | {
26 | if (!Memory.InRaid)
27 | return;
28 | ulong thermalVision = CameraManager.GetThermalVision(false);
29 | if (thermalVision != 0)
30 | {
31 | writes.AddValueEntry(thermalVision + Offsets.ThermalVision.On, Enabled);
32 | }
33 | }
34 | catch (Exception ex)
35 | {
36 |
37 | }
38 | }
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/EFTPlayer/BtrOperator.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA.ScatterAPI;
2 |
3 | namespace eft_dma_radar.Tarkov.EFTPlayer
4 | {
5 | ///
6 | /// BTR Bot Operator.
7 | ///
8 | public sealed class BtrOperator : ObservedPlayer
9 | {
10 | private readonly ulong _btrView;
11 | private Vector3 _position;
12 |
13 | public override ref Vector3 Position
14 | {
15 | get => ref _position;
16 | }
17 | public override string Name
18 | {
19 | get => "BTR";
20 | set { }
21 | }
22 | public BtrOperator(ulong btrView, ulong playerBase) : base(playerBase)
23 | {
24 | _btrView = btrView;
25 | Type = PlayerType.AIRaider;
26 | }
27 |
28 | ///
29 | /// Set the position of the BTR.
30 | /// Give this function it's own unique Index.
31 | ///
32 | /// Scatter read index to read off of.
33 | public override void OnRealtimeLoop(ScatterReadIndex index)
34 | {
35 | index.AddEntry(0, _btrView + Offsets.BTRView._targetPosition);
36 | index.Callbacks += x1 =>
37 | {
38 | if (x1.TryGetResult(0, out var position))
39 | _position = position;
40 | };
41 | }
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/SharedPaints.cs:
--------------------------------------------------------------------------------
1 | using SkiaSharp;
2 |
3 | namespace eft_dma_shared.Common.Misc
4 | {
5 | public static class SharedPaints
6 | {
7 | public static SKPaint PaintBitmap { get; } = new()
8 | {
9 | IsAntialias = true,
10 | FilterQuality = SKFilterQuality.High
11 | };
12 |
13 | public static SKPaint PaintBitmapAlpha { get; } = new()
14 | {
15 | Color = SKColor.Empty.WithAlpha(127),
16 | IsAntialias = true,
17 | FilterQuality = SKFilterQuality.High
18 | };
19 |
20 | ///
21 | /// Gets an SKColorFilter that will reduce an image's brightness level.
22 | ///
23 | /// Adjust this value between 0 (black) and 1 (original brightness), where values less than 1 reduce brightness
24 | /// SKColorFilter Object.
25 | public static SKColorFilter GetDarkModeColorFilter(float brightnessFactor)
26 | {
27 | float[] colorMatrix = {
28 | brightnessFactor, 0, 0, 0, 0, // Red channel
29 | 0, brightnessFactor, 0, 0, 0, // Green channel
30 | 0, 0, brightnessFactor, 0, 0, // Blue channel
31 | 0, 0, 0, 1, 0, // Alpha channel
32 | };
33 | return SKColorFilter.CreateColorMatrix(colorMatrix);
34 | }
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/AntiAfk.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Features;
2 | using eft_dma_shared.Common.Unity;
3 |
4 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
5 | {
6 | public sealed class AntiAfk : MemWriteFeature
7 | {
8 | ///
9 | /// Set Anti-Afk.
10 | ///
11 | ///
12 | public void Set()
13 | {
14 | try
15 | {
16 | var gom = GameObjectManager.Get(Memory.UnityBase);
17 | var applicationGO = gom.GetObjectFromList("Application (Main Client)");
18 | ArgumentOutOfRangeException.ThrowIfZero(applicationGO, nameof(applicationGO));
19 | var tarkovApplication = GameObject.GetComponent(applicationGO, "TarkovApplication");
20 | ArgumentOutOfRangeException.ThrowIfZero(tarkovApplication, nameof(tarkovApplication));
21 |
22 | var afkMonitor = Memory.ReadPtrChain(tarkovApplication,
23 | new uint[] { Offsets.TarkovApplication.MenuOperation, Offsets.MenuOperation.AfkMonitor });
24 | const float amt = 604800f; // 1 week
25 | Memory.WriteValue(afkMonitor + Offsets.AfkMonitor.Delay, amt);
26 | }
27 | catch (Exception ex)
28 | {
29 | throw new Exception($"ERROR Setting Anti-AFK", ex);
30 | }
31 | }
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Ballistics/BallisticsInfo.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 |
3 | namespace eft_dma_shared.Common.Ballistics
4 | {
5 | public sealed class BallisticsInfo
6 | {
7 | ///
8 | /// Muzzle Velocity of the weapon + all attachments.
9 | /// Required for ballistics formula.
10 | ///
11 | public float BulletSpeed { get; set; }
12 | ///
13 | /// Required for ballistics formula.
14 | ///
15 | public float BulletMassGrams { get; set; }
16 | ///
17 | /// Required for ballistics formula.
18 | ///
19 | public float BulletDiameterMillimeters { get; set; }
20 | ///
21 | /// Required for ballistics formula.
22 | ///
23 | public float BallisticCoefficient { get; set; }
24 |
25 | ///
26 | /// Returns true if Ammo/Ballistics values are valid.
27 | ///
28 | public bool IsAmmoValid
29 | {
30 | get
31 | {
32 | return BulletMassGrams > 0f && BulletMassGrams < 2000f &&
33 | BulletSpeed > 1f && BulletSpeed < 2500f &&
34 | BallisticCoefficient >= 0f && BallisticCoefficient <= 3f &&
35 | BulletDiameterMillimeters > 0f && BulletDiameterMillimeters <= 100f;
36 | }
37 | }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/arena-dma-radar/UI/LootFilters/LootFilter.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.Loot;
2 | using arena_dma_radar.Tarkov.Loot;
3 | using arena_dma_radar.UI.Radar;
4 |
5 | namespace arena_dma_radar.UI.LootFilters
6 | {
7 | ///
8 | /// Enumerable Loot Filter Class.
9 | ///
10 | internal static class LootFilter
11 | {
12 | public static string SearchString;
13 | public static bool ShowMeds;
14 | public static bool ShowFood;
15 | public static bool ShowBackpacks;
16 | public static bool ShowWishlist;
17 |
18 | // private static bool ShowQuestItems => MainForm.Config.QuestHelper.Enabled;
19 |
20 | ///
21 | /// Creates a loot filter based on current Loot Filter settings.
22 | ///
23 | /// Loot Filter Predicate.
24 | public static Predicate Create()
25 | {
26 | Predicate p = (x) => // Default Predicate
27 | {
28 | return (LootFilter.ShowBackpacks && x.IsBackpack);
29 | };
30 | return (item) =>
31 | {
32 | if (p(item))
33 | {
34 | if (item is LootContainer container)
35 | {
36 | container.SetFilter(p);
37 | }
38 | return true;
39 | }
40 | return false;
41 | };
42 | }
43 | }
44 | }
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Features/MemoryWrites/Patches/NoWepMalfPatch.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.Features;
2 | using eft_dma_shared.Common.Features;
3 | using eft_dma_shared.Common.Unity;
4 |
5 | namespace arena_dma_radar.Arena.Features.MemoryWrites.Patches
6 | {
7 | public sealed class NoWepMalfPatch : MemPatchFeature
8 | {
9 | public override bool Enabled
10 | {
11 | get => MemWrites.Config.NoWeaponMalfunctions;
12 | set => MemWrites.Config.NoWeaponMalfunctions = value;
13 | }
14 | protected override byte[] Signature { get; } = new byte[]
15 | {
16 | 0x55, // push rbp
17 | 0x48, 0x8B, 0xEC, // mov rbp, rsp
18 | 0x48, 0x81, 0xEC, 0xC0, 0x00, 0x00, 0x00 // sub rsp, 0xC0
19 | };
20 | protected override byte[] Patch { get; } = new byte[]
21 | {
22 | 0xB8, 0x00, 0x00, 0x00, 0x00, // mov eax, 0
23 | 0xC3 // ret
24 | };
25 | protected override Func GetPFunc => Lookup_GetMalfunctionState;
26 | protected override int PFuncSize => 64;
27 |
28 | public override void OnGameStop()
29 | {
30 | IsApplied = default;
31 | }
32 |
33 | private static ulong Lookup_GetMalfunctionState()
34 | {
35 | var pFuncGetMalfState = MonoLib.MonoClass.Find("Assembly-CSharp", "FirearmController", out _).FindJittedMethod("GetMalfunctionState");
36 | return pFuncGetMalfState;
37 | }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Native.cs:
--------------------------------------------------------------------------------
1 | using System.Runtime.InteropServices;
2 |
3 | namespace eft_dma_shared.Misc
4 | {
5 | ///
6 | /// Windows Native Code / Interop
7 | ///
8 | public static partial class Native
9 | {
10 | // SetProcessWorkingSetSizeEx
11 | public const uint QUOTA_LIMITS_HARDWS_MIN_DISABLE = 0x00000002;
12 | public const uint QUOTA_LIMITS_HARDWS_MIN_ENABLE = 0x00000001;
13 | public const uint QUOTA_LIMITS_HARDWS_MAX_DISABLE = 0x00000008;
14 | public const uint QUOTA_LIMITS_HARDWS_MAX_ENABLE = 0x00000004;
15 |
16 | [LibraryImport("kernel32.dll")]
17 | public static partial EXECUTION_STATE SetThreadExecutionState(EXECUTION_STATE esFlags);
18 |
19 | [LibraryImport("powrprof.dll")]
20 | public static partial uint PowerSetActiveScheme(IntPtr userRootPowerKey, ref Guid schemeGuid);
21 |
22 | [LibraryImport("kernel32.dll")]
23 | [return: MarshalAs(UnmanagedType.Bool)]
24 | public static partial bool SetProcessWorkingSetSizeEx(
25 | IntPtr hProcess,
26 | ulong dwMinimumWorkingSetSize,
27 | ulong dwMaximumWorkingSetSize,
28 | uint flags);
29 |
30 | [Flags]
31 | public enum EXECUTION_STATE : uint
32 | {
33 | ES_AWAYMODE_REQUIRED = 0x00000040,
34 | ES_CONTINUOUS = 0x80000000,
35 | ES_DISPLAY_REQUIRED = 0x00000002,
36 | ES_SYSTEM_REQUIRED = 0x00000001
37 | // Legacy flag, should not be used.
38 | // ES_USER_PRESENT = 0x00000004
39 | }
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/LowLevelCache.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Concurrent;
2 | using System.Text.Json.Serialization;
3 |
4 | namespace eft_dma_shared.Common.Unity.LowLevel
5 | {
6 | ///
7 | /// Contains Cache Data for Unity Low Level API.
8 | ///
9 | public sealed class LowLevelCache
10 | {
11 | [JsonPropertyName("ZK8MQLY")]
12 | public uint PID { get; set; }
13 | [JsonPropertyName("X8kP9Ln")]
14 | public ulong CodeCave { get; set; }
15 | [JsonPropertyName("tZ6Yv7m")]
16 | public ulong UnityPlayerDll { get; set; }
17 | [JsonPropertyName("K9XrF2q")]
18 | public ulong MonoDll { get; set; }
19 | [JsonPropertyName("XJ9TQWZ")]
20 | public ulong HookedMonoFuncAddress { get; set; }
21 | [JsonPropertyName("PL6VDRM")]
22 | public ulong HookedMonoFunc { get; set; }
23 | [JsonPropertyName("L3Wp7Tz")]
24 | public ConcurrentDictionary ChamsMaterialIds { get; set; } = new();
25 |
26 | ///
27 | /// Persist the cache to disk.
28 | ///
29 | public async Task SaveAsync() => await SharedProgram.Config.SaveAsync();
30 |
31 | ///
32 | /// Reset the cache to defaults.
33 | ///
34 | public void Reset()
35 | {
36 | CodeCave = default;
37 | UnityPlayerDll = default;
38 | MonoDll = default;
39 | HookedMonoFuncAddress = default;
40 | HookedMonoFunc = default;
41 | ChamsMaterialIds.Clear();
42 | }
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/GameWorld/Interactive/ArenaPresetRefillContainer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using eft_dma_shared.Common.Unity;
3 | using System;
4 | using System.Collections.Generic;
5 | using System.Linq;
6 | using System.Text;
7 | using System.Threading.Tasks;
8 |
9 | namespace LonesArenaRadar.Arena.GameWorld.Interactive
10 | {
11 | public sealed class ArenaPresetRefillContainer
12 | {
13 | private static readonly uint[] _transformInternalChain =
14 | [
15 | ObjectClass.MonoBehaviourOffset,
16 | MonoBehaviour.GameObjectOffset,
17 | GameObject.ComponentsOffset,
18 | 0x8
19 | ];
20 | public ulong Base { get; set; }
21 | public string Id { get; set; }
22 | public string? KeyId { get; set; }
23 | public Vector3 Position { get; set; }
24 |
25 | public ArenaPresetRefillContainer(ulong ptr)
26 | {
27 | try
28 | {
29 | //Setting the values that aren't going to change. That way we can just check the state on refresh
30 | Base = ptr;
31 | var keyidPtr = Memory.ReadPtr(Base + Offsets.WorldInteractiveObject.KeyId, false);
32 | var doorIdPtr = Memory.ReadPtr(Base + Offsets.WorldInteractiveObject.Id, false);
33 | var transformInternal = Memory.ReadPtrChain(Base, _transformInternalChain, false);
34 | var transform = new UnityTransform(transformInternal);
35 |
36 | Position = transform.UpdatePosition();
37 | }
38 | catch { }
39 | }
40 |
41 | public void Refresh()
42 | {
43 |
44 | }
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/Patches/NoWepMalfPatch.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_shared.Common.Features;
3 | using eft_dma_shared.Common.Unity;
4 |
5 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites.Patches
6 | {
7 | public sealed class NoWepMalfPatch : MemPatchFeature
8 | {
9 | public override bool Enabled
10 | {
11 | get => MemWrites.Config.NoWeaponMalfunctions;
12 | set => MemWrites.Config.NoWeaponMalfunctions = value;
13 | }
14 | public override bool CanRun => base.CanRun && (Memory.Game?.RaidHasStarted ?? false);
15 | protected override byte[] Signature { get; } = new byte[]
16 | {
17 | 0x55, // push rbp
18 | 0x48, 0x8B, 0xEC, // mov rbp, rsp
19 | 0x48, 0x81, 0xEC, 0xC0, 0x00, 0x00, 0x00 // sub rsp, 0xC0
20 | };
21 | protected override byte[] Patch { get; } = new byte[]
22 | {
23 | 0xB8, 0x00, 0x00, 0x00, 0x00, // mov eax, 0
24 | 0xC3 // ret
25 | };
26 | protected override Func GetPFunc => Lookup_GetMalfunctionState;
27 | protected override int PFuncSize => 64;
28 |
29 | public override void OnGameStop()
30 | {
31 | IsApplied = false;
32 | }
33 |
34 | private static ulong Lookup_GetMalfunctionState()
35 | {
36 | var pFuncGetMalfState = MonoLib.MonoClass.Find("Assembly-CSharp", ClassNames.NoMalfunctions.ClassName, out _).FindJittedMethod(ClassNames.NoMalfunctions.GetMalfunctionState);
37 | return pFuncGetMalfState;
38 | }
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/Hooks/NativeOffsets.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Unity.LowLevel.Hooks
2 | {
3 | internal static class NativeOffsets
4 | {
5 | // mono-2.0-bdwgc.dll
6 | public const ulong mono_mprotect = 0x72B60;
7 | public const ulong mono_class_setup_methods = 0xCFC60;
8 | public const ulong mono_marshal_free = 0x16ABE0;
9 | public const ulong mono_compile_method = 0x1C8610;
10 | public const ulong mono_object_new = 0x1D5190;
11 | public const ulong mono_type_get_object = 0x234C90;
12 | public const ulong mono_gchandle_new = 0x1C4AA0;
13 | public const ulong mono_method_signature = 0x158470;
14 | public const ulong mono_signature_get_param_count = 0x195E60;
15 | public const ulong mono_marshal_alloc_hglobal = 0x274700;
16 |
17 | // UnityPlayer.dll
18 | public const ulong AssetBundle_CUSTOM_LoadAsset_Internal = 0x1CD440;
19 | public const ulong AssetBundle_CUSTOM_LoadFromMemory_Internal = 0x1CC810;
20 | public const ulong AssetBundle_CUSTOM_Unload = 0x1CE410;
21 | public const ulong Behaviour_SetEnabled = 0x4499E0; // Behaviour::SetEnabled
22 | public const ulong GameObject_CUSTOM_Find = 0x1006C0;
23 | public const ulong GameObject_CUSTOM_SetActive = 0xFD8E0;
24 | public const ulong Material_CUSTOM_CreateWithShader = 0xAFCA0;
25 | public const ulong Material_CUSTOM_SetColorImpl_Injected = 0xB7CC0;
26 | public const ulong Object_CUSTOM_DontDestroyOnLoad = 0x105EC0;
27 | public const ulong Object_Set_Custom_PropHideFlags = 0x106130;
28 | public const ulong Shader_CUSTOM_PropertyToID = 0xAB260;
29 | public const ulong mono_gc_is_incremental = 0x1CFA548; // Search name as string to get offset
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Features/MemoryWrites/NoVisor.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.GameWorld;
2 | using eft_dma_shared.Common.Features;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Unity;
5 | using arena_dma_radar.Arena.Features;
6 | using eft_dma_shared.Common.Misc.Commercial;
7 |
8 | namespace arena_dma_radar.Arena.Features.MemoryWrites
9 | {
10 | public sealed class NoVisor : MemWriteFeature
11 | {
12 | public override bool Enabled
13 | {
14 | get => MemWrites.Config.NoVisor;
15 | set => MemWrites.Config.NoVisor = value;
16 | }
17 |
18 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(100);
19 |
20 | public override void TryApply(ScatterWriteHandle writes)
21 | {
22 | try
23 | {
24 | if (Enabled && Memory.Game is LocalGameWorld game)
25 | {
26 | const float newVisor = 0f;
27 | var cm = game.CameraManager;
28 | var visorEffect = MonoBehaviour.GetComponent(cm.FPSCamera, "VisorEffect");
29 | if (visorEffect != 0x0)
30 | {
31 | var currentVisor = Memory.ReadValue(visorEffect + Offsets.VisorEffect.Intensity, false);
32 | if (currentVisor != newVisor)
33 | {
34 | writes.AddValueEntry(visorEffect + Offsets.VisorEffect.Intensity, newVisor);
35 | LoneLogging.WriteLine($"NoVisor -> {newVisor}");
36 | }
37 | }
38 | }
39 | }
40 | catch (Exception ex)
41 | {
42 | LoneLogging.WriteLine($"ERROR configuring NoVisor: {ex}");
43 | }
44 | }
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Features/MemWriteFeature.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA.ScatterAPI;
2 | using System.Diagnostics;
3 |
4 | namespace eft_dma_shared.Common.Features
5 | {
6 | public abstract class MemWriteFeature : IFeature, IMemWriteFeature
7 | where T : IMemWriteFeature
8 | {
9 | ///
10 | /// Singleton Instance.
11 | ///
12 | public static T Instance { get; }
13 |
14 | private readonly Stopwatch _sw = Stopwatch.StartNew();
15 |
16 | static MemWriteFeature()
17 | {
18 | Instance = Activator.CreateInstance();
19 | IFeature.Register(Instance);
20 | }
21 |
22 | public virtual bool Enabled { get; set; }
23 |
24 | protected virtual TimeSpan Delay => TimeSpan.FromMilliseconds(10);
25 |
26 | protected bool DelayElapsed => Delay == TimeSpan.Zero || _sw.Elapsed >= Delay;
27 |
28 | public virtual bool CanRun
29 | {
30 | get
31 | {
32 | if (!Memory.InRaid || !Memory.RaidHasStarted)
33 | return false;
34 | if (!DelayElapsed)
35 | return false;
36 | return true;
37 | }
38 | }
39 |
40 | public virtual void TryApply(ScatterWriteHandle writes)
41 | {
42 | }
43 |
44 | public void OnApply()
45 | {
46 | if (Delay != TimeSpan.Zero)
47 | {
48 | _sw.Restart();
49 | }
50 | }
51 |
52 | public virtual void OnGameStart()
53 | {
54 | }
55 |
56 | public virtual void OnRaidStart()
57 | {
58 | }
59 |
60 | public virtual void OnRaidEnd()
61 | {
62 | }
63 |
64 | public virtual void OnGameStop()
65 | {
66 | }
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/NoVisor.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_radar.Tarkov.GameWorld;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Features;
5 | using eft_dma_shared.Common.Misc;
6 | using eft_dma_shared.Common.Misc.Commercial;
7 | using eft_dma_shared.Common.Unity;
8 |
9 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
10 | {
11 | public sealed class NoVisor : MemWriteFeature
12 | {
13 | public override bool Enabled
14 | {
15 | get => MemWrites.Config.NoVisor;
16 | set => MemWrites.Config.NoVisor = value;
17 | }
18 |
19 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(500);
20 |
21 | public override void TryApply(ScatterWriteHandle writes)
22 | {
23 | try
24 | {
25 | if (Enabled && Memory.Game is LocalGameWorld game)
26 | {
27 | const float newVisor = 0f;
28 | ulong fps = game.CameraManager?.FPSCamera ?? 0x0;
29 | fps.ThrowIfInvalidVirtualAddress();
30 | var visorEffect = MonoBehaviour.GetComponent(fps, "VisorEffect");
31 | if (visorEffect != 0x0)
32 | {
33 | var currentVisor = Memory.ReadValue(visorEffect + Offsets.VisorEffect.Intensity);
34 | if (currentVisor != newVisor)
35 | {
36 | writes.AddValueEntry(visorEffect + Offsets.VisorEffect.Intensity, newVisor);
37 | LoneLogging.WriteLine($"NoVisor -> {newVisor}");
38 | }
39 | }
40 | }
41 | }
42 | catch (Exception ex)
43 | {
44 | LoneLogging.WriteLine($"ERROR configuring NoVisor: {ex}");
45 | }
46 | }
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Loot/LootContainer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 |
3 | namespace eft_dma_radar.Tarkov.Loot
4 | {
5 | public class LootContainer : LootItem
6 | {
7 | private static readonly TarkovMarketItem _defaultItem = new();
8 | private static readonly Predicate _pTrue = (x) => { return true; };
9 | private Predicate _filter = _pTrue;
10 |
11 | public override string Name
12 | {
13 | get
14 | {
15 | var items = this.FilteredLoot;
16 | if (items is not null && items.Count() == 1)
17 | return items.First().Name ?? "Loot";
18 | return "Loot";
19 | }
20 | }
21 | ///
22 | /// Constructor.
23 | ///
24 | /// Name of container (example: AIRDROP).
25 | public LootContainer(IReadOnlyList loot) : base(_defaultItem)
26 | {
27 | ArgumentNullException.ThrowIfNull(loot, nameof(loot));
28 | this.Loot = loot;
29 | }
30 |
31 | ///
32 | /// Update the filter for this container.
33 | ///
34 | /// New filter to be set.
35 | public void SetFilter(Predicate filter)
36 | {
37 | ArgumentNullException.ThrowIfNull(filter, nameof(filter));
38 | _filter = filter;
39 | }
40 |
41 | ///
42 | /// All items inside this Container (unfiltered/unordered).
43 | ///
44 | public IReadOnlyList Loot { get; }
45 |
46 | ///
47 | /// All Items inside this container that pass the current Loot Filter.
48 | /// Ordered by Important/Price Value.
49 | ///
50 | public IEnumerable FilteredLoot => Loot
51 | .Where(x => _filter(x))
52 | .OrderLoot();
53 | }
54 | }
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ColorPicker/Container/ContainerColorOption.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.Misc;
2 | using eft_dma_radar.UI.ESP;
3 | using eft_dma_radar.UI.Radar;
4 |
5 | namespace LonesEFTRadar.UI.ColorPicker.Container
6 | {
7 | [Obfuscation(Exclude = true, Feature = "renaming")]
8 | public enum ContainerColorOption
9 | {
10 | CacheAndBody,
11 | Body,
12 | Medical,
13 | Tech,
14 | Grenade,
15 | Jacket,
16 | Bag,
17 | PC,
18 | Ammo
19 | }
20 | internal static class ContainerColorOptions
21 | {
22 | internal static void LoadColors(Config config)
23 | {
24 | config.Containers.Colors ??= new Dictionary();
25 | foreach (var defaultColor in GetDefaultColors())
26 | config.Containers.Colors.TryAdd(defaultColor.Key, defaultColor.Value);
27 | SetColors(config.Containers.Colors);
28 | }
29 |
30 | internal static Dictionary GetDefaultColors() =>
31 | new()
32 | {
33 | [ContainerColorOption.CacheAndBody] = SKColor.Parse("FFFFCC").ToString(),
34 | [ContainerColorOption.Body] = SKColor.Parse("FFFFCC").ToString(),
35 | [ContainerColorOption.Medical] = SKColor.Parse("FFFFCC").ToString(),
36 | [ContainerColorOption.Tech] = SKColor.Parse("FFFFCC").ToString(),
37 | [ContainerColorOption.Grenade] = SKColor.Parse("FFFFCC").ToString(),
38 | [ContainerColorOption.Jacket] = SKColor.Parse("FFFFCC").ToString(),
39 | [ContainerColorOption.Bag] = SKColor.Parse("FFFFCC").ToString(),
40 | [ContainerColorOption.PC] = SKColor.Parse("FFFFCC").ToString(),
41 | [ContainerColorOption.Ammo] = SKColor.Parse("FFFFCC").ToString()
42 | };
43 | internal static void SetColors(IReadOnlyDictionary colors)
44 | {
45 |
46 | }
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Data/TarkovMarket/FleaTax.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Misc.Data.TarkovMarket
2 | {
3 | internal static class FleaTax
4 | {
5 | private const double CommunityItemTax = 3f;
6 | private const double CommunityRequirementTax = 3f;
7 | private const double RagFairCommissionModifier = 1f; // Constant in ItemTemplate
8 |
9 | ///
10 | /// Calculates the amount of tax to be paid on the flea market.
11 | ///
12 | /// Flea list price.
13 | /// Base price value of the item.
14 | ///
15 | public static double Calculate(double requirementsPrice, double num) /// public static double CalculateTaxPrice(Item item, int offerItemCount, double requirementsPrice, bool sellInOnePiece)
16 | {
17 | if (num == 0d || requirementsPrice == 0d) // Prevent DIV by Zero
18 | {
19 | return 0d;
20 | }
21 | // Convert tax modifiers to percentages
22 | double num2 = CommunityItemTax / 100d;
23 | double num3 = CommunityRequirementTax / 100d;
24 | double num4 = Math.Log10(num / requirementsPrice);
25 | double num5 = Math.Log10(requirementsPrice / num);
26 |
27 | // Determine the logarithm to weight based on relationship to the item's base price
28 | if (requirementsPrice >= num)
29 | {
30 | num5 = Math.Pow(num5, 1.08d);
31 | }
32 | else
33 | {
34 | num4 = Math.Pow(num4, 1.08d);
35 | }
36 | num4 = Math.Pow(4.0d, num4);
37 | num5 = Math.Pow(4.0d, num5);
38 |
39 | // Get the base tax amount
40 | double num6 = num * num2 * num4 + requirementsPrice * num3 * num5;
41 |
42 | // Apply the RagFairCommissionModifier
43 | return num6 * RagFairCommissionModifier;
44 | }
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Loot/LootContainer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 | using arena_dma_radar.Arena.Loot;
3 |
4 | namespace arena_dma_radar.Tarkov.Loot
5 | {
6 | public class LootContainer : LootItem
7 | {
8 | private static readonly TarkovMarketItem _defaultItem = new();
9 | private static readonly Predicate _pTrue = (x) => { return true; };
10 | private Predicate _filter = _pTrue;
11 |
12 | public override string Name
13 | {
14 | get
15 | {
16 | var items = this.FilteredLoot;
17 | if (items is not null && items.Count() == 1)
18 | return items.First().Name ?? "Loot";
19 | return "Loot";
20 | }
21 | }
22 | ///
23 | /// Constructor.
24 | ///
25 | /// Name of container (example: AIRDROP).
26 | public LootContainer(IReadOnlyList loot) : base(_defaultItem)
27 | {
28 | ArgumentNullException.ThrowIfNull(loot, nameof(loot));
29 | this.Loot = loot;
30 | }
31 |
32 | ///
33 | /// Update the filter for this container.
34 | ///
35 | /// New filter to be set.
36 | public void SetFilter(Predicate filter)
37 | {
38 | ArgumentNullException.ThrowIfNull(filter, nameof(filter));
39 | _filter = filter;
40 | }
41 |
42 | ///
43 | /// All items inside this Container (unfiltered/unordered).
44 | ///
45 | public IReadOnlyList Loot { get; }
46 |
47 | ///
48 | /// All Items inside this container that pass the current Loot Filter.
49 | /// Ordered by Important/Price Value.
50 | ///
51 | public IEnumerable FilteredLoot => Loot
52 | .Where(x => _filter(x))
53 | .OrderLoot();
54 | }
55 | }
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/WorldInteractableManager.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Unity;
2 | using eft_dma_shared.Common.Unity.Collections;
3 | using System;
4 | using System.Collections.Generic;
5 | using System.Linq;
6 | using System.Text;
7 | using System.Threading.Tasks;
8 | using LonesEFTRadar.Tarkov.GameWorld.Interactive;
9 | using eft_dma_radar.UI.Misc;
10 | using eft_dma_radar;
11 |
12 | namespace LonesEFTRadar.Tarkov.GameWorld
13 | {
14 | public sealed class WorldInteractiveManager
15 | {
16 | private readonly ulong _localGameWorld;
17 | private readonly HashSet _Doors;
18 | private readonly HashSet _Switches;
19 | private bool _kill = false;
20 |
21 | public IReadOnlyCollection Doors => _Doors;
22 | public IReadOnlyCollection Switches => _Switches;
23 |
24 | public WorldInteractiveManager(ulong localGameWorld)
25 | {
26 | _localGameWorld = localGameWorld;
27 | _Doors = new();
28 | Init();
29 | }
30 |
31 | public void Init()
32 | {
33 | if (!Program.Config.ESP.ShowDoorViewer)
34 | return;
35 | try
36 | {
37 | var interactableArrayPtr = Memory.ReadPtrChain(_localGameWorld, new uint[] { 0x258, 0x30 }, false);
38 | using var array = MemArray.Get(interactableArrayPtr, false);
39 | var set = array.Where(x => x != 0x0).ToHashSet();
40 | array.Dispose();
41 |
42 | foreach (var item in set)
43 | {
44 | var itemName = ObjectClass.ReadName(item);
45 | if (itemName.Contains("Door"))
46 | {
47 | _Doors.Add(new Door(item, itemName));
48 | }
49 | }
50 | }
51 | catch { }
52 | }
53 |
54 | public void Refresh()
55 | {
56 | if (_Doors.Count == 0)
57 | {
58 | Init();
59 | }
60 | foreach (var door in _Doors)
61 | {
62 | door.Refresh();
63 | }
64 | }
65 | }
66 | }
67 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/GameWorld/InteractiveManager.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using eft_dma_shared.Common.Unity.Collections;
3 | using eft_dma_shared.Common.Unity;
4 | using System;
5 | using System.Collections.Generic;
6 | using System.Linq;
7 | using System.Text;
8 | using System.Threading.Tasks;
9 | using LonesArenaRadar.Arena.GameWorld.Interactive;
10 |
11 | namespace LonesArenaRadar.Arena.GameWorld
12 | {
13 | public sealed class InteractiveManager
14 | {
15 | private readonly ulong _localGameWorld;
16 | private readonly HashSet _refillContainers;
17 | private bool _kill = false;
18 |
19 | public IReadOnlyCollection RefillContainers => _refillContainers;
20 |
21 | public InteractiveManager(ulong localGameWorld)
22 | {
23 | _localGameWorld = localGameWorld;
24 | _refillContainers = new();
25 | Init();
26 | }
27 |
28 | public void Init()
29 | {
30 | try
31 | {
32 | var interactableArrayPtr = Memory.ReadPtrChain(_localGameWorld, new uint[] { 0x268, 0x30 }, false);
33 | using var array = MemArray.Get(interactableArrayPtr, false);
34 | var set = array.Where(x => x != 0x0).ToHashSet();
35 | array.Dispose();
36 |
37 | foreach (var item in set)
38 | {
39 | var itemName = ObjectClass.ReadName(item);
40 | if (itemName == "ArenaPresetRefillContainer")
41 | {
42 | _refillContainers.Add(new ArenaPresetRefillContainer(item));
43 | _kill = false;
44 | }
45 | }
46 | }
47 | catch { _kill = true; return; }
48 | }
49 |
50 | public void Refresh()
51 | {
52 | if (_kill)
53 | return;
54 | if (_refillContainers.Count == 0)
55 | {
56 | Init();
57 | }
58 | foreach (var refill in _refillContainers)
59 | {
60 | refill.Refresh();
61 | }
62 | }
63 | }
64 | }
65 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/LowLevel/Types/RemoteBytes.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA;
2 | using eft_dma_shared.Common.Misc;
3 | using eft_dma_shared.Common.Unity.LowLevel.Hooks;
4 |
5 | namespace eft_dma_shared.Common.Unity.LowLevel.Types
6 | {
7 | public sealed class RemoteBytes : IDisposable
8 | {
9 | public static implicit operator ulong(RemoteBytes x) => x._pmem;
10 |
11 | private readonly uint _size;
12 | private ulong _pmem;
13 |
14 | public RemoteBytes(int size)
15 | {
16 | _size = MemDMABase.AlignLength((uint)size);
17 | _pmem = NativeMethods.AllocBytes(_size);
18 | _pmem.ThrowIfInvalidVirtualAddress();
19 | }
20 |
21 | public RemoteBytes(IMonoType data)
22 | {
23 | _size = MemDMABase.AlignLength((uint)data.Data.Length);
24 | _pmem = NativeMethods.AllocBytes(_size);
25 | _pmem.ThrowIfInvalidVirtualAddress();
26 | WriteMonoValue(data);
27 | }
28 |
29 | public void WriteValue(T value)
30 | where T : unmanaged
31 | {
32 | int writeSize = SizeChecker.Size;
33 | ArgumentOutOfRangeException.ThrowIfGreaterThan(writeSize, (int)_size, nameof(writeSize));
34 |
35 | Memory.WriteValueEnsure(_pmem, value);
36 | }
37 |
38 | public void WriteMonoValue(IMonoType value)
39 | {
40 | int writeSize = value.Data.Length;
41 | ArgumentOutOfRangeException.ThrowIfGreaterThan(writeSize, (int)_size, nameof(writeSize));
42 |
43 | Memory.WriteBufferEnsure(_pmem, value.Data);
44 | }
45 |
46 | public void WriteBuffer(Span buffer)
47 | where T : unmanaged
48 | {
49 | int writeSize = SizeChecker.Size * buffer.Length;
50 | ArgumentOutOfRangeException.ThrowIfGreaterThan(writeSize, (int)_size, nameof(writeSize));
51 |
52 | Memory.WriteBufferEnsure(_pmem, buffer);
53 | }
54 |
55 | public void Dispose()
56 | {
57 | ulong pmem = Interlocked.Exchange(ref _pmem, 0);
58 | if (pmem != 0x0)
59 | {
60 | NativeMethods.FreeBytes(pmem);
61 | }
62 | }
63 | }
64 | }
65 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/FileCrypt.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Security.Cryptography;
3 |
4 | namespace eft_dma_shared.Common.Misc
5 | {
6 | public static class FileCrypt
7 | {
8 | ///
9 | /// Opens an encrypted file from disk and loads it into memory.
10 | ///
11 | /// Path of the file to decrypt/open.
12 | /// Readable MemoryStream of the decrypted file contents.
13 | public static MemoryStream OpenEncryptedFile(string filePath)
14 | {
15 | try
16 | {
17 | byte[] salt = new byte[12];
18 | byte[] nonce = new byte[12];
19 | byte[] tag = new byte[16];
20 | byte[] ct, pt;
21 | using (var fs = new FileStream(filePath, FileMode.Open, FileAccess.Read))
22 | {
23 | ct = new byte[fs.Length - salt.Length - nonce.Length - tag.Length];
24 | fs.ReadExactly(salt);
25 | fs.ReadExactly(nonce);
26 | fs.ReadExactly(tag);
27 | fs.ReadExactly(ct);
28 | }
29 | pt = new byte[ct.Length];
30 | byte[] key;
31 | using (var h = new Rfc2898DeriveBytes(UnpackEncryptionKey(), salt, 600000, HashAlgorithmName.SHA512))
32 | {
33 | key = h.GetBytes(32);
34 | }
35 | using (var aes = new AesGcm(key, tag.Length))
36 | {
37 | aes.Decrypt(nonce, ct, tag, pt);
38 | }
39 | return new MemoryStream(pt, false);
40 | }
41 | catch
42 | {
43 | return null;
44 | }
45 | }
46 |
47 | private static byte[] UnpackEncryptionKey()
48 | {
49 | // Unpack AES Key from Resources
50 | using (var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("eft-dma-shared.FILE_CRYPT_KEY.bin"))
51 | {
52 | var key = new byte[stream!.Length];
53 | stream.ReadExactly(key);
54 | return key;
55 | }
56 | }
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/WebRadar/Data/WebRadarPlayer.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using MessagePack;
3 |
4 | namespace eft_dma_radar.Tarkov.WebRadar.Data
5 | {
6 | [MessagePackObject]
7 | public readonly struct WebRadarPlayer
8 | {
9 | ///
10 | /// Player Name.
11 | ///
12 | [Key(0)]
13 | public readonly string Name { get; init; }
14 | ///
15 | /// Player Type (PMC, Scav,etc.)
16 | ///
17 | [Key(1)]
18 | public readonly WebPlayerType Type { get; init; }
19 | ///
20 | /// True if player is active, otherwise False.
21 | ///
22 | [Key(2)]
23 | public readonly bool IsActive { get; init; }
24 | ///
25 | /// True if player is alive, otherwise False.
26 | ///
27 | [Key(3)]
28 | public readonly bool IsAlive { get; init; }
29 | ///
30 | /// Unity World Position.
31 | ///
32 | [Key(4)]
33 | public readonly Vector3 Position { get; init; }
34 | ///
35 | /// Unity World Rotation.
36 | ///
37 | [Key(5)]
38 | public readonly Vector2 Rotation { get; init; }
39 |
40 | ///
41 | /// Create a WebRadarPlayer from a Full Player Object.
42 | ///
43 | /// Full EFT Player Object.
44 | /// Compact WebRadarPlayer object.
45 | public static WebRadarPlayer CreateFromPlayer(Player player)
46 | {
47 | WebPlayerType type = player is LocalPlayer ?
48 | WebPlayerType.LocalPlayer : player.IsFriendly ?
49 | WebPlayerType.Teammate : player.IsHuman ?
50 | player.IsScav ?
51 | WebPlayerType.PlayerScav : WebPlayerType.Player : WebPlayerType.Bot;
52 | return new WebRadarPlayer
53 | {
54 | Name = player.Name,
55 | Type = type,
56 | IsActive = player.IsActive,
57 | IsAlive = player.IsAlive,
58 | Position = player.Position,
59 | Rotation = player.Rotation
60 | };
61 | }
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/DMA/ScatterAPI/ScatterReadMap.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Pools;
2 |
3 | namespace eft_dma_shared.Common.DMA.ScatterAPI
4 | {
5 | ///
6 | /// Provides mapping for a Scatter Read Operation. May contain multiple Scatter Read Rounds.
7 | /// This API is *NOT* Thread Safe! Keep operations synchronous.
8 | ///
9 | public sealed class ScatterReadMap : IPooledObject
10 | {
11 | private readonly List _rounds = new();
12 | ///
13 | /// [Optional] Callback(s) to be executed on completion of *all* scatter read executions.
14 | /// NOTE: Be sure to handle exceptions!
15 | ///
16 | public Action CompletionCallbacks { get; set; }
17 |
18 | [Obsolete("You must rent this object via IPooledObject!")]
19 | public ScatterReadMap() { }
20 |
21 | ///
22 | /// Get a ScatterReadMap.
23 | ///
24 | /// ScatterReadMap object from the object pool.
25 | public static ScatterReadMap Get() =>
26 | IPooledObject.Rent();
27 |
28 | ///
29 | /// Executes Scatter Read operation as defined per the map.
30 | ///
31 | public void Execute()
32 | {
33 | if (_rounds.Count == 0)
34 | return;
35 | foreach (var round in _rounds)
36 | round.Run();
37 | CompletionCallbacks?.Invoke();
38 | }
39 | ///
40 | /// (Base)
41 | /// Add scatter read rounds to the operation. Each round is a successive scatter read, you may need multiple
42 | /// rounds if you have reads dependent on earlier scatter reads result(s).
43 | ///
44 | /// ScatterReadRound object.
45 | public ScatterReadRound AddRound(bool useCache = true)
46 | {
47 | var round = ScatterReadRound.Get(useCache);
48 | _rounds.Add(round);
49 | return round;
50 | }
51 |
52 | public void Dispose()
53 | {
54 | IPooledObject.Return(this);
55 | }
56 |
57 | public void SetDefault()
58 | {
59 | foreach (var rd in _rounds)
60 | rd.Dispose();
61 | _rounds.Clear();
62 | CompletionCallbacks = default;
63 | }
64 | }
65 | }
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ESP/EspForm.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_radar.UI.ESP
2 | {
3 | partial class EspForm
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | ComponentResourceManager resources = new ComponentResourceManager(typeof(EspForm));
32 | skglControl_ESP = new SKGLControl();
33 | SuspendLayout();
34 | //
35 | // skglControl_ESP
36 | //
37 | skglControl_ESP.BackColor = Color.Black;
38 | skglControl_ESP.Dock = DockStyle.Fill;
39 | skglControl_ESP.Location = new Point(0, 0);
40 | skglControl_ESP.Margin = new Padding(4, 3, 4, 3);
41 | skglControl_ESP.Name = "skglControl_ESP";
42 | skglControl_ESP.Size = new Size(624, 441);
43 | skglControl_ESP.TabIndex = 0;
44 | skglControl_ESP.VSync = false;
45 | skglControl_ESP.PaintSurface += skglControl_ESP_PaintSurface;
46 | //
47 | // EspForm
48 | //
49 | AutoScaleDimensions = new SizeF(7F, 15F);
50 | AutoScaleMode = AutoScaleMode.Font;
51 | ClientSize = new Size(624, 441);
52 | Controls.Add(skglControl_ESP);
53 | FormBorderStyle = FormBorderStyle.FixedSingle;
54 | Icon = (Icon)resources.GetObject("$this.Icon");
55 | MinimizeBox = false;
56 | Name = "EspForm";
57 | Text = "ESP";
58 | TopMost = true;
59 | ResumeLayout(false);
60 | }
61 |
62 | #endregion
63 |
64 | private SKGLControl skglControl_ESP;
65 | }
66 | }
--------------------------------------------------------------------------------
/arena-dma-radar/UI/ESP/EspForm.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace arena_dma_radar.UI.ESP
2 | {
3 | partial class EspForm
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | ComponentResourceManager resources = new ComponentResourceManager(typeof(EspForm));
32 | skglControl_ESP = new SKGLControl();
33 | SuspendLayout();
34 | //
35 | // skglControl_ESP
36 | //
37 | skglControl_ESP.BackColor = Color.Black;
38 | skglControl_ESP.Dock = DockStyle.Fill;
39 | skglControl_ESP.Location = new Point(0, 0);
40 | skglControl_ESP.Margin = new Padding(4, 3, 4, 3);
41 | skglControl_ESP.Name = "skglControl_ESP";
42 | skglControl_ESP.Size = new Size(624, 441);
43 | skglControl_ESP.TabIndex = 0;
44 | skglControl_ESP.VSync = false;
45 | skglControl_ESP.PaintSurface += skglControl_ESP_PaintSurface;
46 | //
47 | // EspForm
48 | //
49 | AutoScaleDimensions = new SizeF(7F, 15F);
50 | AutoScaleMode = AutoScaleMode.Font;
51 | ClientSize = new Size(624, 441);
52 | Controls.Add(skglControl_ESP);
53 | FormBorderStyle = FormBorderStyle.FixedSingle;
54 | Icon = (Icon)resources.GetObject("$this.Icon");
55 | MinimizeBox = false;
56 | Name = "EspForm";
57 | Text = "ESP";
58 | TopMost = true;
59 | ResumeLayout(false);
60 | }
61 |
62 | #endregion
63 |
64 | private SKGLControl skglControl_ESP;
65 | }
66 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/DMA/ScatterAPI/ScatterReadRound.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA;
2 | using eft_dma_shared.Common.Misc.Pools;
3 |
4 | namespace eft_dma_shared.Common.DMA.ScatterAPI
5 | {
6 | ///
7 | /// Defines a Scatter Read Round. Each round will execute a single scatter read. If you have reads that
8 | /// are dependent on previous reads (chained pointers for example), you may need multiple rounds.
9 | ///
10 | public sealed class ScatterReadRound : IPooledObject
11 | {
12 | private readonly Dictionary _indexes = new();
13 | public bool UseCache { get; private set; }
14 |
15 | [Obsolete("You must rent this object via IPooledObject!")]
16 | public ScatterReadRound() { }
17 |
18 | ///
19 | /// Get a Scatter Read Round from the Object Pool.
20 | ///
21 | /// Rented ScatterReadRound instance.
22 | public static ScatterReadRound Get(bool usecache)
23 | {
24 | var rd = IPooledObject.Rent();
25 | rd.UseCache = usecache;
26 | return rd;
27 | }
28 |
29 | ///
30 | /// Returns the requested ScatterReadIndex.
31 | ///
32 | /// Index to retrieve.
33 | /// ScatterReadIndex object.
34 | public ScatterReadIndex this[int index]
35 | {
36 | get
37 | {
38 | if (_indexes.TryGetValue(index, out var existing))
39 | return existing;
40 | return _indexes[index] = IPooledObject.Rent();
41 | }
42 | }
43 |
44 | ///
45 | /// ** Internal use only do not use **
46 | ///
47 | internal void Run()
48 | {
49 | Memory.ReadScatter(_indexes.Values.SelectMany(x => x.Entries.Values).ToArray(), UseCache);
50 | foreach (var index in _indexes)
51 | index.Value.ExecuteCallback();
52 | }
53 |
54 | public void Dispose()
55 | {
56 | IPooledObject.Return(this);
57 | }
58 |
59 | public void SetDefault()
60 | {
61 | foreach (var index in _indexes.Values)
62 | index.Dispose();
63 | _indexes.Clear();
64 | UseCache = default;
65 | }
66 | }
67 | }
68 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/Collections/MemList.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA;
2 | using eft_dma_shared.Common.Misc.Pools;
3 |
4 | namespace eft_dma_shared.Common.Unity.Collections
5 | {
6 | ///
7 | /// DMA Wrapper for a C# List
8 | /// Must initialize before use. Must dispose after use.
9 | ///
10 | /// Collection Type
11 | public sealed class MemList : SharedArray, IPooledObject>
12 | where T : unmanaged
13 | {
14 | public const uint CountOffset = 0x18;
15 | public const uint ArrOffset = 0x10;
16 | public const uint ArrStartOffset = 0x20;
17 |
18 | ///
19 | /// Get a MemList from the object pool.
20 | ///
21 | /// Base Address for this collection.
22 | /// Perform cached reading.
23 | /// Rented MemList instance.
24 | public static MemList Get(ulong addr, bool useCache = true)
25 | {
26 | var list = IPooledObject>.Rent();
27 | list.Initialize(addr, useCache);
28 | return list;
29 | }
30 |
31 | ///
32 | /// Initializer for Unity List
33 | ///
34 | /// Base Address for this collection.
35 | /// Perform cached reading.
36 | private void Initialize(ulong addr, bool useCache = true)
37 | {
38 | try
39 | {
40 | var count = Memory.ReadValue(addr + CountOffset, useCache);
41 | ArgumentOutOfRangeException.ThrowIfGreaterThan(count, 16384, nameof(count));
42 | Initialize(count);
43 | if (count == 0)
44 | return;
45 | var listBase = Memory.ReadPtr(addr + ArrOffset, useCache) + ArrStartOffset;
46 | Memory.ReadBuffer(listBase, Span, useCache);
47 | }
48 | catch
49 | {
50 | Dispose();
51 | throw;
52 | }
53 | }
54 |
55 | [Obsolete("You must rent this object via IPooledObject!")]
56 | public MemList() : base() { }
57 |
58 | protected override void Dispose(bool disposing)
59 | {
60 | IPooledObject>.Return(this);
61 | }
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/Bones.cs:
--------------------------------------------------------------------------------
1 | using System.ComponentModel;
2 |
3 | namespace eft_dma_shared.Common.Unity
4 | {
5 | ///
6 | /// Bones Index for Player Transforms.
7 | ///
8 | public enum Bones : uint
9 | {
10 | [Description("HumanBase")]
11 | HumanBase = 0,
12 | [Description("Stomach")]
13 | HumanPelvis = 14,
14 | [Description("HumanLThigh1")]
15 | HumanLThigh1 = 15,
16 | [Description("HumanLThigh2")]
17 | HumanLThigh2 = 16,
18 | [Description("HumanLCalf")]
19 | HumanLCalf = 17,
20 | [Description("HumanLFoot")]
21 | HumanLFoot = 18,
22 | [Description("HumanLToe")]
23 | HumanLToe = 19,
24 | [Description("HumanRThigh1")]
25 | HumanRThigh1 = 20,
26 | [Description("HumanRThigh2")]
27 | HumanRThigh2 = 21,
28 | [Description("HumanRCalf")]
29 | HumanRCalf = 22,
30 | [Description("HumanRFoot")]
31 | HumanRFoot = 23,
32 | [Description("HumanRToe")]
33 | HumanRToe = 24,
34 | [Description("HumanSpine1")]
35 | HumanSpine1 = 29,
36 | [Description("HumanSpine2")]
37 | HumanSpine2 = 36,
38 | [Description("Thorax")]
39 | HumanSpine3 = 37,
40 | [Description("HumanLCollarbone")]
41 | HumanLCollarbone = 89,
42 | [Description("HumanLUpperarm")]
43 | HumanLUpperarm = 90,
44 | [Description("HumanLForearm1")]
45 | HumanLForearm1 = 91,
46 | [Description("HumanLForearm2")]
47 | HumanLForearm2 = 92,
48 | [Description("HumanLForearm3")]
49 | HumanLForearm3 = 93,
50 | [Description("HumanLPalm")]
51 | HumanLPalm = 94,
52 | [Description("HumanRCollarbone")]
53 | HumanRCollarbone = 110,
54 | [Description("HumanRUpperarm")]
55 | HumanRUpperarm = 111,
56 | [Description("HumanRForearm1")]
57 | HumanRForearm1 = 112,
58 | [Description("HumanRForearm2")]
59 | HumanRForearm2 = 113,
60 | [Description("HumanRForearm3")]
61 | HumanRForearm3 = 114,
62 | [Description("HumanRPalm")]
63 | HumanRPalm = 115,
64 | [Description("Neck")]
65 | HumanNeck = 132,
66 | [Description("Head")]
67 | HumanHead = 133,
68 | ///
69 | /// Custom Define - Do not read at this index.
70 | ///
71 | [Description("Legs")]
72 | Legs = 9999
73 | };
74 | }
75 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/Patches/FixWildSpawnType.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_shared.Common.Features;
3 | using eft_dma_shared.Common.Misc;
4 | using eft_dma_shared.Common.Unity;
5 | using eft_dma_shared.Common.Unity.LowLevel.Hooks;
6 |
7 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites.Patches
8 | {
9 | public class FixWildSpawnType : MemPatchFeature
10 | {
11 | private const byte o1 = (byte)Offsets.PlayerSpawnInfo.Side;
12 | private const byte o2 = (byte)Offsets.InfoContainer.Side;
13 |
14 | private const byte p1 = (byte)Offsets.PlayerSpawnInfo.WildSpawnType;
15 |
16 | public override bool Enabled
17 | {
18 | get => MemWrites.Config.AdvancedMemWrites;
19 | set { }
20 | }
21 | protected override byte[] Signature { get; } = new byte[]
22 | {
23 | 0x48, 0x63, 0x40, o1, // movsxd rax, dword ptr [rax+SIDE_OFFSET_PlayerSpawnInfo]
24 | 0x89, 0x46, o2, // mov [rsi+SIDE_OFFSET_InfoContainer], eax
25 | };
26 | protected override byte[] Patch { get; } = new byte[]
27 | {
28 | 0x48, 0x63, 0x40, p1, // movsxd rax, dword ptr [rax+SIDE_OFFSET_PlayerSpawnInfo]
29 | 0x89, 0x46, o2, // mov [rsi+SIDE_OFFSET_InfoContainer], eax
30 | };
31 |
32 | protected override Func GetPFunc => Lookup_SetUpSpawnInfo;
33 | protected override int PFuncSize => 0x100;
34 |
35 | public override void OnGameStop()
36 | {
37 | IsApplied = false;
38 | }
39 |
40 | private static ulong Lookup_SetUpSpawnInfo()
41 | {
42 | if (!NativeHook.Initialized)
43 | throw new Exception("NativeHook not initialized!");
44 | var @class = MonoLib.MonoClass.Find("Assembly-CSharp", ClassNames.FixWildSpawnType.ClassName, out ulong classAddr);
45 | classAddr.ThrowIfInvalidVirtualAddress();
46 | if (NativeMethods.CompileClass(classAddr) == 0)
47 | throw new Exception("Failed to compile class");
48 | if (@class.TryFindJittedMethod(ClassNames.FixWildSpawnType.MethodName, out ulong method))
49 | {
50 | return method;
51 | }
52 | else
53 | {
54 | var jittedMethod = NativeMethods.CompileMethod(method);
55 | if (jittedMethod == 0)
56 | throw new Exception("Failed to compile method");
57 | return jittedMethod;
58 | }
59 | }
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/UnityOffsets.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_shared.Common.Unity
2 | {
3 | public readonly struct UnityOffsets
4 | {
5 | public readonly struct ModuleBase
6 | {
7 | public const uint GameObjectManager = 0x1CF93E0; // to eft_dma_radar.GameObjectManager
8 | public const uint AllCameras = 0x1BF8BC0; // Lookup in IDA 's_AllCamera'
9 | public const uint InputManager = 0x1C91748;
10 | public const uint GfxDevice = 0x1CF9F48; // g_MainGfxDevice , Type GfxDeviceClient
11 | }
12 | public readonly struct UnityInputManager
13 | {
14 | public const uint CurrentKeyState = 0x60; // 0x50 + 0x8
15 | }
16 | public readonly struct TransformInternal
17 | {
18 | public const uint TransformAccess = 0x38; // to TransformHierarchy
19 | }
20 | public readonly struct TransformAccess
21 | {
22 | public const uint Vertices = 0x18; // MemList
23 | public const uint Indices = 0x20; // MemList
24 | }
25 | public readonly struct SkinnedMeshRenderer // SkinnedMeshRenderer : Renderer
26 | {
27 | public const uint Renderer = 0x10; // Renderer : Unity::Component
28 | }
29 | public readonly struct Renderer // Renderer : Unity::Component
30 | {
31 | public const uint Materials = 0x148; // m_Materials : dynamic_array,0>
32 | public const uint Count = 0x158; // Extends from m_Materials type (0x20 length?)
33 | }
34 |
35 | public readonly struct Camera
36 | {
37 | // CopiableState struct begins at 0x40
38 | public const uint ViewMatrix = 0x100;
39 | public const uint FOV = 0x180;
40 | public const uint AspectRatio = 0x4F0;
41 | public const uint OcclusionCulling = 0x524; // bool, Camera::CopiableState -> m_OcclusionCulling
42 | }
43 |
44 | public readonly struct GfxDeviceClient
45 | {
46 | public const uint Viewport = 0x25A0; // m_Viewport RectT ?
47 | }
48 |
49 | public readonly struct UnityAnimator // Animator struc ; (sizeof=0x6A0, align=0x8, copyof_18870)
50 | {
51 | public const uint Speed = 0x488; // 0000047C m_Speed
52 | }
53 |
54 | public readonly struct SSAA // Unity.Postprocessing.Runtime Assembly in UNISPECT
55 | {
56 | public const uint OpticMaskMaterial = 0x60; // -.SSAA->_opticMaskMaterial // Offset: 0x0060 (Type: UnityEngine.Material)
57 | }
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/eft-dma-radar.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 17
4 | VisualStudioVersion = 17.0.31912.275
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eft-dma-shared", "eft-dma-shared\eft-dma-shared.csproj", "{6D8F90BD-7B14-420E-4422-9F1B0E716CC7}"
7 | EndProject
8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eft-dma-radar", "eft-dma-radar\eft-dma-radar.csproj", "{7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}"
9 | EndProject
10 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "arena-dma-radar", "arena-dma-radar\arena-dma-radar.csproj", "{95F68917-F531-DF0E-E10F-128BA0B85C6F}"
11 | EndProject
12 | Global
13 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
14 | Commercial|x64 = Commercial|x64
15 | Debug|x64 = Debug|x64
16 | Release|x64 = Release|x64
17 | EndGlobalSection
18 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
19 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Commercial|x64.ActiveCfg = Commercial|x64
20 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Commercial|x64.Build.0 = Commercial|x64
21 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Debug|x64.ActiveCfg = Debug|x64
22 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Debug|x64.Build.0 = Debug|x64
23 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Release|x64.ActiveCfg = Release|x64
24 | {6D8F90BD-7B14-420E-4422-9F1B0E716CC7}.Release|x64.Build.0 = Release|x64
25 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Commercial|x64.ActiveCfg = Release|x64
26 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Commercial|x64.Build.0 = Release|x64
27 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Debug|x64.ActiveCfg = Debug|x64
28 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Debug|x64.Build.0 = Debug|x64
29 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Release|x64.ActiveCfg = Release|x64
30 | {7F6D99FB-CD79-68B0-78DE-FDEB5E23FA1E}.Release|x64.Build.0 = Release|x64
31 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Commercial|x64.ActiveCfg = Release|x64
32 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Commercial|x64.Build.0 = Release|x64
33 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Debug|x64.ActiveCfg = Debug|x64
34 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Debug|x64.Build.0 = Debug|x64
35 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Release|x64.ActiveCfg = Release|x64
36 | {95F68917-F531-DF0E-E10F-128BA0B85C6F}.Release|x64.Build.0 = Release|x64
37 | EndGlobalSection
38 | GlobalSection(SolutionProperties) = preSolution
39 | HideSolutionNode = FALSE
40 | EndGlobalSection
41 | GlobalSection(ExtensibilityGlobals) = postSolution
42 | SolutionGuid = {9FE05244-9482-47D1-B12C-9357E58CD3AB}
43 | EndGlobalSection
44 | EndGlobal
45 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/EFTPlayer/SpecialCollections/PlayerHistory.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.Misc;
2 | using eft_dma_radar.UI.Radar;
3 |
4 | namespace eft_dma_radar.Tarkov.EFTPlayer.SpecialCollections
5 | {
6 | ///
7 | /// Wrapper class to manage Player History.
8 | /// Thread Safe.
9 | ///
10 | public sealed class PlayerHistory
11 | {
12 | private readonly HashSet _logged = new();
13 | private readonly BindingList _entries = new();
14 |
15 | ///
16 | /// Adds an entry to the Player History.
17 | ///
18 | /// Player to add/update.
19 | public void AddOrUpdate(Player player)
20 | {
21 | try
22 | {
23 | if (player.IsHumanOther) /// Log to Player History
24 | {
25 | var entry = new PlayerHistoryEntry(player);
26 | MainForm.Window?.Invoke(() =>
27 | {
28 | if (_logged.Add(player)) // Add
29 | {
30 | _entries.Insert(0, entry);
31 | _entries.ResetBindings();
32 | }
33 | else // Update
34 | {
35 | var oldEntry = _entries.FirstOrDefault(x => (ulong)x.Player == (ulong)player);
36 | if (oldEntry is not null)
37 | {
38 | int index = _entries.IndexOf(oldEntry);
39 | _entries[index] = entry;
40 | _entries.ResetBindings();
41 | }
42 | }
43 | });
44 | }
45 | }
46 | catch { }
47 | }
48 |
49 | ///
50 | /// Resets the Player History state for a new raid.
51 | /// Does not clear existing entries, but clears the HashSet that prevents players from being added multiple times.
52 | ///
53 | public void Reset()
54 | {
55 | MainForm.Window?.Invoke(() =>
56 | {
57 | _logged.Clear();
58 | });
59 | }
60 |
61 | ///
62 | /// Get a reference to the backing collection.
63 | /// UNSAFE! Should only be done for binding purposes.
64 | ///
65 | /// List reference.
66 | public BindingList GetReferenceUnsafe() => _entries;
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/EFTPlayer/SpecialCollections/PlayerWatchlist.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.UI.Misc;
2 | using eft_dma_radar.UI.Radar;
3 |
4 | namespace eft_dma_radar.Tarkov.EFTPlayer.SpecialCollections
5 | {
6 | ///
7 | /// Wrapper class to manage Player Watchlist.
8 | /// Thread Safe.
9 | ///
10 | public sealed class PlayerWatchlist
11 | {
12 | private readonly SortableBindingList _bindingList;
13 |
14 | ///
15 | /// Entries in this watchlist.
16 | ///
17 | public IReadOnlyDictionary Entries { get; private set; } = new Dictionary();
18 |
19 | ///
20 | /// Singleton Constructor.
21 | /// Only construct once!
22 | ///
23 | public PlayerWatchlist()
24 | {
25 | Program.Config.PlayerWatchlist = Program.Config.PlayerWatchlist
26 | .Where(x => x is not null && !string.IsNullOrWhiteSpace(x.AcctID))
27 | .OrderBy(x => x.Timestamp.Ticks)
28 | .DistinctBy(x => x.AcctID)
29 | .ToList(); // Sanitize List
30 | _bindingList = new(Program.Config.PlayerWatchlist);
31 | Update();
32 | _bindingList.ListChanged += Entries_ListChanged;
33 | }
34 |
35 | private void Entries_ListChanged(object sender, ListChangedEventArgs e) => Update();
36 |
37 | ///
38 | /// Update the backing dictionary to reflect the BindingList.
39 | ///
40 | private void Update()
41 | {
42 | this.Entries = _bindingList
43 | .DistinctBy(x => x.AcctID)
44 | .ToDictionary(
45 | item => item.AcctID, // key
46 | item => item); // value
47 | }
48 |
49 | ///
50 | /// Manually add an entry into the Player Watchlist.
51 | /// Will be invoked on the UI Thread.
52 | ///
53 | /// Entry to add.
54 | public void ManualAdd(PlayerWatchlistEntry entry)
55 | {
56 | MainForm.Window?.Invoke(() =>
57 | {
58 | _bindingList.Add(entry);
59 | });
60 | }
61 |
62 | ///
63 | /// Get a reference to the backing collection.
64 | /// UNSAFE! Should only be done for binding purposes.
65 | ///
66 | /// BindingList reference.
67 | internal SortableBindingList GetReferenceUnsafe() => _bindingList;
68 | }
69 | }
70 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | ###############################################################################
2 | # Set default behavior to automatically normalize line endings.
3 | ###############################################################################
4 | * text=auto
5 |
6 | ###############################################################################
7 | # Set default behavior for command prompt diff.
8 | #
9 | # This is need for earlier builds of msysgit that does not have it on by
10 | # default for csharp files.
11 | # Note: This is only used by command line
12 | ###############################################################################
13 | #*.cs diff=csharp
14 |
15 | ###############################################################################
16 | # Set the merge driver for project and solution files
17 | #
18 | # Merging from the command prompt will add diff markers to the files if there
19 | # are conflicts (Merging from VS is not affected by the settings below, in VS
20 | # the diff markers are never inserted). Diff markers may cause the following
21 | # file extensions to fail to load in VS. An alternative would be to treat
22 | # these files as binary and thus will always conflict and require user
23 | # intervention with every merge. To do so, just uncomment the entries below
24 | ###############################################################################
25 | #*.sln merge=binary
26 | #*.csproj merge=binary
27 | #*.vbproj merge=binary
28 | #*.vcxproj merge=binary
29 | #*.vcproj merge=binary
30 | #*.dbproj merge=binary
31 | #*.fsproj merge=binary
32 | #*.lsproj merge=binary
33 | #*.wixproj merge=binary
34 | #*.modelproj merge=binary
35 | #*.sqlproj merge=binary
36 | #*.wwaproj merge=binary
37 |
38 | ###############################################################################
39 | # behavior for image files
40 | #
41 | # image files are treated as binary by default.
42 | ###############################################################################
43 | #*.jpg binary
44 | #*.png binary
45 | #*.gif binary
46 |
47 | ###############################################################################
48 | # diff behavior for common document formats
49 | #
50 | # Convert binary document formats to text before diffing them. This feature
51 | # is only available from the command line. Turn it on by uncommenting the
52 | # entries below.
53 | ###############################################################################
54 | #*.doc diff=astextplain
55 | #*.DOC diff=astextplain
56 | #*.docx diff=astextplain
57 | #*.DOCX diff=astextplain
58 | #*.dot diff=astextplain
59 | #*.DOT diff=astextplain
60 | #*.pdf diff=astextplain
61 | #*.PDF diff=astextplain
62 | #*.rtf diff=astextplain
63 | #*.RTF diff=astextplain
64 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Features/MemoryWrites/UI/AimbotRandomBoneForm.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.Features.MemoryWrites;
2 | using arena_dma_radar.UI.Misc;
3 |
4 | namespace arena_dma_radar.Features.MemoryWrites.UI
5 | {
6 | public sealed partial class AimbotRandomBoneForm : Form
7 | {
8 | private static AimbotRandomBoneConfig Config { get; } = Aimbot.Config.RandomBone;
9 |
10 | public AimbotRandomBoneForm()
11 | {
12 | InitializeComponent();
13 | if (!Config.Is100Percent)
14 | Config.ResetDefaults();
15 | textBox_Head.Text = Config.HeadPercent.ToString();
16 | textBox_Torso.Text = Config.TorsoPercent.ToString();
17 | textBox_Arms.Text = Config.ArmsPercent.ToString();
18 | textBox_Legs.Text = Config.LegsPercent.ToString();
19 | }
20 |
21 | private void HeadDefault() => textBox_Head.Text = "10";
22 | private void TorsoDefault() => textBox_Torso.Text = "38";
23 | private void ArmsDefault() => textBox_Arms.Text = "26";
24 | private void LegsDefault() => textBox_Legs.Text = "26";
25 |
26 | private void button_OK_Click(object sender, EventArgs e)
27 | {
28 | if (!Config.Is100Percent)
29 | {
30 | MessageBox.Show(this, "Values do not add up to exactly 100%! Please correct your values.", Program.Name, MessageBoxButtons.OK, MessageBoxIcon.Warning);
31 | return;
32 | }
33 | this.DialogResult = DialogResult.OK;
34 | }
35 | private void textBox_Head_TextChanged(object sender, EventArgs e)
36 | {
37 | int value;
38 | while (!int.TryParse(textBox_Head.Text, out value) || value < 0)
39 | HeadDefault();
40 | Config.HeadPercent = value;
41 | }
42 |
43 | private void textBox_Torso_TextChanged(object sender, EventArgs e)
44 | {
45 | int value;
46 | while (!int.TryParse(textBox_Torso.Text, out value) || value < 0)
47 | TorsoDefault();
48 | Config.TorsoPercent = value;
49 | }
50 |
51 | private void textBox_Arms_TextChanged(object sender, EventArgs e)
52 | {
53 | int value;
54 | while (!int.TryParse(textBox_Arms.Text, out value) || value < 0)
55 | ArmsDefault();
56 | Config.ArmsPercent = value;
57 | }
58 |
59 | private void textBox_Legs_TextChanged(object sender, EventArgs e)
60 | {
61 | int value;
62 | while (!int.TryParse(textBox_Legs.Text, out value) || value < 0)
63 | LegsDefault();
64 | Config.LegsPercent = value;
65 | }
66 | }
67 | }
68 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/UI/AimbotRandomBoneForm.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features.MemoryWrites;
2 | using eft_dma_radar.UI.Misc;
3 |
4 | namespace eft_dma_radar.Features.MemoryWrites.UI
5 | {
6 | public sealed partial class AimbotRandomBoneForm : Form
7 | {
8 | private static AimbotRandomBoneConfig Config { get; } = Aimbot.Config.RandomBone;
9 |
10 | public AimbotRandomBoneForm()
11 | {
12 | InitializeComponent();
13 | if (!Config.Is100Percent)
14 | Config.ResetDefaults();
15 | textBox_Head.Text = Config.HeadPercent.ToString();
16 | textBox_Torso.Text = Config.TorsoPercent.ToString();
17 | textBox_Arms.Text = Config.ArmsPercent.ToString();
18 | textBox_Legs.Text = Config.LegsPercent.ToString();
19 | }
20 |
21 | private void HeadDefault() => textBox_Head.Text = "10";
22 | private void TorsoDefault() => textBox_Torso.Text = "38";
23 | private void ArmsDefault() => textBox_Arms.Text = "26";
24 | private void LegsDefault() => textBox_Legs.Text = "26";
25 |
26 | private void button_OK_Click(object sender, EventArgs e)
27 | {
28 | if (!Config.Is100Percent)
29 | {
30 | MessageBox.Show(this, "Values do not add up to exactly 100%! Please correct your values.", Program.Name, MessageBoxButtons.OK, MessageBoxIcon.Warning);
31 | return;
32 | }
33 | this.DialogResult = DialogResult.OK;
34 | }
35 |
36 | private void textBox_Head_TextChanged(object sender, EventArgs e)
37 | {
38 | int value;
39 | while (!int.TryParse(textBox_Head.Text, out value) || value < 0)
40 | HeadDefault();
41 | Config.HeadPercent = value;
42 | }
43 |
44 | private void textBox_Torso_TextChanged(object sender, EventArgs e)
45 | {
46 | int value;
47 | while (!int.TryParse(textBox_Torso.Text, out value) || value < 0)
48 | TorsoDefault();
49 | Config.TorsoPercent = value;
50 | }
51 |
52 | private void textBox_Arms_TextChanged(object sender, EventArgs e)
53 | {
54 | int value;
55 | while (!int.TryParse(textBox_Arms.Text, out value) || value < 0)
56 | ArmsDefault();
57 | Config.ArmsPercent = value;
58 | }
59 |
60 | private void textBox_Legs_TextChanged(object sender, EventArgs e)
61 | {
62 | int value;
63 | while (!int.TryParse(textBox_Legs.Text, out value) || value < 0)
64 | LegsDefault();
65 | Config.LegsPercent = value;
66 | }
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/PrecisionTimer.cs:
--------------------------------------------------------------------------------
1 | using System.Runtime.Intrinsics.X86;
2 |
3 | namespace eft_dma_shared.Common.Misc
4 | {
5 | ///
6 | /// Provides a High Precision Timer mechanism that resolves to 100-nanosecond periods.
7 | ///
8 | public sealed class PrecisionTimer : IDisposable
9 | {
10 | private readonly WaitTimer _timer = new();
11 | private readonly TimeSpan _interval;
12 | private volatile bool _isRunning = false;
13 |
14 | ///
15 | /// Callback to execute when timer fires.
16 | ///
17 | public event EventHandler Elapsed = null;
18 |
19 | public PrecisionTimer()
20 | {
21 | _timer = new();
22 | }
23 |
24 | public PrecisionTimer(TimeSpan interval)
25 | {
26 | _interval = interval;
27 | }
28 |
29 | ///
30 | /// Start the timer.
31 | ///
32 | public void Start()
33 | {
34 | if (_isRunning)
35 | return;
36 | new Thread(Worker)
37 | {
38 | IsBackground = true
39 | }.Start();
40 | }
41 |
42 |
43 | ///
44 | /// Stop the timer.
45 | ///
46 | public void Stop()
47 | {
48 | _isRunning = false;
49 | }
50 |
51 | private void Worker()
52 | {
53 | _isRunning = true;
54 | while (_isRunning)
55 | {
56 | try
57 | {
58 | if (_interval <= TimeSpan.Zero) // Busy wait
59 | {
60 | if (X86Base.IsSupported)
61 | X86Base.Pause();
62 | else
63 | Thread.Yield();
64 | }
65 | else
66 | _timer.AutoWait(_interval);
67 | if (_isRunning)
68 | Elapsed?.Invoke(this, EventArgs.Empty);
69 | }
70 | catch { }
71 | }
72 | }
73 |
74 | #region IDisposable
75 | private bool _disposed;
76 | public void Dispose()
77 | {
78 | bool disposed = Interlocked.Exchange(ref _disposed, true);
79 | if (!disposed)
80 | {
81 | Stop();
82 | if (Elapsed is not null)
83 | {
84 | foreach (var sub in Elapsed.GetInvocationList().Cast())
85 | Elapsed -= sub;
86 | }
87 | try { _timer.Dispose(); } catch { }
88 | }
89 | }
90 | #endregion
91 | }
92 | }
93 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Interactive/Switches.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar;
2 | using eft_dma_radar.Tarkov.EFTPlayer;
3 | using eft_dma_radar.Tarkov.GameWorld;
4 | using eft_dma_radar.UI.ESP;
5 | using eft_dma_radar.UI.Misc;
6 | using eft_dma_radar.UI.Radar;
7 | using eft_dma_shared.Common.Misc;
8 | using eft_dma_shared.Common.Misc.Data;
9 | using eft_dma_shared.Common.Players;
10 | using eft_dma_shared.Common.Unity;
11 | using System;
12 | using System.Collections.Generic;
13 | using System.Linq;
14 | using System.Text;
15 | using System.Threading.Tasks;
16 | using static eft_dma_shared.Common.Misc.Data.EftDataManager;
17 |
18 | namespace LonesEFTRadar.Tarkov.GameWorld.Interactive
19 | {
20 | public sealed class Switches : IESPEntity, IWorldEntity
21 | {
22 |
23 | private static readonly uint[] _transformInternalChain =
24 | [
25 | ObjectClass.MonoBehaviourOffset,
26 | MonoBehaviour.GameObjectOffset,
27 | GameObject.ComponentsOffset,
28 | 0x8
29 | ];
30 | public ulong Base { get; set; }
31 |
32 | public string Id { get; set; }
33 | public static Config Config { get; } = Program.Config;
34 | public Door Door { get; set; }
35 |
36 | private Vector3 _position;
37 | public ref Vector3 Position => ref _position;
38 |
39 | public Switches(ulong ptr)
40 | {
41 | try
42 | {
43 | Base = ptr;
44 | var transformInternal = Memory.ReadPtrChain(Base, _transformInternalChain, false);
45 | var transform = new UnityTransform(transformInternal);
46 |
47 | _position = transform.UpdatePosition();
48 | Id = Memory.ReadUnityString(Memory.ReadPtr(Base + Offsets.Interactable.Id, false));
49 |
50 | var doorPtr = Memory.ReadPtr(Base + 0x178, false);
51 | if (doorPtr != 0x0)
52 | Door = new Door(doorPtr, "Door");
53 | }
54 | catch(Exception e) { MessageBox.Show($"ERROR: Couldn't find switch\n\n{e}"); }
55 |
56 | }
57 |
58 | public void DrawESP(SKCanvas canvas, LocalPlayer localPlayer)
59 | {
60 | var switchPos = _position;
61 |
62 | if(!CameraManager.WorldToScreen(ref switchPos, out var scrPos))
63 | return;
64 |
65 | scrPos.DrawESPText(canvas, this, localPlayer, false, SKPaints.TextBackpackESP, $"Switch\n{Utils.GetDistPretty(Position, localPlayer.Position)}" );
66 | if(Door != null)
67 | {
68 | scrPos.Y += SKPaints.TextBackpackESP.TextSize;
69 | scrPos.DrawESPText(canvas, this, localPlayer, false, SKPaints.TextCorpseESP, $"Door: {Door.KeyName}");
70 | }
71 |
72 | }
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/ArenaPlayer/LocalPlayer.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.ArenaPlayer.Plugins;
2 | using eft_dma_shared.Common.DMA.ScatterAPI;
3 | using eft_dma_shared.Common.DMA;
4 | using eft_dma_shared.Common.Misc.Commercial;
5 | using eft_dma_shared.Common.Players;
6 | using eft_dma_shared.Common.Unity;
7 |
8 | namespace arena_dma_radar.Arena.ArenaPlayer
9 | {
10 | public sealed class LocalPlayer : ArenaClientPlayer, ILocalPlayer
11 | {
12 | ///
13 | /// Magazine information.
14 | ///
15 | public FirearmManager Firearm { get; }
16 | public override string Name { get; }
17 | ///
18 | /// Player is Human-Controlled.
19 | ///
20 | public override bool IsHuman { get; }
21 |
22 | public LocalPlayer(ulong playerBase) : base(playerBase)
23 | {
24 | string classType = ObjectClass.ReadName(this);
25 | if (classType != "ArenaClientPlayer")
26 | throw new ArgumentOutOfRangeException(nameof(classType));
27 | IsHuman = true;
28 | Name = "localPlayer";
29 | this.Firearm = new(this);
30 | ulong id = ulong.Parse(AccountID);
31 | ILocalPlayer.AccountId = id;
32 | }
33 |
34 | ///
35 | /// Additional realtime reads for LocalPlayer.
36 | ///
37 | ///
38 | public override void OnRealtimeLoop(ScatterReadIndex index)
39 | {
40 | index.AddEntry(-11, this.HandsControllerAddr);
41 | index.Callbacks += x1 =>
42 | {
43 | if (x1.TryGetResult(-11, out var handsController))
44 | ILocalPlayer.HandsController = handsController;
45 | };
46 | Firearm.OnRealtimeLoop(index);
47 | base.OnRealtimeLoop(index);
48 | }
49 |
50 | ///
51 | /// Get View Angles for LocalPlayer.
52 | ///
53 | /// View Angles (Vector2).
54 | public Vector2 GetViewAngles() =>
55 | Memory.ReadValue(this.RotationAddress, false);
56 |
57 | ///
58 | /// Checks if LocalPlayer is Aiming (ADS).
59 | ///
60 | /// True if aiming (ADS), otherwise False.
61 | public bool CheckIfADS()
62 | {
63 | try
64 | {
65 | return Memory.ReadValue(this.PWA + Offsets.ProceduralWeaponAnimation._isAiming, false);
66 | }
67 | catch (Exception ex)
68 | {
69 | LoneLogging.WriteLine($"CheckIfADS() ERROR: {ex}");
70 | return false;
71 | }
72 | }
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/FullBright.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Features;
2 | using eft_dma_shared.Common.DMA.ScatterAPI;
3 | using eft_dma_shared.Common.Features;
4 | using eft_dma_shared.Common.Misc.Commercial;
5 | using eft_dma_shared.Common.Unity;
6 |
7 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
8 | {
9 | public sealed class FullBright : MemWriteFeature
10 | {
11 | private bool _set;
12 |
13 | public override bool Enabled
14 | {
15 | get => MemWrites.Config.FullBright;
16 | set => MemWrites.Config.FullBright = value;
17 | }
18 |
19 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(200);
20 |
21 |
22 | public override void TryApply(ScatterWriteHandle writes)
23 | {
24 | try
25 | {
26 | if (Enabled && !_set)
27 | {
28 | var levelSettings = Memory.ReadPtr(MonoLib.LevelSettingsField);
29 |
30 | writes.AddValueEntry(levelSettings + Offsets.LevelSettings.AmbientMode, (int)AmbientMode.Trilight);
31 |
32 | const float brightness = 0.35f; // This is a good level for all maps
33 | var equatorColor = new UnityColor(brightness, brightness, brightness);
34 | var groundColor = new UnityColor(0f, 0f, 0f);
35 | writes.AddValueEntry(levelSettings + Offsets.LevelSettings.EquatorColor, ref equatorColor);
36 | writes.AddValueEntry(levelSettings + Offsets.LevelSettings.GroundColor, ref groundColor);
37 | writes.Callbacks += () =>
38 | {
39 | _set = true;
40 | LoneLogging.WriteLine("FullBright [On]");
41 | };
42 | }
43 | else if (!Enabled && _set)
44 | {
45 | var levelSettings = Memory.ReadPtr(MonoLib.LevelSettingsField);
46 | writes.AddValueEntry(levelSettings + Offsets.LevelSettings.AmbientMode, (int)AmbientMode.Flat);
47 | writes.Callbacks += () =>
48 | {
49 | _set = false;
50 | LoneLogging.WriteLine("FullBright [Off]");
51 | };
52 | }
53 | }
54 | catch (Exception ex)
55 | {
56 | LoneLogging.WriteLine($"ERROR configuring FullBright: {ex}");
57 | }
58 | }
59 |
60 | public override void OnRaidStart()
61 | {
62 | _set = default;
63 | }
64 |
65 | private enum AmbientMode : int
66 | {
67 | Skybox,
68 | Trilight,
69 | Flat = 3,
70 | Custom
71 | }
72 | }
73 | }
74 |
--------------------------------------------------------------------------------
/eft-dma-shared/eft-dma-shared.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net9.0-windows
5 | enable
6 | warnings
7 | True
8 | Debug;Release;Commercial
9 | x64
10 | true
11 |
12 |
13 |
14 | True
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 | none
41 |
42 |
43 |
44 | none
45 |
46 |
47 |
48 | none
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 | ..\VmmFrost.dll
65 |
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/Collections/MemHashSet.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.DMA;
2 | using eft_dma_shared.Common.Misc.Pools;
3 | using System.Runtime.InteropServices;
4 |
5 | namespace eft_dma_shared.Common.Unity.Collections
6 | {
7 | ///
8 | /// DMA Wrapper for a C# HashSet
9 | /// Must initialize before use. Must dispose after use.
10 | ///
11 | /// Collection Type
12 | public sealed class MemHashSet : SharedArray.MemHashEntry>, IPooledObject>
13 | where T : unmanaged
14 | {
15 | public const uint CountOffset = 0x3C;
16 | public const uint ArrOffset = 0x18;
17 | public const uint ArrStartOffset = 0x20;
18 |
19 | ///
20 | /// Get a MemHashSet from the object pool.
21 | ///
22 | /// Base Address for this collection.
23 | /// Perform cached reading.
24 | /// Rented MemHashSet instance.
25 | public static MemHashSet Get(ulong addr, bool useCache = true)
26 | {
27 | var hashSet = IPooledObject>.Rent();
28 | hashSet.Initialize(addr, useCache);
29 | return hashSet;
30 | }
31 |
32 | ///
33 | /// Initializer for Unity HashSet
34 | ///
35 | /// Base Address for this collection.
36 | /// Perform cached reading.
37 | private void Initialize(ulong addr, bool useCache = true)
38 | {
39 | try
40 | {
41 | var count = Memory.ReadValue(addr + CountOffset, useCache);
42 | ArgumentOutOfRangeException.ThrowIfGreaterThan(count, 16384, nameof(count));
43 | Initialize(count);
44 | if (count == 0)
45 | return;
46 | var hashSetBase = Memory.ReadPtr(addr + ArrOffset, useCache) + ArrStartOffset;
47 | Memory.ReadBuffer(hashSetBase, Span, useCache);
48 | }
49 | catch
50 | {
51 | Dispose();
52 | throw;
53 | }
54 | }
55 |
56 | [Obsolete("You must rent this object via IPooledObject!")]
57 | public MemHashSet() : base() { }
58 |
59 | protected override void Dispose(bool disposing)
60 | {
61 | IPooledObject>.Return(this);
62 | }
63 |
64 | [StructLayout(LayoutKind.Sequential, Pack = 1)]
65 | public readonly struct MemHashEntry
66 | {
67 | public static implicit operator T(MemHashEntry x) => x.Value;
68 |
69 | private readonly int _hashCode;
70 | private readonly int _next;
71 | public readonly T Value;
72 | }
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/ColorPicker/ColorPicker.cs:
--------------------------------------------------------------------------------
1 | using DarkModeForms;
2 |
3 | namespace eft_dma_radar.UI.ColorPicker
4 | {
5 | public sealed partial class ColorPicker : Form
6 | where TEnum : Enum
7 | where TClass : ColorItem
8 | {
9 | private readonly Dictionary _colors;
10 | private readonly DarkModeCS _darkmode;
11 | private TEnum _selected;
12 |
13 | ///
14 | /// Form Result.
15 | ///
16 | [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
17 | public Dictionary Result { get; private set; }
18 |
19 | public ColorPicker(string name, IDictionary existing)
20 | {
21 | _colors = new(existing);
22 | InitializeComponent();
23 | _darkmode = new DarkModeCS(this);
24 | PopulateOptions();
25 | if (comboBox_Colors.Items.Count > 0)
26 | comboBox_Colors.SelectedIndex = 0;
27 | this.Text = name;
28 | }
29 |
30 | ///
31 | /// Populate the ESP Color Options list.
32 | ///
33 | private void PopulateOptions()
34 | {
35 |
36 | var enumType = typeof(TEnum);
37 |
38 | foreach (var field in enumType.GetFields(BindingFlags.Public | BindingFlags.Static))
39 | {
40 | var attributes = field.GetCustomAttributes(inherit: false);
41 | if (attributes?.Any(x => x is ObsoleteAttribute) ?? false)
42 | continue;
43 | var value = (TEnum)field.GetValue(null)!;
44 | comboBox_Colors.Items.Add(ColorItem.CreateInstance(value));
45 | }
46 | }
47 |
48 | private void comboBox_Colors_SelectedIndexChanged(object sender, EventArgs e)
49 | {
50 | _selected = ((TClass)comboBox_Colors.SelectedItem)!.Option;
51 | textBox_ColorValue.Text = _colors[_selected];
52 | }
53 |
54 | private void textBox_ColorValue_TextChanged(object sender, EventArgs e)
55 | {
56 | var input = textBox_ColorValue.Text.Trim();
57 | _colors[_selected] = input;
58 | }
59 |
60 | private void button_Edit_Click(object sender, EventArgs e)
61 | {
62 | var dlg = colorDialog1.ShowDialog();
63 | if (dlg is DialogResult.OK)
64 | {
65 | var color = colorDialog1.Color.ToSKColor();
66 | textBox_ColorValue.Text = color.ToString();
67 | }
68 | }
69 |
70 | private void button_Save_Click(object sender, EventArgs e)
71 | {
72 | foreach (var color in _colors)
73 | if (!SKColor.TryParse(color.Value, out var skColor))
74 | throw new Exception($"Invalid Color Value for {color.Key}!");
75 | this.Result = _colors;
76 | this.DialogResult = DialogResult.OK;
77 | }
78 | }
79 | }
--------------------------------------------------------------------------------
/arena-dma-radar/UI/ColorPicker/ColorPicker.cs:
--------------------------------------------------------------------------------
1 | using DarkModeForms;
2 |
3 | namespace arena_dma_radar.UI.ColorPicker
4 | {
5 | public sealed partial class ColorPicker : Form
6 | where TEnum : Enum
7 | where TClass : ColorItem
8 | {
9 | private readonly Dictionary _colors;
10 | private readonly DarkModeCS _darkmode;
11 | private TEnum _selected;
12 |
13 | ///
14 | /// Form Result.
15 | ///
16 | [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
17 | public Dictionary Result { get; private set; }
18 |
19 | public ColorPicker(string name, IDictionary existing)
20 | {
21 | _colors = new(existing);
22 | InitializeComponent();
23 | _darkmode = new DarkModeCS(this);
24 | PopulateOptions();
25 | if (comboBox_Colors.Items.Count > 0)
26 | comboBox_Colors.SelectedIndex = 0;
27 | this.Text = name;
28 | }
29 |
30 | ///
31 | /// Populate the ESP Color Options list.
32 | ///
33 | private void PopulateOptions()
34 | {
35 |
36 | var enumType = typeof(TEnum);
37 |
38 | foreach (var field in enumType.GetFields(BindingFlags.Public | BindingFlags.Static))
39 | {
40 | var attributes = field.GetCustomAttributes(inherit: false);
41 | if (attributes?.Any(x => x is ObsoleteAttribute) ?? false)
42 | continue;
43 | var value = (TEnum)field.GetValue(null)!;
44 | comboBox_Colors.Items.Add(ColorItem.CreateInstance(value));
45 | }
46 | }
47 |
48 | private void comboBox_Colors_SelectedIndexChanged(object sender, EventArgs e)
49 | {
50 | _selected = ((TClass)comboBox_Colors.SelectedItem)!.Option;
51 | textBox_ColorValue.Text = _colors[_selected];
52 | }
53 |
54 | private void textBox_ColorValue_TextChanged(object sender, EventArgs e)
55 | {
56 | var input = textBox_ColorValue.Text.Trim();
57 | _colors[_selected] = input;
58 | }
59 |
60 | private void button_Edit_Click(object sender, EventArgs e)
61 | {
62 | var dlg = colorDialog1.ShowDialog();
63 | if (dlg is DialogResult.OK)
64 | {
65 | var color = colorDialog1.Color.ToSKColor();
66 | textBox_ColorValue.Text = color.ToString();
67 | }
68 | }
69 |
70 | private void button_Save_Click(object sender, EventArgs e)
71 | {
72 | foreach (var color in _colors)
73 | if (!SKColor.TryParse(color.Value, out var skColor))
74 | throw new Exception($"Invalid Color Value for {color.Key}!");
75 | this.Result = _colors;
76 | this.DialogResult = DialogResult.OK;
77 | }
78 | }
79 | }
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/ArenaPlayer/Plugins/GearManager.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Data;
2 | using eft_dma_shared.Common.Unity.Collections;
3 | using System.Collections.Frozen;
4 |
5 | namespace arena_dma_radar.Arena.ArenaPlayer.Plugins
6 | {
7 | public sealed class GearManager
8 | {
9 | private static readonly FrozenSet _skipSlots = new HashSet(StringComparer.OrdinalIgnoreCase)
10 | {
11 | "SecuredContainer", "Dogtag", "Compass", "Eyewear", "ArmBand", "Scabbard"
12 | }.ToFrozenSet(StringComparer.OrdinalIgnoreCase);
13 |
14 | ///
15 | /// List of equipped items in Player Inventory Slots.
16 | ///
17 | public IReadOnlyDictionary Equipment { get; private set; }
18 |
19 | public bool hasBomb = false;
20 |
21 | public GearManager(ArenaObservedPlayer player)
22 | {
23 | var inventorycontroller = Memory.ReadPtr(player.InventoryControllerAddr);
24 | var inventory = Memory.ReadPtr(inventorycontroller + Offsets.InventoryController.Inventory);
25 | var equipment = Memory.ReadPtr(inventory + Offsets.Inventory.Equipment);
26 | var slots = Memory.ReadPtr(equipment + Offsets.Equipment.Slots);
27 | GetGear(slots);
28 | }
29 | private void GetGear(ulong slotsPtr)
30 | {
31 | using var slotsArray = MemArray.Get(slotsPtr);
32 | var gearDict = new Dictionary(StringComparer.OrdinalIgnoreCase);
33 | foreach (var slot in slotsArray)
34 | {
35 | try
36 | {
37 | var namePtr = Memory.ReadPtr(slot + Offsets.Slot.ID);
38 | if (namePtr == 0x0) continue;
39 | var name = Memory.ReadUnityString(namePtr);
40 | if (_skipSlots.Contains(name))
41 | continue;
42 | var containedItem = Memory.ReadPtr(slot + Offsets.Slot.ContainedItem);
43 | if(containedItem == 0x0) continue;
44 | var inventorytemplate = Memory.ReadPtr(containedItem + Offsets.LootItem.Template);
45 | if (inventorytemplate == 0x0) continue;
46 | var idPtr = Memory.ReadValue(inventorytemplate + Offsets.ItemTemplate._id);
47 | string id = Memory.ReadUnityString(idPtr.StringID);
48 | if (id.Equals("6669a73bef0f6220df0ed178"))
49 | {
50 | gearDict.TryAdd(name, "BlastGang attacker's backpack");
51 | continue;
52 | }
53 |
54 | if (EftDataManager.AllItems.TryGetValue(id, out var entry))
55 | gearDict.TryAdd(name, entry.Name);
56 |
57 | }
58 | catch { } // Skip over empty slots
59 | }
60 | Equipment = gearDict; // update readonly ref
61 | }
62 | }
63 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Maps/LoneMapManager.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc;
2 | using System.Collections.Frozen;
3 | using System.IO.Compression;
4 | using System.Text.Json;
5 |
6 | namespace eft_dma_shared.Common.Maps
7 | {
8 | ///
9 | /// Maintains Map Resources for this application.
10 | ///
11 | public static class LoneMapManager
12 | {
13 | private static readonly Lock _sync = new();
14 | private static ZipArchive _zip;
15 | private static FrozenDictionary _maps;
16 |
17 | ///
18 | /// Currently Loaded Map.
19 | ///
20 | public static ILoneMap Map { get; private set; }
21 |
22 | ///
23 | /// Initialize this Module.
24 | /// ONLY CALL ONCE!
25 | ///
26 | public static void ModuleInit()
27 | {
28 | const string mapsPath = "Maps.bin";
29 | try
30 | {
31 | /// Load Maps
32 | var mapsStream = FileCrypt.OpenEncryptedFile(mapsPath) ??
33 | throw new Exception($"Failed to load Maps Bundle '{mapsPath}'");
34 | var zip = new ZipArchive(mapsStream, ZipArchiveMode.Read, false);
35 | var mapsBuilder = new Dictionary(StringComparer.OrdinalIgnoreCase);
36 | foreach (var file in zip.Entries)
37 | {
38 | if (file.Name.EndsWith(".json", StringComparison.OrdinalIgnoreCase))
39 | {
40 | using var stream = file.Open();
41 | var config = JsonSerializer.Deserialize(stream);
42 | foreach (var id in config!.MapID)
43 | mapsBuilder.Add(id, config);
44 | }
45 | }
46 | _maps = mapsBuilder.ToFrozenDictionary(StringComparer.OrdinalIgnoreCase);
47 | _zip = zip;
48 | }
49 | catch (Exception ex)
50 | {
51 | throw new ApplicationException("Failed to Initialize Maps!", ex);
52 | }
53 | }
54 |
55 | ///
56 | /// Update the current map and load resources into Memory.
57 | ///
58 | /// Id of map to load.
59 | ///
60 | ///
61 | public static void LoadMap(string mapId)
62 | {
63 | lock (_sync)
64 | {
65 | try
66 | {
67 | if (!_maps.TryGetValue(mapId, out var newMap))
68 | newMap = _maps["default"];
69 | Map?.Dispose();
70 | Map = null;
71 | Map = new LoneSvgMap(_zip, mapId, newMap);
72 | }
73 | catch (Exception ex)
74 | {
75 | throw new Exception($"ERROR loading '{mapId}'", ex);
76 | }
77 | }
78 | }
79 | }
80 | }
81 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/GameWorld/Explosives/MortarProjectile.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_radar.UI.ESP;
3 | using eft_dma_radar.UI.Misc;
4 | using eft_dma_radar.UI.Radar;
5 | using eft_dma_shared.Common.ESP;
6 | using eft_dma_shared.Common.Maps;
7 | using eft_dma_shared.Common.Players;
8 | using eft_dma_shared.Common.Unity;
9 |
10 | namespace eft_dma_radar.Tarkov.GameWorld.Explosives
11 | {
12 | public sealed class MortarProjectile : IExplosiveItem
13 | {
14 | public static implicit operator ulong(MortarProjectile x) => x.Addr;
15 | private readonly ConcurrentDictionary _parent;
16 |
17 | public MortarProjectile(ulong baseAddr, ConcurrentDictionary parent)
18 | {
19 | _parent = parent;
20 | this.Addr = baseAddr;
21 | this.Refresh();
22 | if (!this.IsActive)
23 | {
24 | throw new Exception("Already exploded!");
25 | }
26 | }
27 |
28 | public ulong Addr { get; }
29 |
30 | public bool IsActive { get; private set; }
31 |
32 | private Vector3 _position;
33 | public ref Vector3 Position => ref _position;
34 |
35 | public void Draw(SKCanvas canvas, LoneMapParams mapParams, ILocalPlayer localPlayer)
36 | {
37 | if (!IsActive)
38 | return;
39 | var circlePosition = Position.ToMapPos(mapParams.Map).ToZoomedPos(mapParams);
40 | var size = 5 * MainForm.UIScale;
41 | SKPaints.ShapeOutline.StrokeWidth = SKPaints.PaintExplosives.StrokeWidth + 2f * MainForm.UIScale;
42 | canvas.DrawCircle(circlePosition, size, SKPaints.ShapeOutline); // Draw outline
43 | canvas.DrawCircle(circlePosition, size, SKPaints.PaintExplosives); // draw LocalPlayer marker
44 | }
45 |
46 | public void DrawESP(SKCanvas canvas, LocalPlayer localPlayer)
47 | {
48 | if (!IsActive)
49 | return;
50 | if (!CameraManagerBase.WorldToScreen(ref _position, out var scrPos))
51 | return;
52 | var circleRadius = 8f * ESP.Config.LineScale;
53 | canvas.DrawCircle(scrPos, circleRadius, SKPaints.PaintGrenadeESP);
54 | }
55 |
56 | public void Refresh()
57 | {
58 | var artilleryProjectile = Memory.ReadValue(this, false);
59 | this.IsActive = artilleryProjectile.IsActive;
60 | if (this.IsActive)
61 | {
62 | _position = artilleryProjectile.Position;
63 | }
64 | else
65 | {
66 | _parent.TryRemove(this, out _);
67 | }
68 | }
69 |
70 | [StructLayout(LayoutKind.Explicit, Pack = 1)]
71 | private readonly struct ArtilleryProjectile
72 | {
73 | [FieldOffset((int)Offsets.ArtilleryProjectileClient.Position)]
74 | public readonly Vector3 Position;
75 | [FieldOffset((int)Offsets.ArtilleryProjectileClient.IsActive)]
76 | public readonly bool IsActive;
77 | }
78 | }
79 | }
80 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Data/LootFilterEntry.cs:
--------------------------------------------------------------------------------
1 | using SkiaSharp;
2 | using System.Text.Json.Serialization;
3 |
4 | namespace eft_dma_shared.Common.Misc.Data
5 | {
6 | ///
7 | /// JSON Wrapper for Important Loot.
8 | ///
9 | public sealed class LootFilterEntry
10 | {
11 | [JsonIgnore]
12 | public static readonly IReadOnlyList Types = new List()
13 | {
14 | new()
15 | {
16 | Id = 0,
17 | Name = "Important Loot"
18 | },
19 | new()
20 | {
21 | Id = 1,
22 | Name = "Blacklisted Loot"
23 | }
24 | };
25 | ///
26 | /// Item's BSG ID.
27 | ///
28 | [JsonPropertyName("itemID")]
29 | public string ItemID { get; set; } = string.Empty;
30 | ///
31 | /// True if this entry is Enabled/Active.
32 | ///
33 | [JsonPropertyName("enabled")]
34 | public bool Enabled { get; set; } = true;
35 | ///
36 | /// Entry Type.
37 | /// 0 = Important Loot
38 | /// 1 = Blacklisted Loot
39 | ///
40 | [JsonPropertyName("type")]
41 | public int Type { get; set; } = 0;
42 | ///
43 | /// True if this filter represents an Important Item.
44 | ///
45 | [JsonIgnore]
46 | public bool Important => Type == 0;
47 | ///
48 | /// True if this filter represents a Blacklisted Item.
49 | ///
50 | [JsonIgnore]
51 | public bool Blacklisted => Type == 1;
52 | [JsonIgnore]
53 | private string _name;
54 | ///
55 | /// Item Long Name per Tarkov Market.
56 | ///
57 | [JsonIgnore]
58 | public string Name
59 | {
60 | get
61 | {
62 | _name ??= EftDataManager.AllItems?
63 | .FirstOrDefault(x => x.Key.Equals(ItemID, StringComparison.OrdinalIgnoreCase))
64 | .Value?.Name;
65 | return _name ?? "NULL";
66 | }
67 | }
68 | ///
69 | /// Entry Comment (name of item,etc.)
70 | ///
71 | [JsonPropertyName("comment")]
72 | public string Comment { get; set; } = string.Empty;
73 | ///
74 | /// Hex value of the rgba color.
75 | ///
76 | [JsonPropertyName("color")]
77 | public string Color { get; set; } = SKColors.Turquoise.ToString();
78 |
79 | public sealed class EntryType
80 | {
81 | ///
82 | /// Entry Type.
83 | /// 0 = Important Loot
84 | /// 1 = Blacklisted Loot
85 | ///
86 | public int Id { get; init; }
87 | ///
88 | /// Type Name.
89 | ///
90 | public string Name { get; init; }
91 |
92 | public override string ToString() => Name;
93 | }
94 | }
95 | }
96 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Unity/Collections/MemDictionary.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using eft_dma_shared.Common.Misc.Pools;
3 | using System.Runtime.InteropServices;
4 |
5 | namespace eft_dma_shared.Common.Unity.Collections
6 | {
7 | ///
8 | /// DMA Wrapper for a C# Dictionary
9 | /// Must initialize before use. Must dispose after use.
10 | ///
11 | /// Key Type between 1-8 bytes.
12 | /// Value Type between 1-8 bytes.
13 | public sealed class MemDictionary : SharedArray.MemDictEntry>, IPooledObject>
14 | where TKey : unmanaged
15 | where TValue : unmanaged
16 | {
17 | public const uint CountOffset = 0x40;
18 | public const uint EntriesOffset = 0x18;
19 | public const uint EntriesStartOffset = 0x20;
20 |
21 | ///
22 | /// Get a MemDictionary , from the object pool.
23 | ///
24 | /// Base Address for this collection.
25 | /// Perform cached reading.
26 | /// Rented MemDictionary / instance.
27 | public static MemDictionary Get(ulong addr, bool useCache = true)
28 | {
29 | var dict = IPooledObject>.Rent();
30 | dict.Initialize(addr, useCache);
31 | return dict;
32 | }
33 |
34 | ///
35 | /// Initializer for Unity Dictionary
36 | ///
37 | /// Base Address for this collection.
38 | /// Perform cached reading.
39 | private void Initialize(ulong addr, bool useCache = true)
40 | {
41 | try
42 | {
43 | var count = Memory.ReadValue(addr + CountOffset, useCache);
44 | ArgumentOutOfRangeException.ThrowIfGreaterThan(count, 16384, nameof(count));
45 | Initialize(count);
46 | if (count == 0)
47 | return;
48 | var dictBase = Memory.ReadPtr(addr + EntriesOffset, useCache) + EntriesStartOffset;
49 | Memory.ReadBuffer(dictBase, Span, useCache); // Single read into mem buffer
50 | }
51 | catch
52 | {
53 | Dispose();
54 | throw;
55 | }
56 | }
57 |
58 | [Obsolete("You must rent this object via IPooledObject!")]
59 | public MemDictionary() : base() { }
60 |
61 | protected override void Dispose(bool disposing)
62 | {
63 | IPooledObject>.Return(this);
64 | }
65 |
66 | [StructLayout(LayoutKind.Sequential, Pack = 8)]
67 | public readonly struct MemDictEntry
68 | {
69 | private readonly ulong _pad00;
70 | public readonly TKey Key;
71 | public readonly TValue Value;
72 | }
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/eft-dma-radar/UI/Misc/InputBox.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace eft_dma_radar.UI.Misc
2 | {
3 | partial class InputBox
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | ComponentResourceManager resources = new ComponentResourceManager(typeof(InputBox));
32 | button_OK = new Button();
33 | label_Prompt = new Label();
34 | textBox_Input = new TextBox();
35 | SuspendLayout();
36 | //
37 | // button_OK
38 | //
39 | button_OK.Location = new Point(482, 39);
40 | button_OK.Name = "button_OK";
41 | button_OK.Size = new Size(75, 23);
42 | button_OK.TabIndex = 0;
43 | button_OK.Text = "OK";
44 | button_OK.UseVisualStyleBackColor = true;
45 | button_OK.Click += button_OK_Click;
46 | //
47 | // label_Prompt
48 | //
49 | label_Prompt.AutoSize = true;
50 | label_Prompt.Location = new Point(12, 21);
51 | label_Prompt.Name = "label_Prompt";
52 | label_Prompt.Size = new Size(47, 15);
53 | label_Prompt.TabIndex = 1;
54 | label_Prompt.Text = "Prompt";
55 | //
56 | // textBox_Input
57 | //
58 | textBox_Input.Location = new Point(12, 39);
59 | textBox_Input.MaxLength = 512;
60 | textBox_Input.Name = "textBox_Input";
61 | textBox_Input.Size = new Size(450, 23);
62 | textBox_Input.TabIndex = 2;
63 | //
64 | // InputBox
65 | //
66 | AutoScaleDimensions = new SizeF(7F, 15F);
67 | AutoScaleMode = AutoScaleMode.Font;
68 | ClientSize = new Size(607, 107);
69 | Controls.Add(textBox_Input);
70 | Controls.Add(label_Prompt);
71 | Controls.Add(button_OK);
72 | Icon = (Icon)resources.GetObject("$this.Icon");
73 | MaximizeBox = false;
74 | MinimizeBox = false;
75 | Name = "InputBox";
76 | Text = "Input Box";
77 | TopMost = true;
78 | ResumeLayout(false);
79 | PerformLayout();
80 | }
81 |
82 | #endregion
83 |
84 | private Button button_OK;
85 | private Label label_Prompt;
86 | private TextBox textBox_Input;
87 | }
88 | }
--------------------------------------------------------------------------------
/eft-dma-radar/UI/LootFilters/LootFilter.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.Loot;
2 | using eft_dma_radar.UI.Radar;
3 |
4 | namespace eft_dma_radar.UI.LootFilters
5 | {
6 | ///
7 | /// Enumerable Loot Filter Class.
8 | ///
9 | internal static class LootFilter
10 | {
11 | public static string SearchString;
12 | public static bool ShowMeds;
13 | public static bool ShowFood;
14 | public static bool ShowBackpacks;
15 | public static bool ShowWishlist;
16 | public static bool ShowImportant;
17 |
18 | private static bool ShowQuestItems => MainForm.Config.QuestHelper.Enabled;
19 |
20 | ///
21 | /// Creates a loot filter based on current Loot Filter settings.
22 | ///
23 | /// Loot Filter Predicate.
24 | public static Predicate Create()
25 | {
26 | var search = SearchString?.Trim();
27 | bool usePrices = string.IsNullOrEmpty(search);
28 | if (usePrices)
29 | {
30 | Predicate p = (x) => // Default Predicate
31 | {
32 | return (x.IsRegularLoot || x.IsValuableLoot || x.IsImportant || x.IsWishlisted) ||
33 | (ShowQuestItems && x.IsQuestCondition) ||
34 | (LootFilter.ShowBackpacks && x.IsBackpack) ||
35 | (LootFilter.ShowMeds && x.IsMeds) ||
36 | (LootFilter.ShowFood && x.IsFood);
37 | };
38 | return (item) =>
39 | {
40 | if (item is LootAirdrop airdrop)
41 | {
42 | return true;
43 | }
44 | if (item is LootCorpse corpse)
45 | {
46 | return true;
47 | }
48 | if (p(item))
49 | {
50 | if (item is LootContainer container)
51 | {
52 | container.SetFilter(p);
53 | }
54 | return true;
55 | }
56 | return false;
57 | };
58 | }
59 | else // Loot Search
60 | {
61 | var names = search!.Split(',').Select(a => a.Trim()).ToArray();
62 | Predicate p = (x) => // Search Predicate
63 | {
64 | return names.Any(a => x.Name.Contains(a, StringComparison.OrdinalIgnoreCase));
65 | };
66 | return (item) =>
67 | {
68 | if (item is LootAirdrop airdrop)
69 | {
70 | return true;
71 | }
72 | if (item.ContainsSearchPredicate(p))
73 | {
74 | if (item is LootContainer container)
75 | {
76 | container.SetFilter(p);
77 | }
78 | return true;
79 | }
80 | return false;
81 | };
82 | }
83 | }
84 | }
85 | }
--------------------------------------------------------------------------------
/arena-dma-radar/arena-dma-radar.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | WinExe
5 | net9.0-windows
6 | LonesArenaRadar
7 | warnings
8 | true
9 | enable
10 | True
11 | x64
12 | Debug;Release
13 | PerMonitorV2
14 | false
15 | ..\Resources\kek-icon.ico
16 | true
17 | true
18 | true
19 |
20 |
21 | none
22 |
23 |
24 | none
25 |
26 |
27 |
28 |
29 | PreserveNewest
30 |
31 |
32 | PreserveNewest
33 |
34 |
35 | PreserveNewest
36 |
37 |
38 | PreserveNewest
39 |
40 |
41 | PreserveNewest
42 |
43 |
44 | PreserveNewest
45 |
46 |
47 | PreserveNewest
48 |
49 |
50 | PreserveNewest
51 |
52 |
53 | PreserveNewest
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 | ..\VmmFrost.dll
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Features/MemoryWrites/NoRecoil.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.ArenaPlayer;
2 | using arena_dma_radar.Arena.Features;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Features;
5 | using eft_dma_shared.Common.Misc.Commercial;
6 |
7 | namespace arena_dma_radar.Arena.Features.MemoryWrites
8 | {
9 | public sealed class NoRecoil : MemWriteFeature
10 | {
11 | public override bool Enabled
12 | {
13 | get => MemWrites.Config.NoRecoil;
14 | set => MemWrites.Config.NoRecoil = value;
15 | }
16 |
17 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(20);
18 |
19 | public override void TryApply(ScatterWriteHandle writes)
20 | {
21 | try
22 | {
23 | if (Enabled && Memory.LocalPlayer is LocalPlayer localPlayer)
24 | {
25 | float recoilAmt = MemWrites.Config.NoRecoilAmount / 100f;
26 | float newSway = MemWrites.Config.NoSwayAmount / 100f;
27 |
28 | Vector3 newRecoil = new Vector3(recoilAmt, recoilAmt, recoilAmt);
29 | var breathEff = Memory.ReadPtr(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.Breath);
30 | var shotEff = Memory.ReadPtr(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.Shootingg);
31 | var newShotRecoil = Memory.ReadPtr(shotEff + Offsets.ShotEffector.NewShotRecoil);
32 | var breathAmt = Memory.ReadValue(breathEff + Offsets.BreathEffector.Intensity, false);
33 | var shotAmt = Memory.ReadValue(newShotRecoil + Offsets.NewShotRecoil.IntensitySeparateFactors, false);
34 | ValidateSway(breathAmt);
35 | ValidateRecoil(shotAmt);
36 | if (breathAmt != newSway)
37 | {
38 | writes.AddValueEntry(breathEff + Offsets.BreathEffector.Intensity, newSway);
39 | LoneLogging.WriteLine($"NoRecoil BreathEffector {breathAmt} -> {newSway}");
40 | }
41 | if (shotAmt != newRecoil)
42 | {
43 | writes.AddValueEntry(newShotRecoil + Offsets.NewShotRecoil.IntensitySeparateFactors, newRecoil);
44 | LoneLogging.WriteLine($"NoRecoil ShotEffector {shotAmt} -> {newRecoil}");
45 | }
46 | }
47 | }
48 | catch (Exception ex)
49 | {
50 | LoneLogging.WriteLine($"ERROR configuring Reduced Recoil/Sway: {ex}");
51 | }
52 | static void ValidateSway(float amount)
53 | {
54 | if (amount < 0f || amount > 5f)
55 | throw new ArgumentOutOfRangeException(nameof(amount));
56 | }
57 | static void ValidateRecoil(Vector3 amount)
58 | {
59 | if (amount.X < 0f || amount.X > 1f)
60 | throw new ArgumentOutOfRangeException(nameof(amount));
61 | if (amount.Y < 0f || amount.Y > 1f)
62 | throw new ArgumentOutOfRangeException(nameof(amount));
63 | if (amount.Z < 0f || amount.Z > 1f)
64 | throw new ArgumentOutOfRangeException(nameof(amount));
65 | }
66 | }
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/MoveSpeed.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_radar.Tarkov.Features;
3 | using eft_dma_shared.Common.DMA.ScatterAPI;
4 | using eft_dma_shared.Common.Features;
5 | using eft_dma_shared.Common.Misc.Commercial;
6 | using eft_dma_shared.Common.Unity;
7 | using eft_dma_shared.Common.Unity.Collections;
8 |
9 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
10 | {
11 | public sealed class MoveSpeed : MemWriteFeature
12 | {
13 | private bool _set = false;
14 |
15 | public override bool Enabled
16 | {
17 | get => MemWrites.Config.MoveSpeed;
18 | set => MemWrites.Config.MoveSpeed = value;
19 | }
20 |
21 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(100);
22 |
23 |
24 | public override void TryApply(ScatterWriteHandle writes)
25 | {
26 | const float baseSpeed = 1.0f;
27 | const float increasedSpeed = 1.2f; // Any higher risks a ban
28 | try
29 | {
30 | if (Memory.LocalPlayer is LocalPlayer localPlayer)
31 | {
32 | bool enabled = Enabled;
33 | if (enabled && !_set)
34 | {
35 | var pAnimators = Memory.ReadPtr(localPlayer + Offsets.Player._animators);
36 | using var animators = MemArray.Get(pAnimators);
37 | var a = Memory.ReadPtrChain(animators[0], new uint[] { Offsets.BodyAnimator.UnityAnimator, ObjectClass.MonoBehaviourOffset });
38 | var current = Memory.ReadValue(a + UnityOffsets.UnityAnimator.Speed, false);
39 | ValidateSpeed(current);
40 | Memory.WriteValueEnsure(a + UnityOffsets.UnityAnimator.Speed, increasedSpeed);
41 | _set = true;
42 | LoneLogging.WriteLine("Move Speed [On]");
43 | }
44 | else if (!enabled && _set)
45 | {
46 | var pAnimators = Memory.ReadPtr(localPlayer + Offsets.Player._animators);
47 | using var animators = MemArray.Get(pAnimators);
48 | var a = Memory.ReadPtrChain(animators[0], new uint[] { Offsets.BodyAnimator.UnityAnimator, ObjectClass.MonoBehaviourOffset });
49 | var current = Memory.ReadValue(a + UnityOffsets.UnityAnimator.Speed, false);
50 | ValidateSpeed(current);
51 | Memory.WriteValueEnsure(a + UnityOffsets.UnityAnimator.Speed, baseSpeed);
52 | _set = false;
53 | LoneLogging.WriteLine("Move Speed [Off]");
54 | }
55 | }
56 | }
57 | catch (Exception ex)
58 | {
59 | LoneLogging.WriteLine($"ERROR Setting Move Speed: {ex}");
60 | }
61 | static void ValidateSpeed(float speed)
62 | {
63 | if (!float.IsNormal(speed) || speed < baseSpeed - 0.2f || speed > increasedSpeed + 0.2f)
64 | throw new ArgumentOutOfRangeException(nameof(speed));
65 | }
66 | }
67 |
68 | public override void OnRaidStart()
69 | {
70 | _set = default;
71 | }
72 | }
73 | }
74 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/Pools/IPooledObject.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using System.Collections.Concurrent;
3 | using System.Runtime.CompilerServices;
4 |
5 | namespace eft_dma_shared.Common.Misc.Pools
6 | {
7 | ///
8 | /// Interface devinces a class object that can be rented from an Object Pool for improved allocation performance.
9 | /// Guidelines:
10 | /// (1) Apply the IPooledObject interface to the class object.
11 | /// (2) The class must contain a parameterless public constructor. It's recommended to set [Obsolete] parameter on this constructor, and use a static factory method.
12 | /// (3) The Dispose method should call IPooledObject.Return(T obj) to return the object to the pool.
13 | /// (4) The Dispose method should never be called more than once, or undefined behavior may occur.
14 | /// (5) SetDefault *must* reset the object state back to it's default state, or undefined behavior may occur.
15 | /// (6) Make sure you do not store references to the object after it has been returned to the pool, or undefined behavior may occur.
16 | ///
17 | /// Class Type
18 | public interface IPooledObject : IDisposable
19 | where T : class, IPooledObject
20 | {
21 | ///
22 | /// Defines a method that will reset the object state back to it's default state, so it can be rented out again.
23 | /// ***Called Internally by the Object Pool on Disposal.***
24 | ///
25 | void SetDefault();
26 |
27 | #region Static Members
28 | ///
29 | /// Rent an object from the Object Pool.
30 | ///
31 | /// Pool object.
32 | static T Rent()
33 | {
34 | return ObjectPool.Rent();
35 | }
36 |
37 | ///
38 | /// Return an object back to the Object Pool.
39 | ///
40 | /// Pool Object to return.
41 | static void Return(T obj)
42 | {
43 | if (obj is IPooledObject pooledObj)
44 | {
45 | pooledObj.SetDefault();
46 | ObjectPool.Return(obj); // Return the base type not the interface type
47 | }
48 | else
49 | {
50 | LoneLogging.WriteLine($"CRITICAL ERROR: Unable to return '{obj.GetType()}' object to the ObjectPool!");
51 | }
52 | }
53 |
54 | private static class ObjectPool
55 | {
56 | private static readonly ConcurrentBag _objectPool = new();
57 |
58 | [MethodImpl(MethodImplOptions.AggressiveInlining)]
59 | internal static T Rent()
60 | {
61 | if (_objectPool.TryTake(out var obj))
62 | {
63 | return obj;
64 | }
65 | else
66 | {
67 | //LoneLogging.WriteLine($"{DateTime.UtcNow.Ticks}: New Pool Obj {typeof(T)}");
68 | return Activator.CreateInstance();
69 | }
70 | }
71 |
72 | [MethodImpl(MethodImplOptions.AggressiveInlining)]
73 | internal static void Return(T obj)
74 | {
75 | _objectPool.Add(obj);
76 | }
77 | }
78 | #endregion
79 | }
80 | }
81 |
--------------------------------------------------------------------------------
/eft-dma-radar/eft-dma-radar.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | WinExe
4 | net9.0-windows
5 | LonesEFTRadar
6 | warnings
7 | true
8 | enable
9 | True
10 | x64
11 | Debug;Release
12 | PerMonitorV2
13 | false
14 | ..\Resources\kek-icon.ico
15 | true
16 | true
17 | true
18 |
19 |
20 | none
21 |
22 |
23 | none
24 |
25 |
26 |
27 |
28 | PreserveNewest
29 |
30 |
31 | PreserveNewest
32 |
33 |
34 | PreserveNewest
35 |
36 |
37 | PreserveNewest
38 |
39 |
40 | PreserveNewest
41 |
42 |
43 | PreserveNewest
44 |
45 |
46 | PreserveNewest
47 |
48 |
49 | PreserveNewest
50 |
51 |
52 | PreserveNewest
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 | ..\VmmFrost.dll
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Features/MemPatchFeature.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc;
2 | using eft_dma_shared.Common.Misc.Commercial;
3 | using System.Diagnostics;
4 |
5 | namespace eft_dma_shared.Common.Features
6 | {
7 | public abstract class MemPatchFeature : IFeature, IMemPatchFeature
8 | where T : IMemPatchFeature
9 | {
10 | ///
11 | /// Singleton Instance.
12 | ///
13 | public static T Instance { get; }
14 |
15 | private readonly Stopwatch _sw = Stopwatch.StartNew();
16 |
17 | static MemPatchFeature()
18 | {
19 | Instance = Activator.CreateInstance();
20 | IFeature.Register(Instance);
21 | }
22 |
23 | public virtual bool Enabled { get; set; }
24 |
25 | public virtual bool CanRun
26 | {
27 | get
28 | {
29 | if (!Memory.Ready || !Enabled)
30 | return false;
31 | if (!DelayElapsed)
32 | return false;
33 | return true;
34 | }
35 | }
36 |
37 | public bool IsApplied { get; protected set; }
38 |
39 | protected virtual TimeSpan Delay => TimeSpan.FromSeconds(3);
40 |
41 | protected bool DelayElapsed => Delay == TimeSpan.Zero || _sw.Elapsed >= Delay;
42 |
43 | protected virtual Func GetPFunc => throw new NotImplementedException();
44 |
45 | protected virtual int PFuncSize => throw new NotImplementedException();
46 |
47 | protected virtual byte[] Signature => throw new NotImplementedException();
48 |
49 | protected virtual byte[] Patch => throw new NotImplementedException();
50 |
51 | protected virtual string Mask { get; }
52 |
53 | ///
54 | /// Try apply this patch (does not throw).
55 | /// No-op if already applied.
56 | ///
57 | /// True if applied OK (or already applied), otherwise False.
58 | public virtual bool TryApply()
59 | {
60 | if (IsApplied)
61 | return true;
62 | try
63 | {
64 | var pFuncBase = GetPFunc();
65 | var method = new byte[PFuncSize];
66 | Memory.ReadBuffer(pFuncBase, method.AsSpan(), false);
67 | int sigIndex = method.FindSignatureOffset(Signature, Mask);
68 | if (sigIndex != -1)
69 | {
70 | Memory.WriteBufferEnsure(pFuncBase + (uint)sigIndex, Patch.AsSpan());
71 | LoneLogging.WriteLine($"MemPatch {GetType().ToString()} Applied!");
72 | return IsApplied = true;
73 | }
74 | else if (method.FindSignatureOffset(Patch) != -1)
75 | {
76 | LoneLogging.WriteLine($"MemPatch {GetType().ToString()} Already Set!");
77 | return IsApplied = true;
78 | }
79 | }
80 | catch (Exception ex)
81 | {
82 | LoneLogging.WriteLine($"ERROR Applying Patch {GetType().ToString()}: {ex}");
83 | }
84 | return false;
85 | }
86 |
87 | public void OnApply()
88 | {
89 | if (Delay != TimeSpan.Zero)
90 | {
91 | _sw.Restart();
92 | }
93 | }
94 |
95 | public virtual void OnGameStart()
96 | {
97 | }
98 |
99 | public virtual void OnRaidStart()
100 | {
101 | }
102 |
103 | public virtual void OnRaidEnd()
104 | {
105 | }
106 |
107 | public virtual void OnGameStop()
108 | {
109 | }
110 | }
111 | }
--------------------------------------------------------------------------------
/eft-dma-shared/Common/Misc/ResourceJanitor.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_shared.Common.Misc.Commercial;
2 | using System.Runtime;
3 | using System.Runtime.InteropServices;
4 |
5 | namespace eft_dma_shared.Common
6 | {
7 | public static partial class ResourceJanitor
8 | {
9 | private static readonly Lock _sync = new();
10 | private static Action _cleanupFunction;
11 |
12 | public static void ModuleInit(Action cleanupFunction)
13 | {
14 | _cleanupFunction = cleanupFunction;
15 | new Thread(Worker)
16 | {
17 | Priority = ThreadPriority.Lowest,
18 | IsBackground = true
19 | }.Start();
20 | }
21 |
22 | private static void Worker()
23 | {
24 | while (true)
25 | {
26 | try
27 | {
28 | var info = new MEMORYSTATUSEX();
29 | if (GlobalMemoryStatusEx(ref info) && info.dwMemoryLoad >= 90) // Over 90% memory usage
30 | {
31 | LoneLogging.WriteLine("[ResourceJanitor] High Memory Load, running cleanup...");
32 | Run(false);
33 | }
34 | }
35 | catch { }
36 | finally { Thread.Sleep(TimeSpan.FromSeconds(5)); }
37 | }
38 | }
39 |
40 | ///
41 | /// Runs resource cleanup on the app.
42 | ///
43 | public static void Run(bool aggressive = true)
44 | {
45 | lock (_sync)
46 | {
47 | try
48 | {
49 | _cleanupFunction?.Invoke();
50 | if (aggressive)
51 | {
52 | GCSettings.LargeObjectHeapCompactionMode = GCLargeObjectHeapCompactionMode.CompactOnce;
53 | GC.Collect(
54 | generation: GC.MaxGeneration,
55 | mode: GCCollectionMode.Aggressive,
56 | blocking: true,
57 | compacting: true);
58 | }
59 | else
60 | {
61 | GC.Collect(
62 | generation: GC.MaxGeneration,
63 | mode: GCCollectionMode.Optimized,
64 | blocking: false,
65 | compacting: false);
66 | }
67 | }
68 | catch (Exception ex)
69 | {
70 | LoneLogging.WriteLine($"ResourceJanitor ERROR: {ex}");
71 | }
72 | }
73 | }
74 |
75 | #region Native Interop
76 | [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Auto)]
77 | private readonly struct MEMORYSTATUSEX
78 | {
79 | public readonly uint dwLength;
80 | public readonly uint dwMemoryLoad;
81 | public readonly ulong ullTotalPhys;
82 | public readonly ulong ullAvailPhys;
83 | public readonly ulong ullTotalPageFile;
84 | public readonly ulong ullAvailPageFile;
85 | public readonly ulong ullTotalVirtual;
86 | public readonly ulong ullAvailVirtual;
87 | public readonly ulong ullAvailExtendedVirtual;
88 |
89 | public MEMORYSTATUSEX()
90 | {
91 | this.dwLength = (uint)Marshal.SizeOf();
92 | }
93 | }
94 |
95 | [LibraryImport("kernel32.dll")]
96 | [return: MarshalAs(UnmanagedType.Bool)]
97 | private static partial bool GlobalMemoryStatusEx(ref MEMORYSTATUSEX lpBuffer);
98 | #endregion
99 | }
100 | }
101 |
--------------------------------------------------------------------------------
/eft-dma-radar/Tarkov/Features/MemoryWrites/WideLean.cs:
--------------------------------------------------------------------------------
1 | using eft_dma_radar.Tarkov.EFTPlayer;
2 | using eft_dma_radar.Tarkov.Features;
3 | using eft_dma_radar.UI.Misc;
4 | using eft_dma_shared.Common.DMA.ScatterAPI;
5 | using eft_dma_shared.Common.Features;
6 | using eft_dma_shared.Common.Misc.Commercial;
7 |
8 | namespace eft_dma_radar.Tarkov.Features.MemoryWrites
9 | {
10 | public sealed class WideLean : MemWriteFeature
11 | {
12 | public static EWideLeanDirection Direction = EWideLeanDirection.Off;
13 | private bool _set = false;
14 |
15 | public override bool Enabled
16 | {
17 | get => MemWrites.Config.WideLean.Enabled;
18 | set => MemWrites.Config.WideLean.Enabled = value;
19 | }
20 |
21 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(100);
22 |
23 |
24 | ///
25 | /// Wide Lean Config.
26 | ///
27 | public static WideLeanConfig Config { get; } = MemWrites.Config.WideLean;
28 |
29 | public override void TryApply(ScatterWriteHandle writes)
30 | {
31 | try
32 | {
33 | if (Memory.LocalPlayer is LocalPlayer localPlayer)
34 | {
35 | var dir = Direction;
36 | if (Enabled && dir is not EWideLeanDirection.Off && !_set)
37 | {
38 | float amt = Config.Amount * .01f * 0.2f;
39 | switch (dir)
40 | {
41 | case EWideLeanDirection.Left:
42 | var left = new Vector3(-amt, 0f, 0f);
43 | writes.AddValueEntry(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.PositionZeroSum, ref left);
44 | break;
45 | case EWideLeanDirection.Right:
46 | var right = new Vector3(amt, 0f, 0f);
47 | writes.AddValueEntry(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.PositionZeroSum, ref right);
48 | break;
49 | case EWideLeanDirection.Up:
50 | var up = new Vector3(0f, 0f, amt);
51 | writes.AddValueEntry(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.PositionZeroSum, ref up);
52 | break;
53 | default:
54 | throw new InvalidOperationException("Invalid wide lean option");
55 | }
56 | writes.Callbacks += () =>
57 | {
58 | _set = true;
59 | LoneLogging.WriteLine("Wide Lean [On]");
60 | };
61 | }
62 | else if (_set && dir is EWideLeanDirection.Off)
63 | {
64 | var off = Vector3.Zero;
65 | writes.AddValueEntry(localPlayer.PWA + Offsets.ProceduralWeaponAnimation.PositionZeroSum, ref off);
66 | writes.Callbacks += () =>
67 | {
68 | _set = false;
69 | LoneLogging.WriteLine("Wide Lean [Off]");
70 | };
71 | }
72 | }
73 | }
74 | catch (Exception ex)
75 | {
76 | Direction = EWideLeanDirection.Off;
77 | LoneLogging.WriteLine($"Wide Lean [ERROR] {ex}");
78 | }
79 | }
80 |
81 | public override void OnRaidStart()
82 | {
83 | _set = default;
84 | }
85 |
86 | public enum EWideLeanDirection
87 | {
88 | Off,
89 | Left,
90 | Right,
91 | Up
92 | }
93 | }
94 | }
95 |
--------------------------------------------------------------------------------
/arena-dma-radar/Arena/Features/MemoryWrites/Chams.cs:
--------------------------------------------------------------------------------
1 | using arena_dma_radar.Arena.GameWorld;
2 | using eft_dma_shared.Common.Features;
3 | using eft_dma_shared.Common.Misc;
4 | using eft_dma_shared.Common.DMA.ScatterAPI;
5 | using eft_dma_shared.Common.Unity;
6 | using eft_dma_shared.Common.Unity.LowLevel;
7 | using arena_dma_radar.Arena.Features;
8 | using eft_dma_shared.Common.Misc.Config;
9 | using eft_dma_shared.Common.Misc.Commercial;
10 |
11 | namespace arena_dma_radar.Arena.Features.MemoryWrites
12 | {
13 | public sealed class Chams : MemWriteFeature
14 | {
15 | ///
16 | /// Chams Config.
17 | ///
18 | public static ChamsConfig Config { get; } = MemWrites.Config.Chams;
19 |
20 | public override bool Enabled
21 | {
22 | get => Config.Enabled;
23 | set => Config.Enabled = value;
24 | }
25 |
26 | protected override TimeSpan Delay => TimeSpan.FromMilliseconds(100);
27 |
28 | public override void TryApply(ScatterWriteHandle writes)
29 | {
30 | try
31 | {
32 | if (Enabled && Memory.Game is LocalGameWorld game)
33 | {
34 | var cm = game.CameraManager;
35 | var mode = Config.Mode; // Cache value
36 | var players = game.Players
37 | .Where(x => x.IsHostileActive)
38 | .Where(x => x.ChamsMode != mode);
39 | if (!players.Any()) // Already Set
40 | return;
41 | int materialID;
42 | switch (mode)
43 | {
44 | case ChamsManager.ChamsMode.Basic:
45 | var ssaa = MonoBehaviour.GetComponent(cm.FPSCamera, "SSAA");
46 | var opticMaskMaterial = Memory.ReadPtr(ssaa + UnityOffsets.SSAA.OpticMaskMaterial);
47 | var opticMonoBehaviour = Memory.ReadPtr(opticMaskMaterial + ObjectClass.MonoBehaviourOffset);
48 | materialID = Memory.ReadValue(opticMonoBehaviour).InstanceID;
49 | break;
50 | case ChamsManager.ChamsMode.Visible:
51 | if (ChamsManager.Materials!.TryGetValue(ChamsManager.ChamsMode.Visible, out var visible) &&
52 | visible.InstanceID < 0)
53 | {
54 | materialID = visible.InstanceID;
55 | }
56 | else
57 | {
58 | return;
59 | }
60 | break;
61 | case ChamsManager.ChamsMode.VisCheck:
62 | if (ChamsManager.Materials!.TryGetValue(ChamsManager.ChamsMode.VisCheck, out var vischeck) &&
63 | vischeck.InstanceID < 0)
64 | {
65 | materialID = vischeck.InstanceID;
66 | }
67 | else
68 | {
69 | return;
70 | }
71 | break;
72 | default:
73 | throw new NotImplementedException(nameof(mode));
74 | }
75 |
76 | using var hChamsScatter = new ScatterWriteHandle();
77 | foreach (var player in players)
78 | {
79 | player.SetChams(hChamsScatter, game, mode, materialID);
80 | }
81 | }
82 | }
83 | catch (Exception ex)
84 | {
85 | LoneLogging.WriteLine($"ERROR configuring Chams: {ex}");
86 | }
87 | }
88 | }
89 | }
90 |
--------------------------------------------------------------------------------