Initial commit: DayZ memory C++ port with DMA backend and overlay

This commit is contained in:
67
2026-06-16 15:18:44 +08:00
commit f04e38b8ae
163 changed files with 163380 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
#pragma once
#include <vector>
#include <string>
#include "Core/Models.h"
#include "Core/RuntimeSession.h"
#include "Memory/VmmAccessor.h"
#include "Readers/EntityTypeCache.h"
// -------------------------------------------------------------------------
// NearEntityListReader
// Reads the world's near-entity pointer table and builds a flat list of
// DayZNearEntityEntry values. Entity type metadata is cached across calls
// via an internal EntityTypeCache.
// -------------------------------------------------------------------------
class NearEntityListReader {
public:
/// Read the current near-entity list into @p entries.
/// Replaces the contents of @p entries on each successful call.
/// Returns false only when the initial table reads fail entirely.
bool TryRead(VmmAccessor& mem,
const RuntimeSession& session,
std::vector<DayZNearEntityEntry>& entries);
/// Clear cached type metadata. Call when the game session restarts.
void Reset();
private:
static constexpr int kMaxEntities = 4096;
EntityTypeCache m_typeCache;
};