Don't truncate player name in savefile name or log message.
The player name is stored in whoami[], which is length 80 in most games (1024 in rogue5). Only the first 10 chars were used to create file_name, because that buffer is the same length. Increasing the size of file_name to 256 permits using all of whoami. The name is also no longer truncated to 20 chars when writing the log. All games should now be able to handle 79-character names without collisions. Anything more would break save compatibility.
This commit is contained in:
parent
082cd54126
commit
67ec840c3c
16 changed files with 23 additions and 23 deletions
|
|
@ -428,7 +428,7 @@ extern int dnum; /* Dungeon number */
|
|||
extern int door_stop; /* Stop running when we pass a door */
|
||||
extern struct delayed_action d_list[20];
|
||||
extern int fight_flush; /* True if toilet input */
|
||||
extern char file_name[80]; /* Save file name */
|
||||
extern char file_name[256]; /* Save file name */
|
||||
extern int firstmove; /* First move after setting door_stop */
|
||||
extern int food_left; /* Amount of food in hero's stomach */
|
||||
extern char fruit[80]; /* Favorite fruit */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue