Undo PokeCodec's PRs

This commit undoes most of PokeCodec's PRs after the debate in chat. Some
harmless or completely superseded PRs have been left alone, as there is not
much benefit in attempting to undo them.

Reverts #1104, #1108, #1115, #1118, #1119, #1124, #1126, #1127, #1132, #1136,
#1137, #1139, #1140, #1144, #1148, #1149, #1150, #1153, #1155, #1177, #1179,
#1180, #1181, #1182 and #1183.
This commit is contained in:
aaaaaa123456789
2020-09-13 04:22:50 -03:00
parent 58a2b62bae
commit 7dc95a0103
149 changed files with 6786 additions and 3108 deletions
+27 -31
View File
@@ -219,22 +219,18 @@ void BufferTrendyPhraseString(void)
ConvertEasyChatWordsToString(gStringVar1, s->words, 2, 1);
}
void TrendyPhraseIsOld(void)
{
u8 result = 0;
u16 result = 0;
do
if (gSaveBlock1Ptr->easyChatPairs[0].unk0_0 - gSaveBlock1Ptr->easyChatPairs[1].unk0_0 < 2)
{
if (gSaveBlock1Ptr->easyChatPairs[0].unk0_0 - gSaveBlock1Ptr->easyChatPairs[1].unk0_0 > 1)
break;
if (gSaveBlock1Ptr->easyChatPairs[0].unk1_6)
break;
if (!gSaveBlock1Ptr->easyChatPairs[1].unk1_6)
break;
result = 1;
} while (0);
#ifndef NONMATCHING
asm("":::"r2"); //Force the compiler to store address of gSaveBlock1 in r3 instead of r2
#endif
if (!gSaveBlock1Ptr->easyChatPairs[0].unk1_6 && gSaveBlock1Ptr->easyChatPairs[1].unk1_6)
result = 1;
}
gSpecialVar_Result = result;
}
@@ -249,46 +245,46 @@ static bool8 sub_8122A58(struct EasyChatPair *a, struct EasyChatPair *b, u8 c)
{
case 0:
if (a->unk0_0 > b->unk0_0)
return TRUE;
return 1;
if (a->unk0_0 < b->unk0_0)
return FALSE;
return 0;
if (a->unk0_7 > b->unk0_7)
return TRUE;
return 1;
if (a->unk0_7 < b->unk0_7)
return FALSE;
return 0;
break;
case 1:
if (a->unk0_7 > b->unk0_7)
return TRUE;
return 1;
if (a->unk0_7 < b->unk0_7)
return FALSE;
return 0;
if (a->unk0_0 > b->unk0_0)
return TRUE;
return 1;
if (a->unk0_0 < b->unk0_0)
return FALSE;
return 0;
break;
case 2:
if (a->unk0_0 > b->unk0_0)
return TRUE;
return 1;
if (a->unk0_0 < b->unk0_0)
return FALSE;
return 0;
if (a->unk0_7 > b->unk0_7)
return TRUE;
return 1;
if (a->unk0_7 < b->unk0_7)
return FALSE;
return 0;
if (a->unk2 > b->unk2)
return TRUE;
return 1;
if (a->unk2 < b->unk2)
return FALSE;
return 0;
if (a->words[0] > b->words[0])
return TRUE;
return 1;
if (a->words[0] < b->words[0])
return FALSE;
return 0;
if (a->words[1] > b->words[1])
return TRUE;
return 1;
if (a->words[1] < b->words[1])
return FALSE;
return TRUE;
return 0;
return 1;
}
return Random() & 1;
}