Advertisement

Scrut.Hut Game Studio - Indie Game Engine

Started by November 15, 2024 05:57 PM
1 comment, last by Tom Sloper 2 weeks, 3 days ago

I want any opinions on this layout for a game engine, minus the game maker and assets and tools that is. Its not to in depth about asset management and the domain descriptions are quite light if I may say my self. Does anyone have any opinions?

//----------------------------------------------------------------------------------
Scrut Game Engine Version 1.0 R0

Scrut Hut is Distributed Platform using Scrut Game Engine by Scrut Game Studios
The Engine is a Distributed piece of Software, yet the Entire Network of computers
is called the Scrut Hut Network. This Network allows Systems to Share Resources
for Servers to Manage Online Content for Games and Applications.

//----------------------------------------------------------------------------------

//-------------
// Architecture

Scrut Game Engine has a Layered Architecture Designed on top of a Static Library
The Layers for the Entire Project are as follows; this Includes the Library and Engine

Stamp
Debug / Release

Library

Engine Layers
Kernel
Shell
Application
Domain
Master
Scrut

/***************************************************/

Library Layers

Mathematics is a set of Consists / Functions / Lookup Tables / Fixed Point Mathematics / Vector, Quaternion, Matrices and Transforms. This system can Interpolate Vectors, Quaternions and Transforms for Coordinate Space Management in Higher Layers for Physics / Rendering. While much work can be done on the side of the CPU, some Mathematics is Handled by the Video Card via GLSL (OpenGL Shading Language) which Enables Client / Server Model to Boost System Performance. Read the Section on Graphics to go further into how Data is Sent to the Video Card and Managed. However, its is Possible to Configure how much work you do on the CPU compared to the Video Card with this System.

Platform is a Operating System Dependent Layer that Enables File / Socket IO and Timer & Thread Management; there is even a Scrut Package File System for Storing all the Project Data in One Place on Disk. This allows one to Map the File Contents to Memory instead of Buffering and Streaming the Data from Disk.

//----

Engine Layers

Kernel Layer is the First Layer in the Engine and Constitutes the Lowest Level Piece of Software that Exist in Scrut. It will Handle Memory / Data Management (Object / Symbol / Module) / Stream & Logging / Threads and a Task Manager. The Distributor is for Handling Resources for the Engines Threads that are Modeled into Pipelines. The Dispatcher is a Deferred System to Send Messages to for Event Management to Route them to their Destination. The Kernel is the Lowest Object in the Scrut Game Engine Layered Architecture in the System. The Lower Layers are Part of the Scrut Library and do not Exist Physically in the Scrut System as Objects. These are merely Part of a Library and are Included in the Project as part of the Household Code and Architecture of the Scrut Object System; this System Builds up to Symbols / Modules to where one can load Extensions to Scrut and Enable other Dynamic Behavior at Run-Time.

Objects are instances of classes that are Included in the Project and part of Scrut Game Engine. Each object has a Unique Type UUID Value and is Different than any Other Object in the System; instance identification is tracked, or where in Memory the Object is Located when a given Time Frame is said to be. The Scrut Game Engine holds a Table of all Objects in the System and the Instance is used to Locate any Object in the System from that Table.

Symbols Consist of Data that is Described by the System and Handled for Access to the Entire Engines Data Center Practically. Much like a File System for a Operating System, this is how you Manipulate Data in the Scrut Game Engine System. Symbols are organized into Tables in a Hierarchy that is Structured Held by the Kernel Layer (Kernel Space for short). This way one can make Tables for Different Purposes and Organized the Entire Games Data at one Instance for the Entire System, and Access any piece of Data from Anywhere in the System.

Modules are Libraries of Objects and Enable Event Management for the Kernel to Build on; each contains a Local Symbol table to Branch from which can Organize all the Data for that Extension to be Handled Specifically and Encapsulated all in One Place. There are Observers receive Notification of Behavior of Objects and are called when an Object is Invoked in Different Ways. The Objects are responsible for Notifying the Observers if any Events / Method Calls (Invoking an Object Method) / Life Cycle & Data Handling / etc... This is how the System can send Events and Controllers Handle Dispatching them to Handlers which Response with a Functor (Function Pointer) Callback Acknowledgement that the Event was Handling by the Target Handlers. Objects then Response to Behavior with Observes allowing the Symbol Table to Store all the Data needed for Execution of the Program.

Shell is part of the Scrut Streaming System that is used to Handle Execution of Buffered Data on Memory from the Socket / Disk / Shared Buffer (Another Process, as in Distributed Computing which Enables Parallel Computation that is Decentralize) / Device in the System. This Includes an Interpreter and System Variables for Configuring the Environment while maintaining Execution in a Orderly Fashion. Scripts can be executed in this system as Native Code / Interpreted or even Distributed to Another System. Heavy Throttling by a Profiler is done to handle Resource Management starting in the Stemming from Kernel Layer Services (Such as the Update Manager) and the Shell Cooperates by Prioritizing Execution based on System Throttle, which can cause Resources to Distribute to / from other Systems.

Application holds the Command Line Arguments in Variables for the Environment to Handle System Configuration. Also Supports the Window or Stream for Either Graphical / CLI Applications. This is the Container of the Project Code that is Booted at run Time.

Domain is a Set of Libraries and are Linked from their corresponding Modules for Handling by the System and Allowing Components to be in the CES (Component - Entity System) in the Activity Layer (This is the Game Loop where the Main Logic of the Game is held). One would have Graphics / Physics / Audio in this Layer Managed by Context Objects that Coordinate these Systems.

Master
- The Game Instance sets the Stage for different Sections of the Game such as Splash / Main Menu / Credits / Options / Game Play / In-Game Settings. There is usually only one Game Instance per Project, yet this is not always true (as such with Mini-Games you might Exchange Objects). This class can be extended to Enable other Parts of the System.

- GameState is the State Machine for the Scrut Engine. More thought needs to go into this sublayer.

- Activity is the Abstracted Game Loop and holds the Entire Game Logic for Executing the Game. This is really the Nuts and Bolts of the System and is Dependent on the Entity-Component System (ECS Systems) that Unity Game Engine (and many others) Uses as well. This allows for use of a well Tested a Robust System Architecture for Game Object Management. A Scene Graph also exists for Optimizing Rendering via a Frustum so Objects can be Passed by the Distributer to the Rendering Pipeline for Handling.

Scrut is the God Object of Scrut and Handles Everything from Initializing the System / Booting Up / Loading & Saving an Application State / Terminating an Application / Restarting the System / Handling System Crisis Mode / etc... This is the Highest Layer in the Engine for Scrut that does not Exists in the Application Space, which can add more Layers if needed.

//----

Kernel Layer
Distributor - Organizes System Resources for Thread Handling
Dispatcher - Buffered Event Management
Scheduler - Task Manager Priority Management

Thread - Scrut Pipelines for Parallel Computing
Update - Task Manager for the System

Memory - Frame & Heap (Dynamic Memory) Managment
Object - Libraries of Objects
Symbol - Kernel Space Enviornment
Module - Extensions to the System
Stream - Enables Buffered Communication
Logger - String Table Logging for the System

Shell
Environment Variables
Registered Streams
Resources
Scripts (Scribble)
Native Code Execution
Interpreter

Application
Command Line Variables

Domain - This is used to Partition Module Libraries in the System Resources
OpenGL 4.5
SDL Input
SDL Audio
WinSock2 (Windows)
Interface (GUI)
Physics

Master
Game Object
Splash
Main Menu
Options
Credits
Game
Settings
Game State - State of the Game
I might go with Active / Idle / Paused / Sleeping for this design; not sure though.
Activity - Game Loop

Scrut - God Layer

This thread was off-topic in the Game Design and Theory forum. What is Game Design? This thread is now in the Engines and Middleware forum. (Note that another mod or admin might disagree with my choice and move it to yet another forum.) @scruthut I'm not a programmer, so I cannot offer any useful feedback re your question. Good luck with your project.

-- Tom Sloper -- sloperama.com

Advertisement