Dave Gnukem is an open source retro-style 2D scrolling platform shooter, inspired by and similar to Duke Nukem 1. It currently runs on Windows, macOS, Linux and various other platforms. It is written in C++ using SDL library and it features an integrated level editor as well. This game is not really a clone or remake, it is probably most akin to a parody.
12 |16 | * Macros -- "Kids, please don't try this at home. 17 | * We're trained professionals here." :) 18 | *19 | * 20 | * :)) 21 | * 22 | * Update: It's toned down now - we couldn't handle the danger. 23 | * 24 | * dj2022-11 note that comment about using "quite an intensive and dangerous perprocessor hackery" was not mine and I agree all this code must be simpler/safter more robust and easier to maintain. 25 | */ 26 | 27 | #ifndef __SYS_ERROR_H_RTFB__ 28 | #define __SYS_ERROR_H_RTFB__ 29 | 30 | 31 | inline void the_void ( const char*, ... ){ return; } 32 | 33 | #define SYS_Error(...) (_SYS_Error(__FILE__, __LINE__, __VA_ARGS__)) 34 | #define SYS_Warning(...) (_SYS_Warning(__FILE__, __LINE__, __VA_ARGS__)) 35 | #define SYS_Debug(...) (_SYS_Debug(__FILE__, __LINE__, __VA_ARGS__)) 36 | 37 | 38 | void _SYS_Error ( const char *file, int line, const char *fmt, ... ); 39 | void _SYS_Warning ( const char *file, int line, const char *fmt, ... ); 40 | void _SYS_Debug ( const char *file, int line, const char *fmt, ... ); 41 | 42 | 43 | #endif // #ifndef __SYS_ERROR_H_RTFB__ 44 | 45 | -------------------------------------------------------------------------------- /src/sys_log.h: -------------------------------------------------------------------------------- 1 | /* 2 | * File: sys_log.h 3 | * Created: 2002-06-29 (Saturday), 11:40 4 | * Modified: 2002-07-22 (Monday), 04:13 5 | * Author: Vytautas Shaltenis, a.k.a. rtfb 6 | * 7 | * Project: Dave Gnukem 8 | * 9 | * Description: System logger 10 | */ 11 | 12 | #ifndef SYS_LOG_H_KRANKLYS__ 13 | #define SYS_LOG_H_KRANKLYS__ 14 | 15 | #include