Removed DUSK_ prefix
This commit is contained in:
@@ -13,11 +13,11 @@ target_sources(${DUSK_TARGET_NAME}
|
||||
if(DUSK_TARGET_SYSTEM STREQUAL "linux")
|
||||
target_compile_definitions(${DUSK_TARGET_NAME}
|
||||
PRIVATE
|
||||
DUSK_TIME_SDL2=1
|
||||
TIME_SDL2=1
|
||||
)
|
||||
elseif(DUSK_TARGET_SYSTEM STREQUAL "psp")
|
||||
target_compile_definitions(${DUSK_TARGET_NAME}
|
||||
PRIVATE
|
||||
DUSK_TIME_FIXED=1
|
||||
TIME_FIXED=1
|
||||
)
|
||||
endif()
|
@@ -9,7 +9,7 @@
|
||||
#include "util/memory.h"
|
||||
#include "assert/assert.h"
|
||||
|
||||
#if DUSK_TIME_SDL2
|
||||
#if TIME_SDL2
|
||||
#include <SDL2/SDL.h>
|
||||
#endif
|
||||
|
||||
@@ -19,16 +19,16 @@ void timeInit(void) {
|
||||
memoryZero(&TIME, sizeof(TIME));
|
||||
|
||||
// Set these to something non-zero.
|
||||
TIME.time = DUSK_TIME_STEP;
|
||||
TIME.delta = DUSK_TIME_STEP;
|
||||
TIME.time = TIME_STEP;
|
||||
TIME.delta = TIME_STEP;
|
||||
}
|
||||
|
||||
void timeUpdate(void) {
|
||||
float_t delta;
|
||||
#if DUSK_TIME_SDL2
|
||||
#if TIME_SDL2
|
||||
delta = (float_t)SDL_GetTicks() / 1000.0f - TIME.time;
|
||||
#elif DUSK_TIME_FIXED
|
||||
delta = DUSK_TIME_PLATFORM_STEP;
|
||||
#elif TIME_FIXED
|
||||
delta = TIME_PLATFORM_STEP;
|
||||
#else
|
||||
#error "No time platform defined"
|
||||
#endif
|
||||
|
@@ -15,7 +15,7 @@ typedef struct {
|
||||
|
||||
extern dusktime_t TIME;
|
||||
|
||||
#define DUSK_TIME_STEP (1.0f / 60.0f) // Default to 60FPS
|
||||
#define TIME_STEP (1.0f / 60.0f) // Default to 60FPS
|
||||
|
||||
/**
|
||||
* Initializes the time system.
|
||||
|
Reference in New Issue
Block a user