#2138 Optionally Hide Debug Output (Finished Games Only)

Open time-killer-games time-killer-games
Coverage Reach
Universal_System/Extensions/ParticleSystems/PS_particle_sprites.cpp Universal_System/Extensions/ParticleSystems/PS_effects.cpp Universal_System/Extensions/ParticleSystems/PS_particle_system.cpp Universal_System/Extensions/ParticleSystems/PS_particle_type.cpp Universal_System/Extensions/ParticleSystems/PS_particle_emitter.cpp Universal_System/Extensions/ParticleSystems/PS_actions.cpp Universal_System/Extensions/ParticleSystems/PS_particle_changer.cpp Universal_System/Extensions/ParticleSystems/PS_particle_destroyer.cpp Universal_System/Extensions/ParticleSystems/PS_particle_deflector.cpp Universal_System/Extensions/ParticleSystems/PS_particle_bridge_fallback.h Universal_System/Extensions/ParticleSystems/PS_particle_system_apiimpl.cpp Universal_System/Extensions/ParticleSystems/PS_particle_attractor.cpp Universal_System/Extensions/ParticleSystems/PS_particle_enums.h Universal_System/Extensions/ParticleSystems/PS_particle_particles_apiimpl.cpp Universal_System/Extensions/ParticleSystems/PS_particle_updatedraw.cpp Universal_System/Extensions/ParticleSystems/PS_effects_enums.h Universal_System/Extensions/ParticleSystems/PS_particle_system_manager.cpp Universal_System/Extensions/DataStructures/data_structures.cpp Universal_System/Extensions/MotionPlanning/motion_planning.cpp Universal_System/Extensions/MotionPlanning/mp_movement.cpp Universal_System/Extensions/MotionPlanning/motion_planning_struct.cpp Universal_System/Extensions/MotionPlanning/motion_planning_struct.h Universal_System/Extensions/Paths/path_functions.cpp Universal_System/Extensions/Paths/pathstruct.cpp Universal_System/Extensions/Paths/pathinit.cpp Universal_System/Extensions/Paths/implement.h Universal_System/Extensions/Paths/pathstruct.h Universal_System/Extensions/DateTime/date_time.cpp Universal_System/Extensions/IniFilesystem/UNIXiniindex.cpp Universal_System/Extensions/IniFilesystem/UNIXinifs.cpp Universal_System/Extensions/IniFilesystem/UNIXiniindex.h Universal_System/Extensions/GTest/include.h Universal_System/Extensions/GTest/GTest.cpp Universal_System/Extensions/libpng/libpng-ext.cpp Universal_System/Extensions/Alarms/alarmcode.cpp Universal_System/Resources/fontstruct.cpp Universal_System/Resources/sprites.cpp Universal_System/Resources/AssetArray.h Universal_System/Resources/backgrounds.cpp Universal_System/Resources/fontinit.cpp Universal_System/Resources/spriteinit.cpp Universal_System/Resources/sprites_internal.cpp Universal_System/Resources/loading.cpp Universal_System/Resources/backgroundinit.cpp Universal_System/Resources/resource_data.cpp Universal_System/Resources/asset_index.cpp Universal_System/Resources/backgrounds_internal.cpp Universal_System/Resources/soundinit.cpp Universal_System/Resources/sprites_internal.h Universal_System/Resources/fonts_internal.h Universal_System/Resources/backgrounds_internal.h Universal_System/roomsystem.cpp Universal_System/Instances/instance_system.cpp Universal_System/Instances/instance.cpp Universal_System/Instances/instance_create.h Universal_System/Instances/instance_planar.cpp Universal_System/Instances/callbacks_events.cpp Universal_System/gif_format.cpp Universal_System/Object_Tiers/object.cpp Universal_System/Object_Tiers/planar_object.cpp Universal_System/Object_Tiers/collisions_object.cpp Universal_System/Object_Tiers/graphics_object.cpp Universal_System/Object_Tiers/timelines_object.cpp Universal_System/Object_Tiers/transform_object.cpp Universal_System/Object_Tiers/graphics_object.h Universal_System/Object_Tiers/timelines_object.h Universal_System/bufferstruct.cpp Universal_System/image_formats.cpp Universal_System/var4.h Universal_System/estring.cpp Universal_System/mathnc.cpp Universal_System/fileio.cpp Universal_System/highscore_functions.cpp Universal_System/mathnc.h Universal_System/move_functions.cpp Universal_System/lua_table.h Universal_System/random.cpp Universal_System/reflexive_types.cpp Universal_System/zlib.cpp Universal_System/terminal_io.cpp Universal_System/actions.h Universal_System/var_array.cpp Universal_System/multifunction_variant.h Universal_System/debugscope.cpp Universal_System/lives.cpp Universal_System/dynamic_args.cpp Universal_System/nlpo2.h Universal_System/image_formats.h Universal_System/reflexive_types.h Universal_System/roomsystem.h Universal_System/shaderstruct.cpp Universal_System/highscore_functions.h Universal_System/random.h Universal_System/depth_draw.cpp Universal_System/buffers_internal.h Universal_System/globalupdate.cpp Universal_System/lives.h Graphics_Systems/General/GSfont.cpp Graphics_Systems/General/GSstdraw.cpp Graphics_Systems/General/GSmodel.cpp Graphics_Systems/General/GStiles.cpp Graphics_Systems/General/GSsurface.cpp Graphics_Systems/General/GSbackground.cpp Graphics_Systems/General/GSsprite.cpp Graphics_Systems/General/GSscreen.cpp Graphics_Systems/General/GScurves.cpp Graphics_Systems/General/GSvertex.cpp Graphics_Systems/General/GSmatrix.cpp Graphics_Systems/General/GSd3d.cpp Graphics_Systems/General/texture_atlas.cpp Graphics_Systems/General/GStextures.cpp Graphics_Systems/General/GSprimitives.cpp Graphics_Systems/General/GScolors.cpp Graphics_Systems/General/GSvertex_impl.h Graphics_Systems/General/actions.h Graphics_Systems/General/GSmodel_impl.h Graphics_Systems/General/GSblend.cpp Graphics_Systems/General/GStextures_impl.h Graphics_Systems/General/GSsurface_impl.h Graphics_Systems/OpenGL-Common/shader.cpp Graphics_Systems/OpenGL-Common/vertex.cpp Graphics_Systems/OpenGL-Common/d3d.cpp Graphics_Systems/OpenGL-Common/surface.cpp Graphics_Systems/OpenGL-Common/textures.cpp Graphics_Systems/OpenGL-Common/std.cpp Graphics_Systems/OpenGL-Common/screen.cpp Graphics_Systems/OpenGL-Common/types.cpp Graphics_Systems/OpenGL-Common/profiler.h Graphics_Systems/OpenGL-Common/GLSLshader.h Graphics_Systems/OpenGL-Common/stdraw.cpp Graphics_Systems/OpenGL-Common/texture_copy.cpp Graphics_Systems/OpenGL-Common/profiler.cpp Graphics_Systems/OpenGL-Common/textures_impl.h Graphics_Systems/OpenGL1/vertex.cpp Graphics_Systems/OpenGL1/shader.cpp Graphics_Systems/OpenGL1/d3d.cpp Graphics_Systems/OpenGL1/std.cpp Graphics_Systems/OpenGL1/stdraw.cpp Graphics_Systems/OpenGL1/GLSLshader.h Graphics_Systems/OpenGL-Desktop/surface.cpp Graphics_Systems/OpenGL-Desktop/screen.cpp Graphics_Systems/OpenGL-Desktop/types.cpp Graphics_Systems/OpenGL-Desktop/textures.cpp Graphics_Systems/OpenGL-Debug/debug.cpp Graphics_Systems/OpenGL3/d3d.cpp Graphics_Systems/OpenGL3/std.cpp Graphics_Systems/OpenGL3/stdraw.cpp Platforms/xlib/XLIBwindow.cpp Platforms/xlib/LINUXjoystick.cpp Platforms/xlib/XLIBmain.cpp Platforms/xlib/XDisplayGetters.cpp Platforms/xlib/XLIBsystem.cpp Platforms/xlib/XLIBicon.cpp Platforms/SDL/Event.cpp Platforms/SDL/Window.cpp Platforms/SDL/Gamepad.cpp Platforms/SDL/Joystick.cpp Platforms/SDL/xlib/Window.cpp Platforms/SDL/Threads.cpp Platforms/SDL/Icon.cpp Platforms/SDL/Clipboard.cpp Platforms/SDL/Main.cpp Platforms/General/PFwindow.cpp Platforms/General/POSIX/Utility.cpp Platforms/General/POSIX/POSIXfilemanip.cpp Platforms/General/POSIX/POSIXdirectory.cpp Platforms/General/POSIX/shell.cpp Platforms/General/POSIX/main.cpp Platforms/General/POSIX/POSIXthreads.cpp Platforms/General/POSIX/POSIXproccess.cpp Platforms/General/PFmain.cpp Platforms/General/PFthreads.cpp Platforms/General/PFshell/PFshell.cpp Platforms/General/PFthreads_impl.h Platforms/General/PFwindow.h Collision_Systems/Precise/PRECimpl.cpp Collision_Systems/Precise/PRECfuncs.cpp Collision_Systems/Precise/placeholderlinks.cpp Collision_Systems/BBox/BBOXfuncs.cpp Collision_Systems/BBox/BBOXimpl.cpp Collision_Systems/BBox/BBOXutil.cpp Collision_Systems/BBox/placeholderlinks.cpp Audio_Systems/OpenAL/ALadvanced.cpp Audio_Systems/OpenAL/ALbasic.cpp Audio_Systems/OpenAL/ALsystem.cpp Audio_Systems/OpenAL/SoundResource.h Audio_Systems/OpenAL/SoundEmitter.h Audio_Systems/OpenAL/SoundChannel.h Bridges/xlib-OpenGL/graphics_bridge.cpp Bridges/SDL-OpenGL/graphics_bridge.cpp Bridges/OpenGL/GLload.cpp Widget_Systems/None/nowidget_impl.cpp Widget_Systems/None/default_log.cpp Widget_Systems/widgets_mandatory.h libEGMstd.cpp SHELLmain.cpp floatcomp.h

No flags found

Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.

e.g., #unittest #integration

#production #enterprise

#frontend #backend

Learn more about Codecov Flags here.


@@ -23,6 +23,10 @@
Loading
23 23
24 24
#include <string>
25 25
26 +
#ifndef DO_NOT_ABORT_ERRORS
27 +
#define DO_NOT_ABORT_ERRORS
28 +
#endif
29 +
26 30
#define DEBUG_MESSAGE(msg, severity) ::enigma_user::show_debug_message((std::string) (msg) + " | " __FILE__ ":" + std::to_string(__LINE__), (severity))
27 31
28 32
enum MESSAGE_TYPE : int {
@@ -63,6 +67,18 @@
Loading
63 67
      default: return "ERROR";
64 68
    }
65 69
  }
70 +
71 +
  inline void show_debug_message_hidden(std::string msg, MESSAGE_TYPE type = M_INFO) {
72 +
    #ifndef DO_NOT_ABORT_ERRORS
73 +
    if (severity == M_ERROR || severity == M_USER_ERROR ||
74 +
      severity == M_FATAL_ERROR || severity == M_FATAL_USER_ERROR) {
75 +
      abort();
76 +
    }
77 +
    #endif
78 +
    if (type == M_FATAL_USER_ERROR || type == M_USER_ERROR) {
79 +
      abort();
80 +
    }
81 +
  }
66 82
  
67 83
  // This function is called at the beginning of the game to allow the widget system to load.
68 84
  bool widget_system_initialize();
@@ -77,6 +93,9 @@
Loading
77 93
78 94
void show_debug_message(std::string msg, MESSAGE_TYPE type = M_INFO);
79 95
96 +
void debug_output_set_enabled(bool enabled, MESSAGE_TYPE type);
97 +
bool debug_output_get_enabled(MESSAGE_TYPE type);
98 +
80 99
// This obviously displays an error message.
81 100
// It should offer a button to end the game, and if not fatal, a button to ignore the error.
82 101
inline void show_error(std::string msg, const bool fatal) {

Everything is accounted for!

No changes detected that need to be reviewed.
What changes does Codecov check for?
Lines, not adjusted in diff, that have changed coverage data.
Files that introduced coverage data that had none before.
Files that have missing coverage data that once were tracked.

24 Commits

Hiding 20 contexual commits Hiding 2 contexual commits
Pull Request Base Commit
Files Coverage
ENIGMAsystem/SHELL 32.97%
Project Totals (197 files) 32.97%
Loading