MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / PrintDebugMessage

Method PrintDebugMessage

TombEngine/Renderer/RendererDebug.cpp:46–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

44 }
45
46 void Renderer::PrintDebugMessage(LPCSTR msg, va_list args)
47 {
48 constexpr auto LINE_X_POS = DISPLAY_SPACE_RES.x / 100;
49 constexpr auto LINE_SPACING = DISPLAY_SPACE_RES.y / 30;
50 constexpr auto COLOR = Color(1.0f, 1.0f, 1.0f);
51 constexpr auto SCALE = 0.8f;
52
53 char buffer[255];
54 ZeroMemory(buffer, 255);
55 _vsprintf_l(buffer, msg, nullptr, args);
56 AddString(buffer, Vector2(LINE_X_POS, _currentLineHeight), COLOR, SCALE, (int)PrintStringFlags::Outline);
57
58 _currentLineHeight += LINE_SPACING;
59 }
60
61 void Renderer::PrintDebugMessage(LPCSTR msg, ...)
62 {

Callers 1

PrintDebugMessageFunction · 0.80

Calls 2

PrintDebugMessageFunction · 0.85
Vector2Function · 0.50

Tested by

no test coverage detected