Skip to content

Commit 52feec5

Browse files
committed
logs
1 parent 12b527a commit 52feec5

13 files changed

Lines changed: 27 additions & 28 deletions

File tree

src/hooks/Achievement.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class $modify(AchievementCCMenuItem, CCMenuItem) {
3333

3434
if (auto fmod = FMODAudioEngine::sharedEngine()) {
3535
int rnd = randng::fast();
36-
log::debug("button menu chance {}", rnd);
36+
log::trace("button menu chance {}", rnd);
3737

3838
// @geode-ignore(unknown-resource)
3939
if (rnd <= f->chance) fmod->playEffectAsync("achievement_01.ogg");

src/hooks/Dementia.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class $modify(DementiaPlayerObject, PlayerObject) {
3636
auto f = m_fields.self();
3737

3838
int rnd = randng::fast();
39-
log::debug("player teleport chance {}", rnd);
39+
log::trace("player teleport chance {}", rnd);
4040

4141
FMOD::Channel* musicChannel = nullptr;
4242
auto fmod = FMODAudioEngine::sharedEngine();
@@ -48,7 +48,7 @@ class $modify(DementiaPlayerObject, PlayerObject) {
4848
// dementia
4949
if (rnd <= f->chance) {
5050
setPosition({ f->lastX, f->lastY });
51-
log::debug("player has dementia to ({}, {}), play time {}", f->lastX, f->lastY, f->lastMusicTime);
51+
log::trace("player has dementia to ({}, {}), play time {}", f->lastX, f->lastY, f->lastMusicTime);
5252

5353
// set the music time back to the last recorded time
5454
if (musicChannel) musicChannel->setPosition(f->lastMusicTime, FMOD_TIMEUNIT_MS);
@@ -60,7 +60,7 @@ class $modify(DementiaPlayerObject, PlayerObject) {
6060

6161
f->lastMusicTime = fmod->getMusicTimeMS(1);
6262

63-
log::debug("position recorded to ({}, {}) and music time {}", f->lastX, f->lastY, f->lastMusicTime);
63+
log::trace("position recorded to ({}, {}) and music time {}", f->lastX, f->lastY, f->lastMusicTime);
6464
};
6565
};
6666

src/hooks/Mock.cpp

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,18 @@ class $modify(MockMenuLayer, MenuLayer) {
4141

4242
// show a lazysprite for the first png found in the save dir
4343
int rnd = randng::fast();
44-
log::debug("mock chance {}", rnd);
44+
log::trace("mock chance {}", rnd);
4545

4646
if (rnd <= f->chance) {
4747
auto const mockConfigPath = fmt::format("{}\\mock.json", horribleMod->getSaveDir());
4848
auto const mockConfig = file::readJson(fs::path(mockConfigPath));
4949

50-
log::debug("Reading path {}...", mockConfigPath);
50+
log::trace("Reading path {}...", mockConfigPath);
51+
("Reading path {}...", mockConfigPath);
5152

5253
if (mockConfig.isOk()) {
53-
log::debug("Read mocking config file");
54+
log::trace("Reading path {}...", mockConfigPath);
55+
("Read mocking config file");
5456

5557
auto const mockConfigUnwr = mockConfig.unwrapOr(matjson::Value());
5658

@@ -61,7 +63,7 @@ class $modify(MockMenuLayer, MenuLayer) {
6163
auto percent = lvlUnwr->asInt().unwrapOr(99);
6264

6365
if (!id.empty()) {
64-
log::debug("ID {} with percentage {} is valid", id, percent);
66+
log::trace("ID {} with percentage {} is valid", id, percent);
6567

6668
auto const pngPath = fmt::format("{}\\{}.png", horribleMod->getSaveDir(), id);
6769

@@ -203,7 +205,7 @@ class $modify(MockPlayLayer, PlayLayer) {
203205
auto const mockConfig = file::readJson(fs::path(mockConfigPath)); // get the saved levels to mock the player :)
204206

205207
if (mockConfig.isOk()) {
206-
log::debug("Clearing mock record for {}", id);
208+
log::trace("Clearing mock record for {}", id);
207209
auto mockConfigUnwr = mockConfig.unwrapOr(matjson::Value());
208210
mockConfigUnwr[utils::numToString(id)].clear();
209211

src/hooks/PlayLayer/BlackScreen.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class $modify(BlackScreenPlayLayer, PlayLayer) {
3232
};
3333

3434
void showBlackScreen(float) {
35-
log::debug("Showing black screen after delay");
35+
log::trace("Showing black screen after delay");
3636

3737
auto const winSize = CCDirector::sharedDirector()->getWinSize();
3838

src/hooks/PlayLayer/CrashGame.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class $modify(CrashGamePlayLayer, PlayLayer) {
3232
if (p1 == m_anticheatSpike && p0 && !p0->m_isDead) return;
3333

3434
int rnd = randng::fast();
35-
log::debug("crash destroy chance {}", rnd);
35+
log::trace("crash destroy chance {}", rnd);
3636

3737
if (rnd <= f->chance) {
3838
log::warn("ur game crash hehehehehehehe");

src/hooks/PlayLayer/Friends.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ static constexpr auto s_friends = std::to_array<const char*>({
3131
"diffIcon_09_btn_001.png",
3232
"diffIcon_10_btn_001.png",
3333
"diffIcon_auto_btn_001.png",
34-
});
34+
});
3535

3636
class $modify(FriendsPlayLayer, PlayLayer) {
3737
HORRIBLE_DELEGATE_HOOKS(id);
@@ -40,7 +40,7 @@ class $modify(FriendsPlayLayer, PlayLayer) {
4040
PlayLayer::setupHasCompleted();
4141

4242
auto delay = randng::get(3.f);
43-
log::debug("Friend will visit after {} seconds", delay);
43+
log::trace("Friend will visit after {} seconds", delay);
4444

4545
scheduleOnce(schedule_selector(FriendsPlayLayer::showAFriend), delay);
4646
};
@@ -84,7 +84,7 @@ class $modify(FriendsPlayLayer, PlayLayer) {
8484

8585
void scheduleNextFriend() {
8686
auto delay = randng::get(5.f);
87-
log::debug("Friend will visit again after {} seconds", delay);
87+
log::trace("Friend will visit again after {} seconds", delay);
8888

8989
scheduleOnce(schedule_selector(FriendsPlayLayer::showAFriend), delay);
9090
};

src/hooks/PlayerObject/ClickSpeed.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class $modify(ClickSpeedPlayerObject, PlayerObject) {
2525
int rng = randng::fast() % 100;
2626
int currentSpeed = m_playerSpeed;
2727

28-
log::debug("current speed: {}", currentSpeed);
28+
log::trace("current speed: {}", currentSpeed);
2929

3030
if (rng <= 50) {
3131
// increase the player speed

src/hooks/PlayerObject/Gravity.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class $modify(GravityPlayerObject, PlayerObject) {
3535
// Only set gravity if on flat ground (not on a slope) and not rotating
3636
if (onGrnd && !m_isRotating && !f->m_isOnSlope && !f->m_wasOnSlope) {
3737
m_gravityMod = newGrav;
38-
log::debug("set gravity to x{} (flat ground)", newGrav);
38+
log::trace("set gravity to x{} (flat ground)", newGrav);
3939
};
4040

4141
PlayerObject::updateJump(p0);

src/hooks/PlayerObject/Sleepy.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class $modify(SleepyPlayerObject, PlayerObject) {
7575
// player sleepy if not already in any stage
7676
auto onGround = m_isOnGround || m_isOnGround2 || m_isOnGround3 || m_isOnGround4;
7777
if (!f->m_sleepy && !f->m_waking && onGround) {
78-
log::debug("Making the player m_sleepy");
78+
log::debug("Making the player sleepy");
7979

8080
f->m_defSpeed = m_playerSpeed; // capture original speed
8181
f->m_sleepy = true;

src/hooks/PlayerObject/Sticky.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class $modify(StickyPlayerObject, PlayerObject) {
7575
};
7676

7777
bool onGround() {
78-
// log::debug("1: {} 2: {} 3: {} 4: {}", m_isOnGround ? "y" : "n", m_isOnGround2 ? "y" : "n", m_isOnGround3 ? "y" : "n", m_isOnGround4 ? "y" : "n");
78+
// log::trace("1: {} 2: {} 3: {} 4: {}", m_isOnGround ? "y" : "n", m_isOnGround2 ? "y" : "n", m_isOnGround3 ? "y" : "n", m_isOnGround4 ? "y" : "n");
7979
return m_isOnGround && m_isOnGround2 && m_isOnGround3 & m_isOnGround4;
8080
};
8181

0 commit comments

Comments
 (0)