This is patch07 to PennMUSH 1.8.0. After applying this patch, you will have version 1.8.0p7 To apply this patch, save it to a file in your top-level MUSH directory, and do the following: patch -p1 < 1.8.0-patch07 make clean make install If you use GNU patch 2.2, you probably want the above to be 'patch -b -p1', not just 'patch -p1'. Unix (or cygwin) users need not worry about failed hunks in src/switchinc.c, hdrs/switches.h, hdrs/cmds.h, or hdrs/funs.h. These files are automatically rebuilt on compile. On the off chance they appear not to be, simply rm them and re-run make. Then @shutdown and restart your MUSH. - Alan/Javelin In this patch: Fixes: * lsearch() with no results no longer returns #-1. It still does so when there's an error. Suggested by Nathan Baum. [SW] * Improved messages for @link of exits. Report by Nathan Baum. [SW] * Restart script more portable to older bourne-like shells. Patch by Walker@M*U*S*H. * Fix to MinGW reboot. Patch by Nathan Baum. * Help fixes by Tyr@M*U*S*H, Talvo@M*U*S*H, Dizzy@Forgotten Time, and Trinsec@M*U*S*H. * @flag/add of a flag with a name that is a unique prefix of an existing flag wouldn't add the new flag. Reported by Mike Griffiths. [SW] * @config/set of an invalid option would still return a success message. Report by Sholevi@M*U*S*H. [SW] * sql() without a field delimiter defaulted to using the row delimiter, instead of a space. Report by Kali@M*U*S*H. * lock() didn't set user-defined locks properly. Report by Dahan@M*U*S*H. [SW] * Infinite loop in fraction() fixed. * FIXED players may no longer teleport through exits. Report by Anyasha@bDv2 * Better messages when attempting to wipe SAFE attributes. Suggested by Nathan Baum. Prereq: 1.8.0p6 *** 1_8_0.61/Patchlevel Sat, 25 Jun 2005 12:43:00 -0500 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.43.1.6 600) --- 1_8_0.71(w)/Patchlevel Mon, 29 Aug 2005 18:04:48 -0500 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.43.1.6 600) *************** *** 1,2 **** Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.8.0p6 --- 1,2 ---- Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.8.0p7 *** 1_8_0.61/game/txt/hlp/penntop.hlp Mon, 30 May 2005 15:53:13 -0500 dunemush (pennmush/13_penntop.hl 1.2.1.27.1.3.1.2.1.2.1.1.1.1.1.1.1.1.1.12.1.1.1.1.1.8.1.11.1.1.1.3.2.1 600) --- 1_8_0.71(w)/game/txt/hlp/penntop.hlp Sat, 27 Aug 2005 11:03:14 -0500 dunemush (pennmush/13_penntop.hl 1.2.1.27.1.3.1.2.1.2.1.1.1.1.1.1.1.1.1.12.1.1.1.1.1.8.1.11.1.1.1.3.2.1.1.1.1.1.1.1 600) *************** *** 1185,1191 **** string from left to right. Most characters stand for themselves in a pattern, and match the corresponding characters in the subject. ! There are two different sets of meta-characters: those that are recognized anywhere in the pattern except within square brackets, and those that are recognized in square brackets. Outside square brackets, the meta-characters are as follows: --- 1185,1191 ---- string from left to right. Most characters stand for themselves in a pattern, and match the corresponding characters in the subject. ! There are two different sets of meta-characters: those that are recognized anywhere in the pattern except within square brackets, and those that are recognized in square brackets. Outside square brackets, the meta-characters are as follows: *************** *** 1230,1236 **** (Cont'd in help regexp syntax4) & regexp syntax4 ! A backlash can also two useful assertions -- conditions that must be met at a particular point in a match: \b word boundary --- 1230,1236 ---- (Cont'd in help regexp syntax4) & regexp syntax4 ! A backlash can also be used for two useful assertions -- conditions that must be met at a particular point in a match: \b word boundary *************** *** 1516,1534 **** Standard attributes are set using @ = Nonstandard attributes are set using & = Attributes may also be set using @set =: Attributes are cleared using @ or & ! or with @wipe. ! Note that there is a difference between clearing an attribute ! and setting an attribute to a null value: @va me <--- wipes out my VA attribute @va me= <--- sets my VA attribute to be empty Empty attributes retain their flags and atrlock status. Wiped attributes are gone forever. ! See also ATTRIBUTES, NON-STANDARD ATTRIBUTES, @set, @wipe & SPOOFING Spoofing is the act of making other characters think that a person said or did something that they did not. This is very easy to --- 1516,1536 ---- Standard attributes are set using @ = Nonstandard attributes are set using & = Attributes may also be set using @set =: + or the set() function. Attributes are cleared using @ or & ! or with @wipe or wipe(). ! Note that if the empty_attrs configuration option is set ! (@config empty_attrs to check), there is a difference between ! clearing an attribute and setting an attribute to a null value: @va me <--- wipes out my VA attribute @va me= <--- sets my VA attribute to be empty Empty attributes retain their flags and atrlock status. Wiped attributes are gone forever. ! See also ATTRIBUTES, NON-STANDARD ATTRIBUTES, @set, @wipe, set(), wipe() & SPOOFING Spoofing is the act of making other characters think that a person said or did something that they did not. This is very easy to *** 1_8_0.61/game/txt/hlp/pennfunc.hlp Thu, 02 Jun 2005 17:07:27 -0500 dunemush (pennmush/16_pennfunc.h 1.2.1.50.1.1.1.1.1.2.1.7.1.8.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.26.1.1.1.1 600) --- 1_8_0.71(w)/game/txt/hlp/pennfunc.hlp Sat, 27 Aug 2005 13:33:40 -0500 dunemush (pennmush/16_pennfunc.h 1.2.1.50.1.1.1.1.1.2.1.7.1.8.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.26.1.1.1.1.1.1.1.1 600) *************** *** 2328,2336 **** & LVTHINGS() lvthings() ! This function returns the dbrefs of all connected and non-dark things ! inside an object. You must be in the object or control it to use this ! function. & LWHO() lwho() lwho() --- 2328,2335 ---- & LVTHINGS() lvthings() ! This function returns the dbrefs of all non-dark things inside an ! object. You must be in the object or control it to use this function. & LWHO() lwho() lwho() *************** *** 2941,2950 **** & PMATCH() pmatch() ! Given the partial name of a player, it returns that player's dbref number. This partial name completion works similarly to the partial name completion of the "page" command - i.e. it first attempts to match ! the normal names of all players (connected or not), and if that fails, it tries to match the partial names of connected players visible to the enactor. If no player is matched, it returns "#-1". If more than one match is possible for a partial name, it returns "#-2". --- 2940,2949 ---- & PMATCH() pmatch() ! Given the partial name of a connected player, returns that player's dbref number. This partial name completion works similarly to the partial name completion of the "page" command - i.e. it first attempts to match ! the full names of all players (connected or not), and if that fails, it tries to match the partial names of connected players visible to the enactor. If no player is matched, it returns "#-1". If more than one match is possible for a partial name, it returns "#-2". *************** *** 3593,3599 **** be careful to escape them with sqlescape(), like this: &SEL_GETID obj = SELECT id FROM mytable WHERE name = '[sqlescape(%0)]' ! &DOIT obj = $do *: ... [setq(0,u(SEL_GETID,%0))] ... See also: sqlescape(), @sql --- 3592,3598 ---- be careful to escape them with sqlescape(), like this: &SEL_GETID obj = SELECT id FROM mytable WHERE name = '[sqlescape(%0)]' ! &DOIT obj = $do *: ... [setq(0,sql(u(SEL_GETID,%0),~,|))] ... See also: sqlescape(), @sql *** 1_8_0.61/game/txt/hlp/penncmd.hlp Wed, 02 Feb 2005 14:07:54 -0600 dunemush (pennmush/18_penncmd.hl 1.2.1.1.1.47.1.1.1.1.1.3.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.10.1.1.1.1.1.1.1.1.1.1.1.47.1.1 600) --- 1_8_0.71(w)/game/txt/hlp/penncmd.hlp Sat, 27 Aug 2005 12:32:59 -0500 dunemush (pennmush/18_penncmd.hl 1.2.1.1.1.47.1.1.1.1.1.3.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.10.1.1.1.1.1.1.1.1.1.1.1.47.1.1.1.1 600) *************** *** 611,616 **** --- 611,619 ---- are parsed by default, but you can call foo/noeval. Note: the $-command needs to make allowances for the /noeval switch in it's matching. + Commands added with @command/add, like other standard commands, + are never case-sensitive (regardless of CASE flag on the attribute). + (examples in help @command3) & @command3 Examples: *** 1_8_0.61/game/restart Thu, 13 May 2004 11:43:05 -0500 dunemush (pennmush/39_restart 1.1.1.1.1.1.1.2.1.1.1.1.1.2.1.2.2.1.2.2.1.1.1.1.1.4 700) --- 1_8_0.71(w)/game/restart Wed, 10 Aug 2005 22:27:18 -0500 dunemush (pennmush/39_restart 1.1.1.1.1.1.1.2.1.1.1.1.1.2.1.2.2.1.2.2.1.1.1.1.1.4.3.1 700) *************** *** 36,47 **** ####################################################################### ! if [ -z $GAMEDIR ]; then echo "You must set GAMEDIR in the restart script." exit 1 fi ! if [ ! -d $GAMEDIR ]; then echo "GAMEDIR doesn't appear to be a directory. It's: $GAMEDIR" exit 1 fi --- 36,47 ---- ####################################################################### ! if [ -z "$GAMEDIR" ]; then echo "You must set GAMEDIR in the restart script." exit 1 fi ! if [ ! -d "$GAMEDIR" ]; then echo "GAMEDIR doesn't appear to be a directory. It's: $GAMEDIR" exit 1 fi *************** *** 49,55 **** cd $GAMEDIR echo Running from `pwd` ! if [ ! -f $CONF_FILE ]; then echo "CONF_FILE doesn't exist. It's: $CONF_FILE" echo "Create $CONF_FILE from $GAMEDIR/mushcnf.dst" exit 1 --- 49,55 ---- cd $GAMEDIR echo Running from `pwd` ! if [ ! -f "$CONF_FILE" ]; then echo "CONF_FILE doesn't exist. It's: $CONF_FILE" echo "Create $CONF_FILE from $GAMEDIR/mushcnf.dst" exit 1 *************** *** 75,81 **** # Find out what the compression program is, if any egrep -s "^compress_program[ ]*[A-Za-z0-9]" $CONF_FILE nocompress=$? ! if [ $nocompress -eq 0 ]; then COMPRESSOR=`egrep "^compress_program" $CONF_FILE | sed "s/[^ ]*[ ]*\(.*\)/\1/"` SUFFIX=`egrep "^compress_suffix" $CONF_FILE | sed "s/[^ ]*[ ]*\(.*\)/\1/"` fi --- 75,81 ---- # Find out what the compression program is, if any egrep -s "^compress_program[ ]*[A-Za-z0-9]" $CONF_FILE nocompress=$? ! if [ "$nocompress" -eq 0 ]; then COMPRESSOR=`egrep "^compress_program" $CONF_FILE | sed "s/[^ ]*[ ]*\(.*\)/\1/"` SUFFIX=`egrep "^compress_suffix" $CONF_FILE | sed "s/[^ ]*[ ]*\(.*\)/\1/"` fi *************** *** 88,94 **** mush=`ps uwwx | grep " $GAMEDIR/$CONF_FILE" | grep -v grep | wc -l` ! if [ $mush -gt 0 ]; then echo Mush already active or some other process is using $GAMEDIR/$CONF_FILE. exit 0 fi --- 88,94 ---- mush=`ps uwwx | grep " $GAMEDIR/$CONF_FILE" | grep -v grep | wc -l` ! if [ "$mush" -gt 0 ]; then echo Mush already active or some other process is using $GAMEDIR/$CONF_FILE. exit 0 fi *************** *** 98,104 **** echo Restarting Mush. ! if [ -r $PANICDIR/$PANICDB ]; then end="`tail -1 $PANICDIR/$PANICDB`" if [ "$end" = "***END OF DUMP***" ]; then echo "Recovering PANIC dump." --- 98,104 ---- echo Restarting Mush. ! if [ -r "$PANICDIR/$PANICDB" ]; then end="`tail -1 $PANICDIR/$PANICDB`" if [ "$end" = "***END OF DUMP***" ]; then echo "Recovering PANIC dump." *************** *** 113,129 **** rm -f log/*.log ! if [ -r data/$OUTDB$SUFFIX ]; then rm -f save/$INDB$SUFFIX.old mv -f data/$INDB$SUFFIX save/$INDB$SUFFIX.old mv data/$OUTDB$SUFFIX data/$INDB$SUFFIX else echo "No $OUTDB$SUFFIX found." ! if [ -r data/$INDB$SUFFIX ]; then echo "Using $INDB$SUFFIX." else echo "No $INDB$SUFFIX found." ! if [ -r save/$INDB$SUFFIX.old ]; then echo "Using save/$INDB$SUFFIX.old." cp save/$INDB$SUFFIX.old data/$INDB$SUFFIX else --- 113,129 ---- rm -f log/*.log ! if [ -r "data/$OUTDB$SUFFIX" ]; then rm -f save/$INDB$SUFFIX.old mv -f data/$INDB$SUFFIX save/$INDB$SUFFIX.old mv data/$OUTDB$SUFFIX data/$INDB$SUFFIX else echo "No $OUTDB$SUFFIX found." ! if [ -r "data/$INDB$SUFFIX" ]; then echo "Using $INDB$SUFFIX." else echo "No $INDB$SUFFIX found." ! if [ -r "save/$INDB$SUFFIX.old" ]; then echo "Using save/$INDB$SUFFIX.old." cp save/$INDB$SUFFIX.old data/$INDB$SUFFIX else *** 1_8_0.61/src/wiz.c Sat, 04 Jun 2005 22:07:33 -0500 dunemush (pennmush/b/23_wiz.c 1.44.1.1.1.1.1.2.1.7.1.1.1.1.1.1.1.1.1.1.1.8.1.2.2.2.1.2.1.1.1.1.1.1.1.2.1.1.1.2.2.17.1.9.1.30.1.3.1.2.1.1.1.4.1.1 660) --- 1_8_0.71(w)/src/wiz.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/b/23_wiz.c 1.44.1.1.1.1.1.2.1.7.1.1.1.1.1.1.1.1.1.1.1.8.1.2.2.2.1.2.1.1.1.1.1.1.1.2.1.1.1.2.2.17.1.9.1.30.1.3.1.2.1.1.1.4.1.1.1.1.1.2 660) *************** *** 538,550 **** return; } else { /* attempted teleport to an exit */ ! if (tport_control_ok(player, victim, Location(victim))) do_move(victim, to, MOVE_NORMAL); ! else { notify(player, T("Permission denied.")); ! notify_format(victim, ! T("%s tries to impose his will on you and fails."), ! Name(player)); } } } --- 538,554 ---- return; } else { /* attempted teleport to an exit */ ! if (tport_control_ok(player, victim, Location(victim)) ! && (Tel_Anything(player) || ! (Tel_Anywhere(player) && (player == victim)) || ! (!Fixed(Owner(victim)) && !Fixed(player)))) { do_move(victim, to, MOVE_NORMAL); ! } else { notify(player, T("Permission denied.")); ! if (victim != player) ! notify_format(victim, ! T("%s tries to impose his will on you and fails."), ! Name(player)); } } } *************** *** 711,717 **** first_free); } else { notify_format(player, ! T("%d objects = %d rooms, %d exits, %d things, %d players."), si->total - si->garbage, si->rooms, si->exits, si->things, si->players); } --- 715,722 ---- first_free); } else { notify_format(player, ! T ! ("%d objects = %d rooms, %d exits, %d things, %d players."), si->total - si->garbage, si->rooms, si->exits, si->things, si->players); } *************** *** 1294,1307 **** nresults = raw_search(executor, NULL, "PARENT", args[0], NULL, NULL, &results, pe_info); else ! nresults = raw_search(executor, args[0], args[1], args[2], args[3], args[4], ! &results, pe_info); if (nresults < 0) { safe_str("#-1", buff, bp); } else if (nresults == 0) { notify(executor, T("Nothing found.")); - safe_str("#-1", buff, bp); } else { int first = 1, n; if (!rev) { --- 1299,1312 ---- nresults = raw_search(executor, NULL, "PARENT", args[0], NULL, NULL, &results, pe_info); else ! nresults = ! raw_search(executor, args[0], args[1], args[2], args[3], args[4], ! &results, pe_info); if (nresults < 0) { safe_str("#-1", buff, bp); } else if (nresults == 0) { notify(executor, T("Nothing found.")); } else { int first = 1, n; if (!rev) { *************** *** 1409,1415 **** notify(player, T("Unknown type.")); return -1; } ! } else if (string_prefix("things", class) || string_prefix("objects", class)) { sclass = S_NAME; restrict_type = TYPE_THING; } else if (string_prefix("exits", class)) { --- 1414,1421 ---- notify(player, T("Unknown type.")); return -1; } ! } else if (string_prefix("things", class) ! || string_prefix("objects", class)) { sclass = S_NAME; restrict_type = TYPE_THING; } else if (string_prefix("exits", class)) { *************** *** 1721,1728 **** * \param type sitelock operation to do. */ void ! do_sitelock(dbref player, const char *site, const char *opts, const char *who, ! enum sitelock_type type) { if (!Wizard(player)) { notify(player, T("Your delusions of grandeur have been noted.")); --- 1727,1734 ---- * \param type sitelock operation to do. */ void ! do_sitelock(dbref player, const char *site, const char *opts, ! const char *who, enum sitelock_type type) { if (!Wizard(player)) { notify(player, T("Your delusions of grandeur have been noted.")); *** 1_8_0.61/src/set.c Sun, 16 Jan 2005 14:49:02 -0600 dunemush (pennmush/b/38_set.c 1.26.1.5.1.1.2.1.1.1.1.1.1.11.1.1.1.1.1.1.1.1.1.1.1.1.1.42 660) --- 1_8_0.71(w)/src/set.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/b/38_set.c 1.26.1.5.1.1.2.1.1.1.1.1.1.11.1.1.1.1.1.1.1.1.1.1.1.1.1.42.1.1 660) *************** *** 1124,1130 **** we_are_wiping = 1; if (!atr_iter_get(player, thing, pattern, 0, wipe_helper, NULL)) ! notify(player, T("No matching attributes.")); else notify(player, T("Attributes wiped.")); --- 1124,1130 ---- we_are_wiping = 1; if (!atr_iter_get(player, thing, pattern, 0, wipe_helper, NULL)) ! notify(player, T("No attributes wiped.")); else notify(player, T("Attributes wiped.")); *** 1_8_0.61/src/lock.c Mon, 08 Nov 2004 10:47:50 -0600 dunemush (pennmush/c/6_lock.c 1.17.1.13.1.1.1.1.1.23 660) --- 1_8_0.71(w)/src/lock.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/6_lock.c 1.17.1.13.1.1.1.1.1.23.1.1.1.1 660) *************** *** 734,742 **** unparse_dbref(thing), real_type); if (!IsPlayer(thing)) ModTime(thing) = mudtime; ! } else notify(player, T("Permission denied.")); ! } } } --- 734,745 ---- unparse_dbref(thing), real_type); if (!IsPlayer(thing)) ModTime(thing) = mudtime; ! } else { notify(player, T("Permission denied.")); ! free_boolexp(key); ! } ! } else ! free_boolexp(key); } } *** 1_8_0.61/src/funmath.c Thu, 02 Jun 2005 14:57:20 -0500 dunemush (pennmush/c/15_funmath.c 1.39.1.1.1.1.1.1.1.10.1.13 660) --- 1_8_0.71(w)/src/funmath.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/15_funmath.c 1.39.1.1.1.1.1.1.1.10.1.13.1.1 660) *************** *** 50,56 **** static MATH *math_hash_lookup(char *); static NVAL angle_to_rad(NVAL angle, const char *from); static NVAL rad_to_angle(NVAL angle, const char *to); ! static double frac(double v, int *RESTRICT n, int *RESTRICT d, double error); void init_math_hashtab(void); extern int format_long(long n, char *buff, char **bp, int maxlen, int base); --- 50,57 ---- static MATH *math_hash_lookup(char *); static NVAL angle_to_rad(NVAL angle, const char *from); static NVAL rad_to_angle(NVAL angle, const char *to); ! static double frac(double v, double *RESTRICT n, double *RESTRICT d, ! double error); void init_math_hashtab(void); extern int format_long(long n, char *buff, char **bp, int maxlen, int base); *************** *** 1145,1151 **** * \return -1.0 if (v < MIN || v > MAX || error < 0.0) | (v - n/d) / v | otherwise. */ static double ! frac(double v, int *RESTRICT n, int *RESTRICT d, double error) { /* Based on a routine found in netlib (http://www.netlib.org) by --- 1146,1152 ---- * \return -1.0 if (v < MIN || v > MAX || error < 0.0) | (v - n/d) / v | otherwise. */ static double ! frac(double v, double *RESTRICT n, double *RESTRICT d, double error) { /* Based on a routine found in netlib (http://www.netlib.org) by *************** *** 1164,1185 **** */ ! int D, N, t; int first = 1; double epsilon, r = 0.0, m; if (v < 0 || error < 0.0) return -1.0; *d = D = 1; ! *n = (int) v; N = *n + 1; do { if (!first) { if (r <= 1.0) r = 1.0 / r; ! N += *n * (int) r; ! D += *d * (int) r; *n += N; *d += D; } else --- 1165,1186 ---- */ ! double D, N, t; int first = 1; double epsilon, r = 0.0, m; if (v < 0 || error < 0.0) return -1.0; *d = D = 1; ! *n = floor(v); N = *n + 1; do { if (!first) { if (r <= 1.0) r = 1.0 / r; ! N += *n * floor(r); ! D += *d * floor(r); *n += N; *d += D; } else *************** *** 1203,1209 **** do { m *= 10.0; } while (m * epsilon < 1.0); ! epsilon = 1.0 / m * ((int) (0.5 + m * epsilon)); if (epsilon <= error) return epsilon; } while (r != 0.0); --- 1204,1210 ---- do { m *= 10.0; } while (m * epsilon < 1.0); ! epsilon = 1.0 / m * (floor(0.5 + m * epsilon)); if (epsilon <= error) return epsilon; } while (r != 0.0); *************** *** 1212,1218 **** FUNCTION(fun_fraction) { ! int num = 0, denom = 0; NVAL n; int sign = 0; --- 1213,1219 ---- FUNCTION(fun_fraction) { ! double num = 0, denom = 0; NVAL n; int sign = 0; *************** *** 1236,1245 **** if (sign) safe_chr('-', buff, bp); ! if (denom == 1) ! safe_integer(num, buff, bp); else ! safe_format(buff, bp, "%d/%d", num, denom); } FUNCTION(fun_isint) --- 1237,1246 ---- if (sign) safe_chr('-', buff, bp); ! if (fabs(denom - 1) < 1.0e-10) ! safe_format(buff, bp, "%.0lf", num); else ! safe_format(buff, bp, "%.0lf/%.0lf", num, denom); } FUNCTION(fun_isint) *** 1_8_0.61/src/fundb.c Thu, 26 May 2005 21:54:22 -0500 dunemush (pennmush/c/17_fundb.c 1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.7.1.3.1.3.1.3.1.2.1.2.1.3.2.1.2.1.2.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.3.1.1.2.2.2.1.1.1.1.1.1.42.1.14.1.1 660) --- 1_8_0.71(w)/src/fundb.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/17_fundb.c 1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.7.1.3.1.3.1.3.1.2.1.2.1.3.2.1.2.1.2.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.3.1.1.2.2.2.1.1.1.1.1.1.42.1.14.1.1.1.1.1.1 660) *************** *** 1227,1240 **** FUNCTION(fun_lock) { dbref it; ! char *p; ! lock_type ltype; ! if ((p = strchr(args[0], '/'))) ! *p++ = '\0'; it = match_thing(executor, args[0]); - ltype = get_locktype(p); if (nargs == 2) { if (!command_check_byname(executor, "@lock") || fun->flags & FN_NOSIDEFX) { --- 1227,1243 ---- FUNCTION(fun_lock) { dbref it; ! char *ltype = NULL; ! lock_type real_ltype; ! if ((ltype = strchr(args[0], '/'))) { ! *ltype++ = '\0'; ! upcasestr(ltype); ! } ! ! real_ltype = get_locktype(ltype); it = match_thing(executor, args[0]); if (nargs == 2) { if (!command_check_byname(executor, "@lock") || fun->flags & FN_NOSIDEFX) { *************** *** 1248,1256 **** return; } } ! if (GoodObject(it) && (ltype != NULL) ! && Can_Read_Lock(executor, it, ltype)) { ! safe_str(unparse_boolexp(executor, getlock(it, ltype), UB_DBREF), buff, bp); return; } safe_str("#-1", buff, bp); --- 1251,1260 ---- return; } } ! if (GoodObject(it) && (real_ltype != NULL) ! && Can_Read_Lock(executor, it, real_ltype)) { ! safe_str(unparse_boolexp(executor, getlock(it, real_ltype), UB_DBREF), ! buff, bp); return; } safe_str("#-1", buff, bp); *** 1_8_0.61/src/flags.c Tue, 30 Nov 2004 16:05:09 -0600 dunemush (pennmush/c/20_flags.c 1.1.1.1.1.1.1.1.1.1.1.1.1.6.1.2.1.1.1.1.1.2.2.2.2.1.2.1.1.3.1.2.1.1.1.1.1.1.1.1.1.3.1.9.1.2.2.1.1.2.1.56.1.12.1.1.1.29.1.2.1.2 660) --- 1_8_0.71(w)/src/flags.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/20_flags.c 1.1.1.1.1.1.1.1.1.1.1.1.1.6.1.2.1.1.1.1.1.2.2.2.2.1.2.1.1.3.1.2.1.1.1.1.1.1.1.1.1.3.1.9.1.2.2.1.1.2.1.56.1.12.1.1.1.29.1.2.1.2.2.1 660) *************** *** 1886,1893 **** FLAGSPACE *n; Flagspace_Lookup(n, ns); /* Don't double-add */ ! if ((f = match_flag_ns(n, strupper(name)))) ! return f; f = new_flag(); f->name = mush_strdup(strupper(name), "flag name"); f->letter = letter; --- 1886,1895 ---- FLAGSPACE *n; Flagspace_Lookup(n, ns); /* Don't double-add */ ! if ((f = match_flag_ns(n, strupper(name)))) { ! if (strcasecmp(f->name, name) == 0) ! return f; ! } f = new_flag(); f->name = mush_strdup(strupper(name), "flag name"); f->letter = letter; *** 1_8_0.61/src/filecopy.c Thu, 19 Aug 2004 06:46:33 -0500 dunemush (pennmush/c/21_filecopy.c 1.86 660) --- 1_8_0.71(w)/src/filecopy.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/21_filecopy.c 1.87 660) *************** *** 25,30 **** --- 25,32 ---- #include "log.h" #include "confmagic.h" + extern char confname[BUFFER_LEN]; /* From bsd.c */ + #ifdef WIN32 /* This is bad, but only for WIN32, which is bad anyway... */ *************** *** 207,213 **** --- 209,219 ---- if (!strcasecmp(rindex(FileName, '\\') + 1, "pennmush.exe")) { if (CopyFile("pennmush.exe", "pennmush_run.exe", FALSE)) { do_rawlog(LT_ERR, "Successfully copied executable, starting copy."); + #ifdef WIN32SERVICES execl("pennmush_run.exe", "pennmush_run.exe", "/run", NULL); + #else + execl("pennmush_run.exe", "pennmush_run.exe", confname, NULL); + #endif } } } *** 1_8_0.61/src/create.c Wed, 30 Jun 2004 15:00:16 -0500 dunemush (pennmush/c/27_create.c 1.27.1.3.1.1.1.1.1.1.1.2.1.1.1.1.1.27 660) --- 1_8_0.71(w)/src/create.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/27_create.c 1.27.1.3.1.1.1.1.1.1.1.2.1.1.1.1.1.28 660) *************** *** 182,188 **** void do_unlink(dbref player, const char *name) { ! dbref exit_l; long match_flags = MAT_EXIT | MAT_HERE | MAT_ABSOLUTE; if (!Wizard(player)) { --- 182,188 ---- void do_unlink(dbref player, const char *name) { ! dbref exit_l, old_loc; long match_flags = MAT_EXIT | MAT_HERE | MAT_ABSOLUTE; if (!Wizard(player)) { *************** *** 201,208 **** } else { switch (Typeof(exit_l)) { case TYPE_EXIT: Location(exit_l) = NOTHING; ! notify_format(player, T("Unlinked exit #%d."), exit_l); break; case TYPE_ROOM: Location(exit_l) = NOTHING; --- 201,210 ---- } else { switch (Typeof(exit_l)) { case TYPE_EXIT: + old_loc = Location(exit_l); Location(exit_l) = NOTHING; ! notify_format(player, T("Unlinked exit #%d (Used to lead to %s)."), ! exit_l, unparse_object(player, old_loc)); break; case TYPE_ROOM: Location(exit_l) = NOTHING; *************** *** 304,310 **** Location(thing) = room; /* notify the player */ ! notify_format(player, T("Linked exit #%d to #%d"), thing, room); break; case TYPE_PLAYER: case TYPE_THING: --- 306,313 ---- Location(thing) = room; /* notify the player */ ! notify_format(player, T("Linked exit #%d to %s"), thing, ! unparse_object(player, room)); break; case TYPE_PLAYER: case TYPE_THING: *** 1_8_0.61/src/conf.c Sun, 20 Mar 2005 13:48:57 -0600 dunemush (pennmush/c/31_conf.c 1.41.2.3.1.3.1.2.1.15.1.1.1.1.1.1.1.41.1.1.1.1 660) --- 1_8_0.71(w)/src/conf.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/31_conf.c 1.41.2.3.1.3.1.2.1.15.1.1.1.1.1.1.1.41.1.1.1.1.1.1 660) *************** *** 829,835 **** /* Was this "restrict_command "? If so, do it */ if (!strcasecmp(opt, "restrict_command")) { if (!restrictions) ! return 1; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; --- 829,835 ---- /* Was this "restrict_command "? If so, do it */ if (!strcasecmp(opt, "restrict_command")) { if (!restrictions) ! return 0; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; *************** *** 852,858 **** return 1; } else if (!strcasecmp(opt, "restrict_function")) { if (!restrictions) ! return 1; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; --- 852,858 ---- return 1; } else if (!strcasecmp(opt, "restrict_function")) { if (!restrictions) ! return 0; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; *************** *** 876,887 **** return 1; } else if (!strcasecmp(opt, "reserve_alias")) { if (!restrictions) ! return 1; reserve_alias(val); return 1; } else if (!strcasecmp(opt, "command_alias")) { if (!restrictions) ! return 1; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; --- 876,887 ---- return 1; } else if (!strcasecmp(opt, "reserve_alias")) { if (!restrictions) ! return 0; reserve_alias(val); return 1; } else if (!strcasecmp(opt, "command_alias")) { if (!restrictions) ! return 0; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; *************** *** 901,907 **** return 1; } else if (!strcasecmp(opt, "attribute_alias")) { if (!restrictions) ! return 1; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; --- 901,907 ---- return 1; } else if (!strcasecmp(opt, "attribute_alias")) { if (!restrictions) ! return 0; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; *************** *** 921,927 **** return 1; } else if (!strcasecmp(opt, "function_alias")) { if (!restrictions) ! return 1; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; --- 921,927 ---- return 1; } else if (!strcasecmp(opt, "function_alias")) { if (!restrictions) ! return 0; for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; *************** *** 944,950 **** char *comm, *file; int admin = !strcasecmp(opt, "ahelp_command"); if (!restrictions) ! return 1; /* Add a new help-like command */ if (source == 1) return 0; --- 944,950 ---- char *comm, *file; int admin = !strcasecmp(opt, "ahelp_command"); if (!restrictions) ! return 0; /* Add a new help-like command */ if (source == 1) return 0; *** 1_8_0.61/src/attrib.c Wed, 01 Dec 2004 09:25:29 -0600 dunemush (pennmush/c/40_attrib.c 1.15.1.2.1.5.1.1.1.3.1.3.1.2.1.2.1.2.2.1.1.2.1.2.1.2.1.1.1.3.1.1.1.1.1.1.3.43.1.15 660) --- 1_8_0.71(w)/src/attrib.c Mon, 29 Aug 2005 18:05:13 -0500 dunemush (pennmush/c/40_attrib.c 1.15.1.2.1.5.1.1.1.3.1.3.1.2.1.2.1.2.2.1.1.2.1.2.1.2.1.1.1.3.1.1.1.1.1.1.3.43.1.15.1.1.1.1 660) *************** *** 1554,1560 **** s ? atr_add(thing, name, s, player, (flags & 0x02) ? AF_NOPROG : NOTHING) : atr_clr(thing, name, player); if (res == AE_SAFE) { ! notify(player, T("That attribute is SAFE. Set it !SAFE to modify it.")); return 0; } else if (res == AE_BADNAME) { notify(player, T("That's not a very good name for an attribute.")); --- 1554,1561 ---- s ? atr_add(thing, name, s, player, (flags & 0x02) ? AF_NOPROG : NOTHING) : atr_clr(thing, name, player); if (res == AE_SAFE) { ! notify_format(player, T("Attribute %s is SAFE. Set it !SAFE to modify it."), ! name); return 0; } else if (res == AE_BADNAME) { notify(player, T("That's not a very good name for an attribute.")); *** 1_8_0.61/hdrs/version.h Sat, 25 Jun 2005 12:43:00 -0500 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17.1.45.1.7 660) --- 1_8_0.71(w)/hdrs/version.h Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17.1.45.1.7 660) *************** *** 1,4 **** #define VERSION "1.8.0" ! #define PATCHLEVEL "6" ! #define PATCHDATE "[06/24/2005]" ! #define NUMVERSION 1008000006 --- 1,4 ---- #define VERSION "1.8.0" ! #define PATCHLEVEL "7" ! #define PATCHDATE "[08/29/2005]" ! #define NUMVERSION 1008000007 *** 1_8_0.61/game/README Sat, 10 Jul 2004 09:53:09 -0500 dunemush (pennmush/g/13_README 1.6 660) --- 1_8_0.71(w)/game/README Wed, 10 Aug 2005 22:37:46 -0500 dunemush (pennmush/g/13_README 1.7 660) *************** *** 42,47 **** --- 42,53 ---- in mush.cnf) every time, since errors and other important messages get printed to that logfile. + After your first startup, it's a good idea to make some small + change to the database (e.g., @create an object) and then + do an @shutdown. Restart the game again and ensure that your + object is still present - this verifies that the server is + successfully dumping. + ============================================================================ Game Trouble-shooting *** 1_8_0.61/game/txt/hlp/pennvOLD.hlp Wed, 08 Jun 2005 18:16:15 -0500 dunemush (pennmush/g/30_pennvOLD.h 1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.2.1.5.1.1.1.1.1.1.1.1.1.1 660) --- 1_8_0.71(w)/game/txt/hlp/pennvOLD.hlp Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/g/30_pennvOLD.h 1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.2.1.5.1.1.1.1.1.1.1.1.1.1.1.1 660) *************** *** 4417,4423 **** For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.8.0: 0, 1, 2, 3, 4, 5, 6 1.7.7: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 --- 4417,4423 ---- For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.8.0: 0, 1, 2, 3, 4, 5, 6, 7 1.7.7: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 *** 1_8_0.61/game/txt/hlp/pennv180.hlp Sat, 25 Jun 2005 12:43:00 -0500 dunemush (pennmush/h/28_pennv180.h 1.1.1.2.1.1.1.2.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1 660) --- 1_8_0.71(w)/game/txt/hlp/pennv180.hlp Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/h/28_pennv180.h 1.1.1.2.1.1.1.2.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.1.1.1 660) *************** *** 1,4 **** ! & 1.8.0p6 & changes This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions --- 1,4 ---- ! & 1.8.0p7 & changes This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions *************** *** 11,16 **** --- 11,43 ---- A list of the patchlevels associated with each release can be read in 'help patchlevels'. + Version 1.8.0 patchlevel 7 August 29, 2005 + + Fixes: + * lsearch() with no results no longer returns #-1. It still does so when + there's an error. Suggested by Nathan Baum. [SW] + * Improved messages for @link of exits. Report by Nathan Baum. [SW] + * Restart script more portable to older bourne-like shells. + Patch by Walker@M*U*S*H. + * Fix to MinGW reboot. Patch by Nathan Baum. + * Help fixes by Tyr@M*U*S*H, Talvo@M*U*S*H, Dizzy@Forgotten Time, + and Trinsec@M*U*S*H. + * @flag/add of a flag with a name that is a unique prefix of an existing + flag wouldn't add the new flag. Reported by Mike Griffiths. [SW] + * @config/set of an invalid option would still return a success message. + Report by Sholevi@M*U*S*H. [SW] + * sql() without a field delimiter defaulted to using the row delimiter, + instead of a space. Report by Kali@M*U*S*H. + * lock() didn't set user-defined locks properly. Report by + Dahan@M*U*S*H. [SW] + * Infinite loop in fraction() fixed. + * FIXED players may no longer teleport through exits. Report by + Anyasha@bDv2 + * Better messages when attempting to wipe SAFE attributes. + Suggested by Nathan Baum. + + + & 1.8.0p6 Version 1.8.0 patchlevel 6 June 24, 2005 Fixes: *** 1_8_0.61/README.SQL Wed, 21 Jul 2004 11:20:20 -0500 dunemush (pennmush/h/15_README.SQL 1.2 660) --- 1_8_0.71(w)/README.SQL Wed, 10 Aug 2005 22:42:41 -0500 dunemush (pennmush/h/15_README.SQL 1.3 660) *************** *** 16,22 **** II. Mush configuration overview III. SQL setup tips ! I. Compiling withi MySQL The Configure script distributed with PennMUSH automatically detects the MySQL client library (libmysqlclient) and attempts to link --- 16,22 ---- II. Mush configuration overview III. SQL setup tips ! I. Compiling with MySQL The Configure script distributed with PennMUSH automatically detects the MySQL client library (libmysqlclient) and attempts to link *** 1_8_0.61/src/sql.c Sat, 10 Jul 2004 09:53:09 -0500 dunemush (pennmush/h/16_sql.c 1.8 660) --- 1_8_0.71(w)/src/sql.c Mon, 29 Aug 2005 18:05:14 -0500 dunemush (pennmush/h/16_sql.c 1.9 660) *************** *** 224,230 **** if (!delim_check(buff, bp, nargs, args, 2, &row_delim)) return; if (nargs < 3) ! field_delim = row_delim; else if (!delim_check(buff, bp, nargs, args, 3, &field_delim)) return; --- 224,230 ---- if (!delim_check(buff, bp, nargs, args, 2, &row_delim)) return; if (nargs < 3) ! field_delim = ' '; else if (!delim_check(buff, bp, nargs, args, 3, &field_delim)) return; *** 1_8_0.61/CHANGES.180 Sat, 25 Jun 2005 12:43:00 -0500 dunemush (pennmush/h/21_CHANGES.18 1.39 600) --- 1_8_0.71(w)/CHANGES.180 Mon, 29 Aug 2005 18:04:37 -0500 dunemush (pennmush/h/21_CHANGES.18 1.46 600) *************** *** 12,17 **** --- 12,43 ---- ========================================================================== + Version 1.8.0 patchlevel 7 August 29, 2005 + + Fixes: + * lsearch() with no results no longer returns #-1. It still does so when + there's an error. Suggested by Nathan Baum. [SW] + * Improved messages for @link of exits. Report by Nathan Baum. [SW] + * Restart script more portable to older bourne-like shells. + Patch by Walker@M*U*S*H. + * Fix to MinGW reboot. Patch by Nathan Baum. + * Help fixes by Tyr@M*U*S*H, Talvo@M*U*S*H, Dizzy@Forgotten Time, + and Trinsec@M*U*S*H. + * @flag/add of a flag with a name that is a unique prefix of an existing + flag wouldn't add the new flag. Reported by Mike Griffiths. [SW] + * @config/set of an invalid option would still return a success message. + Report by Sholevi@M*U*S*H. [SW] + * sql() without a field delimiter defaulted to using the row delimiter, + instead of a space. Report by Kali@M*U*S*H. + * lock() didn't set user-defined locks properly. Report by + Dahan@M*U*S*H. [SW] + * Infinite loop in fraction() fixed. + * FIXED players may no longer teleport through exits. Report by + Anyasha@bDv2 + * Better messages when attempting to wipe SAFE attributes. + Suggested by Nathan Baum. + + Version 1.8.0 patchlevel 6 June 24, 2005 Fixes: