rename namespace Log to logging (#27)
This commit is contained in:
parent
c3404b5ef4
commit
a5059056e8
@ -32,13 +32,13 @@ public:
|
||||
static bool init_happened = false;
|
||||
if (init_happened) return true;
|
||||
|
||||
Log::msg("init()");
|
||||
logging::msg("init()");
|
||||
init_happened = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
void post_init() override {
|
||||
Log::msg("post_init()");
|
||||
logging::msg("post_init()");
|
||||
|
||||
// Get interfaces here before init_all has a chance to do anything
|
||||
|
||||
@ -110,7 +110,7 @@ public:
|
||||
std::this_thread::yield();
|
||||
}
|
||||
|
||||
Log::msg("process_attach()");
|
||||
logging::msg("process_attach()");
|
||||
|
||||
// make sure that the netvars are initialised
|
||||
// becuase their dynamic initialiser could be after the
|
||||
@ -130,9 +130,9 @@ public:
|
||||
|
||||
void shutdown() override {}
|
||||
|
||||
void level_init_pre_entity() override { Log::msg("init_pre_entity()"); }
|
||||
void level_init_pre_entity() override { logging::msg("init_pre_entity()"); }
|
||||
void level_init_post_entity() override {
|
||||
Log::msg("level_init_post_entity");
|
||||
logging::msg("level_init_post_entity");
|
||||
|
||||
// Make sure that all our class_ids are correct
|
||||
// This will only do anything on debug builds and not on release builds.
|
||||
@ -143,14 +143,14 @@ public:
|
||||
// Do level init here
|
||||
create_move::level_init();
|
||||
}
|
||||
auto level_shutdown_pre_clear_steam_api_context() -> void override { Log::msg("level_shutdown_pre_clear_steam_api_context"); }
|
||||
auto level_shutdown_pre_clear_steam_api_context() -> void override { logging::msg("level_shutdown_pre_clear_steam_api_context"); }
|
||||
auto level_shutdown_pre_entity() -> void override {
|
||||
Log::msg("level_shutdown_pre_entity");
|
||||
logging::msg("level_shutdown_pre_entity");
|
||||
|
||||
// Do level_shutdown here
|
||||
create_move::level_shutdown();
|
||||
}
|
||||
auto level_shutdown_post_entity() -> void override { Log::msg("level_shutdown_post_entity"); }
|
||||
auto level_shutdown_post_entity() -> void override { logging::msg("level_shutdown_post_entity"); }
|
||||
|
||||
// update is called from CHLClient_HudUpdate
|
||||
// in theory we should be able to render here
|
||||
|
@ -80,14 +80,14 @@ bool hooked_create_move(void *instance, float sample_framerate, UserCmd *user_cm
|
||||
}
|
||||
|
||||
void level_init() {
|
||||
Log::msg("=> Hooking up!");
|
||||
logging::msg("=> Hooking up!");
|
||||
|
||||
assert(create_move_hook == nullptr);
|
||||
create_move_hook = new hooks::HookFunction<ClientMode, 0>(IFace<ClientMode>().get(), 21, 22, 22, reinterpret_cast<void *>(&hooked_create_move));
|
||||
}
|
||||
|
||||
void level_shutdown() {
|
||||
Log::msg("<= Deleting hooks");
|
||||
logging::msg("<= Deleting hooks");
|
||||
|
||||
delete create_move_hook;
|
||||
create_move_hook = nullptr;
|
||||
|
@ -33,12 +33,12 @@ bool internal_checker::ClassIDChecker::check_correct() {
|
||||
auto found_value = find_class_id(name);
|
||||
|
||||
if (found_value == -1) {
|
||||
Log::msg("[ClassID] Unable to find correct value for '%s'", name);
|
||||
logging::msg("[ClassID] Unable to find correct value for '%s'", name);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (found_value != intended_value) {
|
||||
Log::msg("[ClassID] value for %s is wrong (wanted %d, got %d)", name, intended_value, found_value);
|
||||
logging::msg("[ClassID] value for %s is wrong (wanted %d, got %d)", name, intended_value, found_value);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -295,7 +295,7 @@ void ConvarBase::tf_convar_changed(sdk::IConVar *iconvar, const char *old_string
|
||||
if (was_clamped) convar->set_value(modifiable->to_string());
|
||||
convar->change_callback = callback_backup;
|
||||
|
||||
Log::msg("Updated convar %s to '%s' (%s)", convar->get_name(), convar->value_string, was_clamped ? "clamped" : "not clamped");
|
||||
logging::msg("Updated convar %s to '%s' (%s)", convar->get_name(), convar->value_string, was_clamped ? "clamped" : "not clamped");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -3,7 +3,7 @@
|
||||
#include "log.hh"
|
||||
#include "signature.hh"
|
||||
|
||||
auto Log::msg(const char *format, ...) -> void {
|
||||
auto logging::msg(const char *format, ...) -> void {
|
||||
|
||||
char buffer[1024];
|
||||
va_list vlist;
|
||||
|
@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
namespace Log {
|
||||
namespace logging {
|
||||
void msg(const char *format, ...);
|
||||
}
|
||||
|
@ -60,7 +60,7 @@ uptr Netvar::Tree::find_offset(std::vector<const char *> t) {
|
||||
|
||||
if (nodes == old_nodes) {
|
||||
// TODO:
|
||||
//Log::msg("[Netvar] Unable to find '%s'", name);
|
||||
//logging::msg("[Netvar] Unable to find '%s'", name);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user