mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-11-10 07:12:03 +00:00
Upgrades P_PatchInfoTables to use 4 digit tempnames, suppoing up to 9999 freeslots
This commit is contained in:
parent
e66eaf001e
commit
c8cec767d5
1 changed files with 3 additions and 3 deletions
|
@ -20097,7 +20097,7 @@ void P_PatchInfoTables(void)
|
|||
INT32 i;
|
||||
char *tempname;
|
||||
|
||||
#if NUMSPRITEFREESLOTS > 1000
|
||||
#if NUMSPRITEFREESLOTS > 9999 //tempname numbering actually starts at SPR_FIRSTFREESLOT, so the limit is actually 9999 + SPR_FIRSTFREESLOT-1, but the preprocessor doesn't understand enums, so its left at 9999 for safety
|
||||
#error "Update P_PatchInfoTables, you big dumb head"
|
||||
#endif
|
||||
|
||||
|
@ -20105,8 +20105,8 @@ void P_PatchInfoTables(void)
|
|||
for (i = SPR_FIRSTFREESLOT; i <= SPR_LASTFREESLOT; i++)
|
||||
{
|
||||
tempname = sprnames[i];
|
||||
tempname[0] = 'F';
|
||||
tempname[1] = (char)('0' + (char)((i-SPR_FIRSTFREESLOT+1)/100));
|
||||
tempname[0] = (char)('0' + (char)((i-SPR_FIRSTFREESLOT+1)/1000));
|
||||
tempname[1] = (char)('0' + (char)(((i-SPR_FIRSTFREESLOT+1)/100)%10));
|
||||
tempname[2] = (char)('0' + (char)(((i-SPR_FIRSTFREESLOT+1)/10)%10));
|
||||
tempname[3] = (char)('0' + (char)((i-SPR_FIRSTFREESLOT+1)%10));
|
||||
tempname[4] = '\0';
|
||||
|
|
Loading…
Reference in a new issue