archivemuh

This commit is contained in:
2025-08-20 19:18:38 -05:00
parent 1411c2e96b
commit fbfcbe9578
173 changed files with 2802 additions and 13 deletions

10
src/engine/CMakeLists.txt Normal file
View File

@@ -0,0 +1,10 @@
# Copyright (c) 2025 Dominic Masters
#
# This software is released under the MIT License.
# https://opensource.org/licenses/MIT
# Sources
target_sources(${DUSK_TARGET_NAME}
PRIVATE
engine.c
)

30
src/engine/engine.c Normal file
View File

@@ -0,0 +1,30 @@
/**
* Copyright (c) 2025 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#include "engine.h"
#include "util/memory.h"
#include "time/time.h"
#include "console/console.h"
engine_t ENGINE;
void engineInit(void) {
memoryZero(&ENGINE, sizeof(engine_t));
ENGINE.running = true;
// Init systems. Order is important.
timeInit();
consoleInit();
}
void engineUpdate(void) {
timeUpdate();
consoleUpdate();
}
void engineDispose(void) {
}

30
src/engine/engine.h Normal file
View File

@@ -0,0 +1,30 @@
/**
* Copyright (c) 2025 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#pragma once
#include "dusk.h"
typedef struct {
bool_t running;
} engine_t;
extern engine_t ENGINE;
/**
* Initializes the engine.
*/
void engineInit(void);
/**
* Updates the engine.
*/
void engineUpdate(void);
/**
* Shuts down the engine.
*/
void engineDispose(void);