Skip to content

A cross-language engine architecture demonstrating systems-level design with C++ ECS core, zero-copy Rust serialization, embedded Lua scripting, Python AI behaviors, a C# level editor, and a TypeScript dashboard for telemetry and profiling

License

Notifications You must be signed in to change notification settings

Quantum-Fiend/Prime_Flux_Engine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

PrimeFlux Engine (Advanced Mini Engine Architecture)

A Multi-Language High-Performance Game Engine

License C++ Rust Python TypeScript

PrimeFlux is a production-grade demonstration of cross-language runtime design, integrating 6 distinct languages into a unified game development ecosystem.


πŸ› Architecture

graph LR
    A[C++ Core Engine] --> B[Lua Scripting]
    A --> C[Python AI]
    A --> D[Rust Serialization]
    A --> E[WebSocket]
    E --> F[TypeScript Dashboard]
    G[C# Editor] -.->|TCP| A
    
    style A fill:#6366f1,color:#fff
    style D fill:#f59e0b,color:#000
    style C fill:#10b981,color:#000
    style F fill:#06b6d4,color:#000
    style G fill:#8b5cf6,color:#fff
Loading
Module Language Function
Core C++ (17/20) Rendering (OpenGL/Vulkan), ECS, Physics, Asset Pipeline
Scripting Lua Gameplay Logic, Hot-Reloading
Artificial Intelligence Python Behavior Trees, ML Integration, Pathfinding
Serialization Rust Zero-copy Scene Loading, Safe Persistence
Tools/Editor C# (.NET) Level Inspector, Scene Authoring
Dashboard TypeScript Real-time Telemetry, Profiling, Remote Debugging

πŸš€ Key Features

Core Engine (C++)

  • βœ… Entity-Component-System (ECS) architecture
  • βœ… Game loop with delta time and fixed timestep
  • βœ… Modular subsystem design
  • πŸ”„ OpenGL/Vulkan rendering (planned)
  • πŸ”„ Physics integration (Bullet/PhysX) (planned)

Rust Serialization

  • βœ… High-performance binary serialization with Serde
  • βœ… C ABI for seamless C++ integration
  • βœ… Type-safe scene and entity data structures
  • βœ… Zero-copy deserialization

Lua Scripting

  • βœ… Embedded Lua interpreter
  • βœ… Gameplay script examples
  • πŸ”„ Hot-reload mechanism (planned)
  • βœ… Event-driven API

Python AI

  • βœ… Behavior tree implementation
  • βœ… Sequence and Selector nodes
  • βœ… Action and Condition nodes
  • πŸ”„ A* pathfinding (planned)
  • πŸ”„ ML model integration (planned)

C# Level Editor

  • βœ… WPF-based visual editor
  • βœ… Scene hierarchy panel
  • βœ… Inspector panel
  • βœ… Console/log viewer
  • πŸ”„ Live engine connection (planned)

TypeScript Dashboard

  • βœ… Real-time metrics (FPS, memory, entities)
  • βœ… WebSocket telemetry (placeholder)
  • βœ… Subsystem status monitoring
  • βœ… Log aggregation
  • βœ… Modern React UI with dark theme

πŸ“‚ Directory Structure

PrimeFlux Engine/
β”œβ”€β”€ core/              # C++ Engine (CMake)
β”‚   β”œβ”€β”€ include/       # Headers (Engine.h, ECS.h)
β”‚   β”œβ”€β”€ src/           # Implementation
β”‚   └── CMakeLists.txt
β”œβ”€β”€ serialization/     # Rust library
β”‚   β”œβ”€β”€ src/lib.rs     # Serde-based serialization
β”‚   └── Cargo.toml
β”œβ”€β”€ scripting/         # Lua scripts
β”‚   └── example_script.lua
β”œβ”€β”€ ai/                # Python AI
β”‚   β”œβ”€β”€ behavior_tree.py
β”‚   └── __init__.py
β”œβ”€β”€ editor/            # C# WPF Editor
β”‚   β”œβ”€β”€ MainWindow.xaml
β”‚   └── PrimeFluxEditor.csproj
β”œβ”€β”€ dashboard/         # TypeScript Dashboard
β”‚   β”œβ”€β”€ src/App.tsx
β”‚   └── package.json
β”œβ”€β”€ shared/            # Shared headers
β”‚   └── RustSerialization.h
β”œβ”€β”€ BUILD.md           # Build instructions
└── ARCHITECTURE.md    # Detailed architecture

πŸ›  Prerequisites

  • CMake 3.20+
  • C++ Compiler (MSVC 2019+, GCC 9+, or Clang 10+)
  • Rust 1.70+ with Cargo
  • Python 3.9+
  • .NET SDK 6.0+
  • Node.js 18+ with npm

πŸƒ Quick Start

1. Build Rust Serialization

cd serialization
cargo build --release

2. Build C++ Engine

cd core
mkdir build && cd build
cmake ..
cmake --build . --config Release
./bin/PrimeFluxEngine

3. Run Dashboard

cd dashboard
npm install
npm run dev
# Open http://localhost:3000

4. Run Editor (Optional)

cd editor
dotnet run

For detailed build instructions, see BUILD.md.


πŸ“Š Why This Project Stands Out

This project demonstrates:

  • βœ… Systems Programming Mastery: C++ engine with ECS, game loop, and subsystem orchestration
  • βœ… Cross-Language Interop: Seamless integration of 6 languages via C ABI, embedding, and IPC
  • βœ… Graphics & Engine Design: Modular architecture ready for OpenGL/Vulkan
  • βœ… AI & Behavior Systems: Python-based behavior trees for intelligent NPCs
  • βœ… Data Safety: Rust-powered serialization with strong type guarantees
  • βœ… Tooling Ecosystem: Professional editor and real-time dashboard
  • βœ… Production Practices: CMake, Cargo, npm, proper project structure

Perfect for roles in:

  • Game Engine Development
  • Systems Programming
  • Graphics Engineering
  • Simulation & Robotics
  • Multi-Language Runtime Design

πŸ“œ License

MIT License - see LICENSE file for details.


🎯 Roadmap

  • Integrate Lua interpreter (LuaJIT)
  • Implement OpenGL/Vulkan renderer
  • Add physics engine (Bullet/PhysX)
  • Complete WebSocket telemetry bridge
  • Implement hot-reload for Lua scripts
  • Add A* pathfinding to Python AI
  • Multi-threaded ECS job system
  • Asset streaming pipeline

Built with ⚑ by a systems programming enthusiast

About

A cross-language engine architecture demonstrating systems-level design with C++ ECS core, zero-copy Rust serialization, embedded Lua scripting, Python AI behaviors, a C# level editor, and a TypeScript dashboard for telemetry and profiling

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published