shithub: cstory

Download patch

ref: 5b18283e5f8dffd4cae6b5b7ef09d67237383db5
parent: f840be28c71e6605e3ec197a120f1b1aa45b3497
author: Gabriel Ravier <gabravier@gmail.com>
date: Tue Nov 5 06:19:20 EST 2019

Documentation : Made some comments clearer

Signed-off-by: Gabriel Ravier <gabravier@gmail.com>

--- a/src/Generic.cpp
+++ b/src/Generic.cpp
@@ -27,7 +27,7 @@
 	months[10] = "Oct";
 	months[11] = "Nov";
 	months[12] = "Dec";
-	sscanf(__DATE__, "%s %d %d", month_string, day, year);	// The expansion of __DATE__ is not reproductible. We might want to change this
+	sscanf(__DATE__, "%s %d %d", month_string, day, year);	// The expansion of __DATE__ is not reproductible. TODO : Think about changing this to be reproductible
 
 	for (i = 0; i < 12; ++i)	// This being 12 instead of 13 might be a bug, but it works anyway by accident
 		if (!memcmp(&month_string, months[i], 3))
--- a/src/MyChar.cpp
+++ b/src/MyChar.cpp
@@ -680,7 +680,7 @@
 	// Change position
 	if (gMC.xm <= resist && gMC.xm >= -resist)
 	{
-		// Okay, this is getting stupid. Why the HELL is the code written like this?
+		// This case is completely empty. This is most likely the result of commented code or some other change (so this is most likely inaccurate to the original source)
 	}
 	else
 	{
--- a/src/MycParam.cpp
+++ b/src/MycParam.cpp
@@ -135,7 +135,7 @@
 
 	// Lose a whimsical star
 	if (gMC.equip & 0x80 && gMC.star > 0)
-		gMC.star = (short)gMC.star - 1;	// Why the hell is it written this way?
+		gMC.star = (short)gMC.star - 1;	// For some reason, does a cast to short. Probably not accurate to the original source
 
 	// Lose experience
 	if (gMC.equip & 4)
--- a/src/NpcAct160.cpp
+++ b/src/NpcAct160.cpp
@@ -70,7 +70,7 @@
 
 		case 3:
 			npc->damage = 20;
-			npc->damage = 0;	// Smart code
+			npc->damage = 0;	// Duplicate line
 
 			if (++npc->act_wait > 24)
 			{
--- a/src/NpcAct320.cpp
+++ b/src/NpcAct320.cpp
@@ -142,10 +142,10 @@
 			break;
 
 		case 1:
-			if (gMC.direct == 0)
+			if (gMC.direct == 0)	// Does the same thing whether this is false or true
 				npc->x = npc->pNpc->x;
 			else
-				npc->x = npc->pNpc->x;	// Duplicate derp
+				npc->x = npc->pNpc->x;
 
 			direct = 1;
 			npc->y = npc->pNpc->y - 0x1400;
@@ -152,10 +152,10 @@
 			break;
 
 		case 2:
-			if (gMC.direct == 0)
+			if (gMC.direct == 0)	// Does the same thing whether this is false or true
 				npc->x = npc->pNpc->x;
 			else
-				npc->x = npc->pNpc->x;	// Duplicate derp
+				npc->x = npc->pNpc->x;
 
 			direct = 3;
 			npc->y = npc->pNpc->y + 0x1400;
--- a/src/Sound.cpp
+++ b/src/Sound.cpp
@@ -390,7 +390,7 @@
 		++ptp_pointer;
 	}
 
-	// Maybe this used to be something to prevent audio popping?
+	// This is self-assignment, so redundant. Maybe this used to be something to prevent audio popping ?
 	mixed_pcm_buffer[0] = mixed_pcm_buffer[0];
 	mixed_pcm_buffer[sample_count - 1] = mixed_pcm_buffer[sample_count - 1];