mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Allow for marking Emblems as "not a Medal" via SOC definition
Also remove long-unused `hint` string
This commit is contained in:
parent
47901939d5
commit
ff1574f80f
3 changed files with 12 additions and 16 deletions
|
|
@ -2124,14 +2124,6 @@ void reademblemdata(MYFILE *f, INT32 num)
|
||||||
word2 = tmp += 2;
|
word2 = tmp += 2;
|
||||||
value = atoi(word2); // used for numerical settings
|
value = atoi(word2); // used for numerical settings
|
||||||
|
|
||||||
// Up here to allow lowercase in hints
|
|
||||||
if (fastcmp(word, "HINT"))
|
|
||||||
{
|
|
||||||
while ((tmp = strchr(word2, '\\')))
|
|
||||||
*tmp = '\n';
|
|
||||||
deh_strlcpy(emblemlocations[num-1].hint, word2, sizeof (emblemlocations[num-1].hint), va("Emblem %d: hint", num));
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
strupr(word2);
|
strupr(word2);
|
||||||
|
|
||||||
if (fastcmp(word, "TYPE"))
|
if (fastcmp(word, "TYPE"))
|
||||||
|
|
@ -2172,6 +2164,8 @@ void reademblemdata(MYFILE *f, INT32 num)
|
||||||
|
|
||||||
emblemlocations[num-1].var = get_number(word2);
|
emblemlocations[num-1].var = get_number(word2);
|
||||||
}
|
}
|
||||||
|
else if (fastcmp(word, "NOTMEDAL"))
|
||||||
|
emblemlocations[num-1].notMedal = (boolean)(i != 0 || word2[0] == 'T' || word2[0] == 'Y');
|
||||||
else
|
else
|
||||||
deh_warning("Emblem %d: unknown word '%s'", num, word);
|
deh_warning("Emblem %d: unknown word '%s'", num, word);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1067,6 +1067,8 @@ INT32 M_CountMedals(boolean all)
|
||||||
INT32 found = 0, i;
|
INT32 found = 0, i;
|
||||||
for (i = 0; i < numemblems; ++i)
|
for (i = 0; i < numemblems; ++i)
|
||||||
{
|
{
|
||||||
|
if (emblemlocations[i].notMedal)
|
||||||
|
continue;
|
||||||
if (!all && !gamedata->collected[i])
|
if (!all && !gamedata->collected[i])
|
||||||
continue;
|
continue;
|
||||||
found++;
|
found++;
|
||||||
|
|
|
||||||
|
|
@ -76,7 +76,7 @@ struct emblem_t
|
||||||
UINT16 color; ///< skincolor to use
|
UINT16 color; ///< skincolor to use
|
||||||
INT32 var; ///< If needed, specifies information on the target amount to achieve (or target skin)
|
INT32 var; ///< If needed, specifies information on the target amount to achieve (or target skin)
|
||||||
char *stringVar; ///< String version
|
char *stringVar; ///< String version
|
||||||
char hint[110]; ///< Hint for emblem hints menu
|
boolean notMedal; ///< Not a Medal?
|
||||||
};
|
};
|
||||||
|
|
||||||
// Unlockable information
|
// Unlockable information
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue