Allow unlimited number of players
This is important for public servers. Setting the MAXPLAYERS sysconf value to 0 (or commenting it out) constructs the lock files with the player UID and player name, so each player may have one game at a time.
This commit is contained in:
+1
-1
@@ -2279,7 +2279,7 @@ int src;
|
|||||||
} else if (src == SET_IN_SYS && match_varname(buf, "MAXPLAYERS", 10)) {
|
} else if (src == SET_IN_SYS && match_varname(buf, "MAXPLAYERS", 10)) {
|
||||||
n = atoi(bufp);
|
n = atoi(bufp);
|
||||||
/* XXX to get more than 25, need to rewrite all lock code */
|
/* XXX to get more than 25, need to rewrite all lock code */
|
||||||
if (n < 1 || n > 25) {
|
if (n < 0 || n > 25) {
|
||||||
raw_printf("Illegal value in MAXPLAYERS (maximum is 25).");
|
raw_printf("Illegal value in MAXPLAYERS (maximum is 25).");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,6 +31,12 @@ EXPLORERS=*
|
|||||||
#SHELLERS=
|
#SHELLERS=
|
||||||
|
|
||||||
# Limit the number of simultaneous games (see also nethack.sh).
|
# Limit the number of simultaneous games (see also nethack.sh).
|
||||||
|
# Valid values are 0-25.
|
||||||
|
# Commenting this out or setting the value to 0 constructs lock files
|
||||||
|
# with UID and username, so each user may have one game at a time, but
|
||||||
|
# number of different players is not limited.
|
||||||
|
# Setting this to any other value constructs the lock files with
|
||||||
|
# letter and "lock" (eg. alock, block, ...)
|
||||||
MAXPLAYERS=10
|
MAXPLAYERS=10
|
||||||
|
|
||||||
# If not null, added to string "To get local support, " in the support
|
# If not null, added to string "To get local support, " in the support
|
||||||
|
|||||||
Reference in New Issue
Block a user