# drappula/lumacore architecture

> Architecture diagram of the GitHub repository drappula/lumacore, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/drappula/lumacore
- Repository: https://github.com/drappula/lumacore

## Overview

LumaCore is an injected Steam DLL that loads at startup, resolves build-specific hook signatures, and applies Steam-client hooks. Its main user-facing flow is Lua files supplied by SteaMidra: LumaCore watches and parses them, then uses the resulting depot keys and ownership data in Steam-facing hooks. Separate branches cover ticket/IPC behavior, achievements and packet rewriting, Denuvo authorization, UI/status reporting, and online-fix game-process support through LumaCorePayload. The startup and hook-install links are shown in source; several feature links rely on README descriptions because their implementations were not sampled.

Main entry points: [`source/core/Orchestrator.cpp`](https://github.com/drappula/lumacore/blob/main/source/core/Orchestrator.cpp) (Hook orchestration), [`source/core/entry.cpp`](https://github.com/drappula/lumacore/blob/main/source/core/entry.cpp) (DLL initialization), [`source/payload/LumaCorePayload/LumaCorePayloadEntry.cpp`](https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/LumaCorePayloadEntry.cpp) (Payload entry), [`source/config/LuaQuery.cpp`](https://github.com/drappula/lumacore/blob/main/source/config/LuaQuery.cpp) (Lua file parsing)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_startup["Startup and patterns"]
  node_proxy["XInput proxy<br/>[LcXInputProxy.cpp]"]
  node_entry["DLL initialization<br/>[entry.cpp]"]
  node_pattern_fetch["Pattern fetching<br/>[PatternFetcher.cpp]"]
  node_signature_scan["Signature scanning<br/>[ByteScan.cpp]"]
  node_orchestrator["Hook orchestration<br/>[Orchestrator.cpp]"]
end

subgraph group_lua["Lua configuration"]
  node_lua_watch["Lua directory watch<br/>[DirWatch.h]"]
  node_lua_parse["Lua file parsing<br/>[LuaQuery.cpp]"]
  node_lua_bindings["Lua API bindings<br/>[LuaBindings.cpp]"]
  node_lua_state["Lua state<br/>[LuaState.cpp]"]
end

subgraph group_steam["Steam hooks"]
  node_steam_user["Steam ownership hooks<br/>[PackagePatch.cpp]"]
  node_depot_keys["Depot key hooks<br/>[DepotKeys.h]"]
  node_decryption["Decryption hooks"]
  node_ipc["IPC and tickets"]
  node_packet["Packet rewriting<br/>[PacketRouter.cpp]"]
  node_denuvo["Denuvo authorization"]
  node_online_fix["Online-fix hooks<br/>[OnlineFixInject.h]"]
  node_steam_ui["Steam UI hooks<br/>[SteamUI.cpp]"]
end

subgraph group_runtime["Runtime support"]
  node_hook_status["Hook status reporting<br/>[HookStatus.cpp]"]
  node_diagnostics["Diagnostics<br/>[Diagnostics.h]"]
end

subgraph group_payload["Game payload"]
  node_payload_entry["Payload entry"]
  node_payload_propagator["Payload deployment"]
  node_eos_bridge["EOS bridge"]
end

node_steamidra(("SteaMidra / Lua files"))
node_steam_client(("Steam client"))
node_game_process(("Game process"))
node_network_mirrors(("Pattern mirrors"))

node_steamidra -->|"loads at startup"| node_proxy
node_proxy -->|"loads DLL"| node_entry
node_entry -->|"loads patterns"| node_pattern_fetch
node_pattern_fetch -->|"fetches patterns"| node_network_mirrors
node_entry -->|"installs hooks"| node_orchestrator
node_entry -->|"starts watcher"| node_lua_watch
node_lua_watch -->|"triggers parsing"| node_lua_parse
node_lua_parse -.->|"uses API"| node_lua_bindings
node_lua_state -->|"supports parsing"| node_lua_parse
node_lua_parse -->|"injects ownership data"| node_steam_client
node_orchestrator -->|"installs hooks"| node_depot_keys
node_orchestrator -->|"installs hooks"| node_decryption
node_orchestrator -->|"installs hooks"| node_packet
node_orchestrator -->|"installs hooks"| node_online_fix
node_orchestrator -->|"installs hooks"| node_steam_user
node_orchestrator -.->|"installs hooks"| node_denuvo
node_orchestrator -->|"unhooks UI"| node_steam_ui
node_orchestrator -.->|"reports hook state"| node_hook_status
node_steam_user -->|"patches ownership"| node_steam_client
node_depot_keys -->|"loads depot keys"| node_steam_client
node_decryption -->|"hooks decryption"| node_steam_client
node_ipc -->|"rewrites IPC"| node_steam_client
node_packet -->|"rewrites packets"| node_steam_client
node_denuvo -->|"authorizes games"| node_steam_client
node_online_fix -->|"synchronizes language"| node_steam_client
node_online_fix -->|"injects payload"| node_payload_entry
node_payload_entry -.->|"deploys payload"| node_payload_propagator
node_payload_entry -->|"provides EOS bridge"| node_eos_bridge
node_payload_entry -->|"runs in process"| node_game_process
node_entry -.->|"starts diagnostics"| node_diagnostics
node_pattern_fetch -.->|"provides signatures"| node_signature_scan

click node_proxy "https://github.com/drappula/lumacore/blob/main/source/proxy/LcXInputProxy.cpp"
click node_entry "https://github.com/drappula/lumacore/blob/main/source/core/entry.cpp"
click node_pattern_fetch "https://github.com/drappula/lumacore/blob/main/source/patterns/PatternFetcher.cpp"
click node_signature_scan "https://github.com/drappula/lumacore/blob/main/source/patterns/ByteScan.cpp"
click node_orchestrator "https://github.com/drappula/lumacore/blob/main/source/core/Orchestrator.cpp"
click node_steam_user "https://github.com/drappula/lumacore/blob/main/source/hooks/client/PackagePatch.cpp"
click node_depot_keys "https://github.com/drappula/lumacore/blob/main/source/hooks/client/DepotKeys.h"
click node_decryption "https://github.com/drappula/lumacore/blob/main/source/hooks/client/DecryptionKeyHook.h"
click node_ipc "https://github.com/drappula/lumacore/blob/main/source/hooks/client/IpcHandlers_ISteamUser.cpp"
click node_packet "https://github.com/drappula/lumacore/blob/main/source/hooks/client/PacketRouter.cpp"
click node_denuvo "https://github.com/drappula/lumacore/blob/main/source/hooks/client/DenuvoAuthenticator.h"
click node_online_fix "https://github.com/drappula/lumacore/blob/main/source/hooks/client/OnlineFixInject.h"
click node_steam_ui "https://github.com/drappula/lumacore/blob/main/source/hooks/ui/SteamUI.cpp"
click node_lua_watch "https://github.com/drappula/lumacore/blob/main/source/runtime/DirWatch.h"
click node_lua_parse "https://github.com/drappula/lumacore/blob/main/source/config/LuaQuery.cpp"
click node_lua_bindings "https://github.com/drappula/lumacore/blob/main/source/config/LuaBindings.cpp"
click node_lua_state "https://github.com/drappula/lumacore/blob/main/source/config/LuaState.cpp"
click node_payload_entry "https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/LumaCorePayloadEntry.cpp"
click node_payload_propagator "https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/PayloadPropagator.cpp"
click node_eos_bridge "https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/EpicOnlineBridge.cpp"
click node_hook_status "https://github.com/drappula/lumacore/blob/main/source/runtime/HookStatus.cpp"
click node_diagnostics "https://github.com/drappula/lumacore/blob/main/source/runtime/Diagnostics.h"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_proxy,node_entry,node_pattern_fetch,node_signature_scan,node_orchestrator,node_steam_client toneBlue
class node_lua_watch,node_lua_parse,node_lua_bindings,node_lua_state toneAmber
class node_steam_user,node_depot_keys,node_decryption,node_ipc,node_packet,node_denuvo,node_online_fix,node_steam_ui toneMint
class node_hook_status,node_diagnostics toneRose
class node_payload_entry,node_payload_propagator,node_eos_bridge,node_steamidra,node_game_process,node_network_mirrors toneIndigo
```

## Components

### Startup and patterns

- [XInput proxy](https://github.com/drappula/lumacore/blob/main/source/proxy/LcXInputProxy.cpp): `source/proxy/LcXInputProxy.cpp`
- [DLL initialization](https://github.com/drappula/lumacore/blob/main/source/core/entry.cpp): `source/core/entry.cpp`
- [Pattern fetching](https://github.com/drappula/lumacore/blob/main/source/patterns/PatternFetcher.cpp): `source/patterns/PatternFetcher.cpp`
- [Signature scanning](https://github.com/drappula/lumacore/blob/main/source/patterns/ByteScan.cpp): `source/patterns/ByteScan.cpp`
- [Hook orchestration](https://github.com/drappula/lumacore/blob/main/source/core/Orchestrator.cpp): `source/core/Orchestrator.cpp`

### Lua configuration

- [Lua directory watch](https://github.com/drappula/lumacore/blob/main/source/runtime/DirWatch.h): `source/runtime/DirWatch.h`
- [Lua file parsing](https://github.com/drappula/lumacore/blob/main/source/config/LuaQuery.cpp): `source/config/LuaQuery.cpp`
- [Lua API bindings](https://github.com/drappula/lumacore/blob/main/source/config/LuaBindings.cpp): `source/config/LuaBindings.cpp`
- [Lua state](https://github.com/drappula/lumacore/blob/main/source/config/LuaState.cpp): `source/config/LuaState.cpp`

### Steam hooks

- [Steam ownership hooks](https://github.com/drappula/lumacore/blob/main/source/hooks/client/PackagePatch.cpp): `source/hooks/client/PackagePatch.cpp`
- [Depot key hooks](https://github.com/drappula/lumacore/blob/main/source/hooks/client/DepotKeys.h): `source/hooks/client/DepotKeys.h`
- [Decryption hooks](https://github.com/drappula/lumacore/blob/main/source/hooks/client/DecryptionKeyHook.h): `source/hooks/client/DecryptionKeyHook.h`
- [IPC and tickets](https://github.com/drappula/lumacore/blob/main/source/hooks/client/IpcHandlers_ISteamUser.cpp): `source/hooks/client/IpcHandlers_ISteamUser.cpp`
- [Packet rewriting](https://github.com/drappula/lumacore/blob/main/source/hooks/client/PacketRouter.cpp): `source/hooks/client/PacketRouter.cpp`
- [Denuvo authorization](https://github.com/drappula/lumacore/blob/main/source/hooks/client/DenuvoAuthenticator.h): `source/hooks/client/DenuvoAuthenticator.h`
- [Online-fix hooks](https://github.com/drappula/lumacore/blob/main/source/hooks/client/OnlineFixInject.h): `source/hooks/client/OnlineFixInject.h`
- [Steam UI hooks](https://github.com/drappula/lumacore/blob/main/source/hooks/ui/SteamUI.cpp): `source/hooks/ui/SteamUI.cpp`

### Runtime support

- [Hook status reporting](https://github.com/drappula/lumacore/blob/main/source/runtime/HookStatus.cpp): `source/runtime/HookStatus.cpp`
- [Diagnostics](https://github.com/drappula/lumacore/blob/main/source/runtime/Diagnostics.h): `source/runtime/Diagnostics.h`

### Game payload

- [Payload entry](https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/LumaCorePayloadEntry.cpp): `source/payload/LumaCorePayload/LumaCorePayloadEntry.cpp`
- [Payload deployment](https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/PayloadPropagator.cpp): `source/payload/LumaCorePayload/PayloadPropagator.cpp`
- [EOS bridge](https://github.com/drappula/lumacore/blob/main/source/payload/LumaCorePayload/EpicOnlineBridge.cpp): `source/payload/LumaCorePayload/EpicOnlineBridge.cpp`

### Other components

- **SteaMidra / Lua files**
- **Steam client**
- **Game process**
- **Pattern mirrors**

## Connections

- SteaMidra / Lua files → XInput proxy: loads at startup (evidence: `README.md`)
- XInput proxy → DLL initialization: loads DLL (evidence: `README.md`)
- DLL initialization → Pattern fetching: loads patterns (evidence: `README.md`)
- Pattern fetching → Pattern mirrors: fetches patterns (evidence: `README.md`)
- DLL initialization → Hook orchestration: installs hooks (evidence: `source/core/entry.cpp`)
- DLL initialization → Lua directory watch: starts watcher (evidence: `README.md`)
- Lua directory watch → Lua file parsing: triggers parsing (evidence: `README.md`)
- Lua file parsing → Lua API bindings: uses API
- Lua state → Lua file parsing: supports parsing (evidence: `source/config/LuaState.cpp`)
- Lua file parsing → Steam client: injects ownership data (evidence: `README.md`)
- Hook orchestration → Depot key hooks: installs hooks (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Decryption hooks: installs hooks (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Packet rewriting: installs hooks (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Online-fix hooks: installs hooks (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Steam ownership hooks: installs hooks (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Denuvo authorization: installs hooks
- Hook orchestration → Steam UI hooks: unhooks UI (evidence: `source/core/Orchestrator.cpp`)
- Hook orchestration → Hook status reporting: reports hook state
- Steam ownership hooks → Steam client: patches ownership (evidence: `README.md`)
- Depot key hooks → Steam client: loads depot keys (evidence: `README.md`)
- Decryption hooks → Steam client: hooks decryption (evidence: `README.md`)
- IPC and tickets → Steam client: rewrites IPC (evidence: `README.md`)
- Packet rewriting → Steam client: rewrites packets (evidence: `README.md`)
- Denuvo authorization → Steam client: authorizes games (evidence: `README.md`)
- Online-fix hooks → Steam client: synchronizes language (evidence: `README.md`)
- Online-fix hooks → Payload entry: injects payload (evidence: `README.md`)
- Payload entry → Payload deployment: deploys payload
- Payload entry → EOS bridge: provides EOS bridge (evidence: `README.md`)
- Payload entry → Game process: runs in process (evidence: `README.md`)
- DLL initialization → Diagnostics: starts diagnostics (evidence: `source/core/entry.cpp`)
- Pattern fetching → Signature scanning: provides signatures
