You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: mod.json
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -240,7 +240,13 @@
240
240
},
241
241
"showCollectedCoins": {
242
242
"name": "Show Collected Coins",
243
-
"description": "Shows the coins you had collected during an attempt before dying.\n\nColor of the label adapts to the coin type.",
243
+
"description": "Shows the coins you had collected during an attempt before dying.\n\nIf \"Use ASCII Art for Coins Instead\" is enabled, the color of the label adapts to the coin type.",
244
+
"type": "bool",
245
+
"default": false
246
+
},
247
+
"useASCIIArtForCoins": {
248
+
"name": "Use ASCII Art for Coins Instead",
249
+
"description": "Use `[C]` and `[ ]` to indicate collected and uncollected coins instead of in-game sprites.",
@@ -194,13 +194,14 @@ class $modify(MyPlayLayer, PlayLayer) {
194
194
if (!theLastCCNode || theLastCCNode == this->m_uiLayer) continue; // skip UILayer
195
195
if (theLastCCNode->getZOrder() != 100) continue;
196
196
if (theLastCCNode->getChildrenCount() < 2) continue;
197
+
if (Manager::getNodeName(theLastCCNode) != "CCNode" && Manager::getNodeName(theLastCCNode) != "cocos2d::CCNode") continue;
197
198
if (getModBool("noVisibleNewBest")) return theLastCCNode->setVisible(false);
198
199
if (!isFromZilkoMod) newBestNodeProbably = theLastCCNode;
199
200
else theLastCCNode->setVisible(false);
200
201
break;
201
202
}
202
203
203
-
if (!newBestNodeProbably || newBestNodeProbably->getUserObject("modified-already"_spr)) return;
204
+
if (!newBestNodeProbably || newBestNodeProbably->getUserObject("modified-already"_spr)) returnlog::info("[MyPlayLayer::findAndModifyTheNewBestNode] found node already");
Copy file name to clipboardExpand all lines: src/PlayerObject.cpp
+15-8Lines changed: 15 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -16,14 +16,15 @@ class $modify(MyPlayerObject, PlayerObject) {
16
16
}
17
17
voidplayerDestroyed(bool p0) {
18
18
PlayerObject::playerDestroyed(p0);
19
-
if (!m_gameLayer || m_gameLayer == LevelEditorLayer::get()) return;
19
+
if (!this->m_gameLayer || this->m_gameLayer == LevelEditorLayer::get()) returnlog::info("[PlayerObject::playerDestroyed] returned because of if (!this->m_gameLayer || this->m_gameLayer == LevelEditorLayer::get())");
20
20
21
21
if (!getBool("enabled")) return;
22
22
constauto pl = PlayLayer::get();
23
-
if (!pl || this != pl->m_player1) return;
23
+
if (!pl || this->m_gameLayer != pl || this != pl->m_player1) returnlog::info("[PlayerObject::playerDestroyed] returned because of if (!pl || this->m_gameLayer != pl || this != pl->m_player1)");
24
24
constauto theLevel = pl->m_level;
25
-
if (!theLevel || theLevel->isPlatformer()) return;
26
-
if (this == pl->m_player2 && theLevel->m_twoPlayerMode) return;
25
+
if (!theLevel || theLevel->isPlatformer()) returnlog::info("[PlayerObject::playerDestroyed] returned because of if (!theLevel || theLevel->isPlatformer())");
26
+
if (this == pl->m_player2 && theLevel->m_twoPlayerMode) returnlog::info("[PlayerObject::playerDestroyed] returned because of if (this == pl->m_player2 && theLevel->m_twoPlayerMode)");
27
+
if (this == pl->m_player2 && pl->m_gameState.m_isDualMode) returnlog::info("[PlayerObject::playerDestroyed] returned because of if (this == pl->m_player2 && pl->m_gameState.m_isDualMode)");
0 commit comments