PennMUSH Community

Changeset 441

Show
Ignore:
Timestamp:
08/13/06 00:10:18 (2 years ago)
Author:
pennmush
Message:

PennMUSH 1.7.7p21 Archival

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • 1.7.7/CHANGES.176

    r433 r441  
    1313 
    1414========================================================================== 
     15 
     16Version 1.7.6 patchlevel 14                     September 23, 2003 
     17 
     18Fixes: 
     19   * Fix to help @search2 by LeeLaLimaLLama@M*U*S*H. 
     20   * The max file descriptor could get stomped in some cases. [SW] 
     21   * Powers and toggles on destroyed objects are reset, as they  
     22     caused anomalous lsearch/haspower behavior. Report by Mordie@M*U*S*H. 
     23   * Changing channel privs and loading channels with objects no longer 
     24     permitted could cause crashes. Report by Septimus@SW RP Forum. 
     25 
    1526 
    1627Version 1.7.6 patchlevel 13                     August 11, 2003 
  • 1.7.7/CHANGES.177

    r439 r441  
    1818 
    1919========================================================================== 
     20 
     21Version 1.7.7 patchlevel 21                     September 23, 2003 
     22 
     23Major Changes: 
     24  * Attribute trees. Attributes may now be organized hierarchically 
     25    like files and directories in a filesystem, using the backtick (`) 
     26    character as the branch separator. Attribute access restrictions 
     27    propagate down trees. New wildcard ** is introduced to match 
     28    all attributes at all tree levels. Suggested by Tabbifli. [TAP] 
     29Locks: 
     30  * New framework for performing lock failure activities in hardcode. 
     31    As a proof-of-concept, the attributes FOLLOW_LOCK`FAILURE, 
     32    FOLLOW_LOCK`OFAILURE, FOLLOW_LOCK`AFAILURE do what you'd expect 
     33    when set on a potential leader.  Suggested by Sholevi@M*U*S*H. 
     34Channels: 
     35  * New per-channel flags NoTitles, NoNames, and NoCemit do what you'd 
     36    expect. Set them with @chan/privs. Based on suggestion by  
     37    Saturn@M3. 
     38  * @chan/recall/quiet omits timestamps. Suggested by Vadiv@M*U*S*H. 
     39Commands: 
     40  * 'help <wildcard-pattern>' now lists all help topics that match that  
     41    pattern.  By popular request. [MUX,SW]  
     42  * @flag/letter can be used to change or clear the one-letter alias for a  
     43    flag.  Suggested by Nymeria@M*U*S*H. [SW] 
     44  * @flag/list by God notes disabled flags. Suggested by Nymeria@M*U*S*H. [SW] 
     45Functions: 
     46  * rand() now comes in a two-argument (low,high) flavor, and randword() 
     47    selects a random word from a list. The latter is aliased to 
     48    pickrand() to match Mux's name. Patch by Luke@M*U*S*H. 
     49Minor Changes: 
     50  * Although we're Pueblo 2.50 compliant, go back to sending Pueblo 1.10 
     51    as the server version until everyone upgrades their clients so 
     52    they can handle the 2.50 string. Suggested by Shirow. 
     53  * The locate() function is no longer noisy (no longer notifies 
     54    the executor in addition to returning a value). Suggested by 
     55    Mystery8@ST:AW.  
     56  * @lock/interact now has a higher priority than other interaction 
     57    checks, so it will work for Wizards. Suggested by Viila@M*U*S*H. 
     58  * Tweaks to facilitate a Debian package of PennMUSH. [EEH] 
     59Fixes: 
     60  * max descriptor could get stomped in some cases. [SW] 
     61  * Removed extra struct def in hdrs/mushtype.h. Suggested by Kyle. 
     62  * Help tweak by Kevin@M*U*S*H. 
     63  * Fix to locks on players messing up their connection failure counts. 
     64    Reported by Luke@M*U*S*H. 
     65  * Fix to @entrances by Luke@M*U*S*H. 
     66  * Fix to Win32 not handling a missing minimal.db by Luke@M*U*S*H. 
     67  * The confirmation message for setting/clearing attribute flags would use 
     68    the flag name given as an argument, not neccessarily the the full name of 
     69    the flag. Reported by Vadiv@M*U*S*H.  [SW] 
     70  * Fix a potential memory leak in ident.c [SW] 
    2071 
    2172Version 1.7.7 patchlevel 20                     September 4, 2003 
  • 1.7.7/MANIFEST

    r439 r441  
    159159utils/mkcmds.sh.SH 
    160160utils/mkvershlp.pl 
     161utils/penn-install 
    161162utils/update-cnf.pl 
    162163utils/update.pl 
     
    170171game/names.cnf 
    171172game/restart 
     173game/data/README 
    172174game/log/README 
    173175game/save/README 
     
    188190game/txt/evt/pennmush.evt 
    189191game/txt/hlp/index.hlp 
     192game/txt/hlp/pennattr.hlp 
    190193game/txt/hlp/pennchat.hlp 
    191194game/txt/hlp/pennconf.hlp 
     
    236239test/testatree.pl 
    237240test/testhastype.pl 
     241test/testrand.pl 
  • 1.7.7/Makefile.SH

    r439 r441  
    6060GLOBAL_INSTALL=/usr/libexec/pennmush 
    6161 
     62# Where to install with 'make debianinstall' 
     63DEB_INSTALL=$(DESTDIR)/usr/share/games/pennmush/game 
     64DEB_BIN=$(DESTDIR)/usr/games 
     65 
    6266all: config.h options.h autogen game/mush.cnf 
    6367    @echo "Making all in src." 
     
    258262    @echo "** or symlink that to somewhere easier to run. You may wish to strip them." 
    259263 
     264debianinstall: install 
     265    (cd game/txt; make clean compose.sh) 
     266    $(INSTALLDIR) $(DEB_INSTALL) 
     267    $(CP) -R game/* $(DEB_INSTALL) 
     268    -rm -f $(DEB_INSTALL)/netmush $(DEB_INSTALL)/info_slave 
     269    $(INSTALL) config.sh $(DEB_INSTALL)/config.sh 
     270    $(INSTALL) src/netmud $(DEB_INSTALL)/netmush 
     271    $(INSTALL) src/info_slave $(DEB_INSTALL)/info_slave 
     272    $(INSTALL) utils/penn-install $(DEB_BIN)/penn-install 
     273    $(CHMOD) a+rX -R $(DEB_INSTALL) 
     274    $(CHMOD) a+rX $(DEB_BIN)/penn-install 
     275    @echo "** Files installed in $(DEB_INSTALL)." 
     276    @echo "** You can run penn-install to create a user directory." 
     277 
    260278!NO!SUBS! 
    261279chmod 755 Makefile 
  • 1.7.7/Patchlevel

    r439 r441  
    11Do not edit this file. It is maintained by the official PennMUSH patches. 
    2 This is PennMUSH 1.7.7p20 
     2This is PennMUSH 1.7.7p21 
  • 1.7.7/game/alias.cnf

    r417 r441  
    4747function_alias modulo mod 
    4848function_alias modulo modulus 
     49function_alias randword pickrand 
    4950 
    5051# For rhost compatibility 
  • 1.7.7/game/mushcnf.dst

    r433 r441  
    7777#compress_suffix .bz2 
    7878# 
    79 compress_program compress 
    80 uncompress_program uncompress 
    81 compress_suffix .Z 
     79compress_program gzip 
     80uncompress_program gunzip 
     81compress_suffix .gz 
    8282 
    8383# Room where new players are created. 
  • 1.7.7/game/restart

    r439 r441  
    2727if [ ! -f $CONF_FILE ]; then 
    2828  echo "CONF_FILE doesn't exist. It's: $CONF_FILE" 
     29  echo "Create $CONF_FILE from $GAMEDIR/mushcnf.dst" 
    2930  exit 1 
    3031fi 
  • 1.7.7/game/txt/compose.sh.SH

    r433 r441  
     1#!/bin/sh 
    12case $CONFIG in 
    23'') 
  • 1.7.7/game/txt/hlp/pennchat.hlp

    r423 r441  
    127127  * "open" - you may speak even if you aren't listening to the channel 
    128128  * "hide_ok" - you may hide from the channel who list. 
     129  * "notitles" - chantitles are not displayed in channel messages. 
     130  * "nonames" - player names are not displayed in channel messages. 
     131  * "nocemit" - @cemit is prohibited on the channel. 
    129132  Specifications may be combined, space-separated. Default is "player" 
    130133 
     
    143146  @channel/chown <channel> = <new owner> 
    144147 
    145   The "priv" switch changes the channel's access privileges. 
     148  The "priv" switch changes the channel's access privileges. Use !<priv> 
     149    to reset a privilege. 
    146150  The "quiet" switch turns the quiet status of a channel on and off. 
    147151  The "wipe" switch clears a channel of players without deleting it. 
  • 1.7.7/game/txt/hlp/penncmd.hlp

    r439 r441  
    12921292  @flag/delete <flag name> 
    12931293  @flag/alias <flag name>=<alias> 
     1294  @flag/letter <flag name>[=<letter>] 
    12941295  @flag/restrict <flag name>=[<setperms>], [<unsetperms>] 
    12951296  @flag/enable <flag name> 
     
    13061307    /enable re-enables a disabled flag 
    13071308    /alias adds a new alias for an existing flag 
     1309    /letter changes or removes a single-letter alias for an existing flag. 
    13081310    /restrict changes flag permissions (see help @flag2) 
    13091311    /delete deletes a flag completely, removing it from all objects 
     
    27652767                    this attribute will be matched down to its unique 
    27662768                    prefixes. This flag is primarily used internally. 
     2769  `                 This attribute is a branch. See: help ATTRIBUTE TREES 
    27672770& @sex 
    27682771  @sex <player> = <gender>   
     
    34573460  name of the object's owner.  May be abbreviated 'ex <object>'.  If the  
    34583461  attribute parameter is given, you will only see that attribute (good  
    3459   for looking at code). You can also wild-card match on attributes.  For  
    3460   example. to see all the attributes that began with a 'v' you could do  
    3461   ex <object>/v* 
     3462  for looking at code). You can also wild-card match on attributes.  
     3463  The * wildcard matches any number of characters except a backtick (`). 
     3464  The ? wildcard matches a single character except a backtick (`). 
     3465  The ** wildcard matches any number of characters, including backticks. 
     3466  For example. to see all the attributes that began with a 'v' you could do  
     3467  ex <object>/v** 
    34623468   
    34633469  The /brief switch is equivalent to the 'brief' command. 
     
    34683474    ignores the object's VISUAL flag (but not its attribute flags) 
    34693475  The /all switch shows the values of VEILED attributes. 
     3476 
     3477  See also: ATTRIBUTE TREES 
    34703478& follow 
    34713479  follow <object> 
  • 1.7.7/game/txt/hlp/pennfunc.hlp

    r439 r441  
    13601360  These functions return a list of attributes on <object> containing 
    13611361  <pattern> (or matching <regexp>).  <attrs> is a wildcard pattern for 
    1362   attribute names to search; if you want to search all attributes, use "*"
     1362  attribute names to search
    13631363 
    13641364  The list returned is similar to that returned by @grep/list 
     
    16911691   
    16921692  If a wildcarded attribute pattern is provided, only attribute names 
    1693   matching that pattern will be returned. 
    1694  
    1695   See also: nattr() 
     1693  matching that pattern will be returned. lattr() uses the same 
     1694  wildcards as examine (?, *, **). 
     1695 
     1696  See also: nattr(), examine 
    16961697& NATTR() 
    16971698& ATTRCNT() 
     
    26332634& RAND() 
    26342635  rand(<num>) 
    2635  
    2636   Rand returns an integer between 0 and num-1, inclusive. 
     2636  rand(<min>, <max>) 
     2637   
     2638  Return a random number. 
     2639   
     2640  The first form returns an integer between 0 and <num>-1, inclusive. 
     2641  The second returns an integer between <min> and <max>, inclusive. 
     2642 
    26372643  If called with an invalid argument, rand() returns an error message 
    26382644  beginning with #-1. 
     2645& RANDWORD() 
     2646& PICKRAND() 
     2647  randword(<list>[, <delim>]) 
     2648   
     2649  Returns a randomly selected element from <list>. <delim> is the list 
     2650  delimiter: if not specified, whitespace delimits the list. 
     2651   
     2652  pickrand() may be an alias for randword() on some servers. 
    26392653& REGEDIT() 
    26402654& REGEDITALL() 
  • 1.7.7/game/txt/hlp/penntop.hlp

    r429 r441  
    77  For the list of MUSH topics, type:              help topics 
    88  For an alphabetical list of all help entries:   help entries  
     9  For a list of entries that match a pattern:     help <wildcard> 
    910  For information about PennMUSH:                 help code 
    1011   
     
    228229 
    229230  To see the attributes that are set on you or on any of the objects you own, 
    230   you should use the "examine" command. This will list all of the attributes 
    231   and their contents. As this can get very spammy for any large object, you 
    232   can also examine specific attributes by using this format: 
    233     examine <object>/<attribute> 
     231  you should use the "examine" command. See 'help examine'. 
    234232   
    235233(continued in help attributes4) 
     
    251249 
    252250  See also: ATTRIB-OWNERSHIP, @set, examine, @atrchown, @atrlock, hasattr() 
    253           get(), v(), NON-STANDARD ATTRIBUTES, SETTING-ATTRIBUTES 
     251    get(), v(), NON-STANDARD ATTRIBUTES, SETTING-ATTRIBUTES, ATTRIBUTE TREES 
     252 
    254253& BEING KILLED 
    255254  
     
    867866  independent of object ownership.  
    868867   
    869   See also: ATTRIBUTES, ATTRIB-OWNERSHIP, Attribute Functions 
     868  See also: ATTRIBUTES, ATTRIB-OWNERSHIP, Attribute Functions,  
     869     ATTRIBUTE TREES 
    870870& PARENT 
    871871& PARENTS 
  • 1.7.7/game/txt/hlp/pennv176.hlp

    r433 r441  
     1& 1.7.6p14 
     2Version 1.7.6 patchlevel 14                     September 23, 2003 
     3 
     4Fixes: 
     5   * Fix to help @search2 by LeeLaLimaLLama@M*U*S*H. 
     6   * The max file descriptor could get stomped in some cases. [SW] 
     7   * Powers and toggles on destroyed objects are reset, as they  
     8     caused anomalous lsearch/haspower behavior. Report by Mordie@M*U*S*H. 
     9   * Changing channel privs and loading channels with objects no longer 
     10     permitted could cause crashes. Report by Septimus@SW RP Forum. 
     11 
     12 
    113& 1.7.6p13 
    214Version 1.7.6 patchlevel 13                     August 11, 2003 
  • 1.7.7/game/txt/hlp/pennv177.hlp

    r439 r441  
    1 & 1.7.7p20 
     1& 1.7.7p21 
    22& changes 
    33This is a list of changes in this patchlevel which are probably of 
     
    1212be read in 'help patchlevels'. 
    1313 
     14Version 1.7.7 patchlevel 21                     September 23, 2003 
     15 
     16Major Changes: 
     17  * Attribute trees. Attributes may now be organized hierarchically 
     18    like files and directories in a filesystem, using the backtick (`) 
     19    character as the branch separator. Attribute access restrictions 
     20    propagate down trees. New wildcard ** is introduced to match 
     21    all attributes at all tree levels. Suggested by Tabbifli. [TAP] 
     22Locks: 
     23  * New framework for performing lock failure activities in hardcode. 
     24    As a proof-of-concept, the attributes FOLLOW_LOCK`FAILURE, 
     25    FOLLOW_LOCK`OFAILURE, FOLLOW_LOCK`AFAILURE do what you'd expect 
     26    when set on a potential leader.  Suggested by Sholevi@M*U*S*H. 
     27Channels: 
     28  * New per-channel flags NoTitles, NoNames, and NoCemit do what you'd 
     29    expect. Set them with @chan/privs. Based on suggestion by  
     30    Saturn@M3. 
     31  * @chan/recall/quiet omits timestamps. Suggested by Vadiv@M*U*S*H. 
     32Commands: 
     33  * 'help <wildcard-pattern>' now lists all help topics that match that  
     34    pattern.  By popular request. [MUX,SW]  
     35  * @flag/letter can be used to change or clear the one-letter alias for a  
     36    flag.  Suggested by Nymeria@M*U*S*H. [SW] 
     37  * @flag/list by God notes disabled flags. Suggested by Nymeria@M*U*S*H. [SW] 
     38Functions: 
     39  * rand() now comes in a two-argument (low,high) flavor, and randword() 
     40    selects a random word from a list. The latter is aliased to 
     41    pickrand() to match Mux's name. Patch by Luke@M*U*S*H. 
     42Minor Changes: 
     43  * Although we're Pueblo 2.50 compliant, go back to sending Pueblo 1.10 
     44    as the server version until everyone upgrades their clients so 
     45    they can handle the 2.50 string. Suggested by Shirow. 
     46  * The locate() function is no longer noisy (no longer notifies 
     47    the executor in addition to returning a value). Suggested by 
     48    Mystery8@ST:AW.  
     49  * @lock/interact now has a higher priority than other interaction 
     50    checks, so it will work for Wizards. Suggested by Viila@M*U*S*H. 
     51  * Tweaks to facilitate a Debian package of PennMUSH. [EEH] 
     52Fixes: 
     53  * max descriptor could get stomped in some cases. [SW] 
     54  * Removed extra struct def in hdrs/mushtype.h. Suggested by Kyle. 
     55  * Help tweak by Kevin@M*U*S*H. 
     56  * Fix to locks on players messing up their connection failure counts. 
     57    Reported by Luke@M*U*S*H. 
     58  * Fix to @entrances by Luke@M*U*S*H. 
     59  * Fix to Win32 not handling a missing minimal.db by Luke@M*U*S*H. 
     60  * The confirmation message for setting/clearing attribute flags would use 
     61    the flag name given as an argument, not neccessarily the the full name of 
     62    the flag. Reported by Vadiv@M*U*S*H.  [SW] 
     63  * Fix a potential memory leak in ident.c [SW] 
     64 
     65& 1.7.7p20 
    1466Version 1.7.7 patchlevel 20                     September 4, 2003 
    1567 
  • 1.7.7/game/txt/hlp/pennvOLD.hlp

    r439 r441  
    44194419 
    442044201.7.7: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 
    4421        19, 20 
    4422 1.7.6: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13 
     4421       19, 20, 21 
     44221.7.6: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 
    442344231.7.5: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 
    442444241.7.4: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 
  • 1.7.7/game/txt/index-files.pl

    r429 r441  
    1 #!/usr/local/bin/perl 
     1#!/usr/bin/perl 
    22# 
    33# index-files.pl - make an & index topic for events/news/help 
  • 1.7.7/hdrs/attrib.h

    r439 r441  
    3131extern int good_atr_name(char const *s); 
    3232extern ATTR *atr_match(char const *string); 
     33extern ATTR *atr_sub_branch(ATTR *branch); 
    3334extern void atr_new_add(dbref thing, char const *RESTRICT atr, 
    3435            char const *RESTRICT s, dbref player, int flags, 
     
    4142typedef int (*aig_func) (dbref, dbref, const char *, ATTR *, void *); 
    4243extern int atr_iter_get(dbref player, dbref thing, char const *name, 
    43             aig_func func, void *args); 
    44 extern int atr_iter_get_visible(dbref player, dbref thing, char const *name, 
    45                 aig_func func, void *args); 
     44            int mortal, aig_func func, void *args); 
    4645extern ATTR *atr_complete_match(dbref player, char const *atr, dbref privs); 
    4746extern void atr_free(dbref thing); 
     
    5857extern void do_atrchown(dbref player, char const *arg1, char const *arg2); 
    5958extern int string_to_atrflag(dbref player, const char *p); 
     59extern const char *atrflag_to_string(int mask); 
    6060extern void init_atr_name_tree(void); 
     61 
     62extern int can_read_attr_internal(dbref player, dbref obj, ATTR *attr); 
     63extern int can_write_attr_internal(dbref player, dbref obj, ATTR *attr, 
     64                   int safe); 
    6165extern unsigned const char *atr_get_compressed_data(ATTR *atr); 
    6266extern char *atr_value(ATTR *atr); 
     
    9094    extern ATTR attr[]; 
    9195 
     96/* external @wipe indicator (changes atr_clr() behaviour) */ 
     97    extern int we_are_wiping; 
     98 
    9299#define AL_ATTR(alist)          (alist) 
    93100#define AL_NAME(alist)          ((alist)->name) 
  • 1.7.7/hdrs/conf.h

    r439 r441  
    5454/* These CAN be modified, but it's heavily NOT suggested */ 
    5555#define PUEBLO_SEND "</xch_mudtext><img xch_mode=purehtml><xch_page clear=text>\n" 
    56 #define PUEBLO_HELLO "This world is Pueblo 2.50 Enhanced.\r\n" 
     56#define PUEBLO_HELLO "This world is Pueblo 1.10 Enhanced.\r\n" 
    5757 
    5858 
  • 1.7.7/hdrs/extchat.h

    r439 r441  
    135135#define CHANNEL_CANHIDE 0x40    /* Can non-DARK Wizards hide here? */ 
    136136#define CHANNEL_OPEN    0x80    /* Can you speak if you're not joined? */ 
     137#define CHANNEL_NOTITLES 0x100  /* Don't show titles of speakers */ 
     138#define CHANNEL_NONAMES 0x200   /* Don't show names of speakers */ 
     139#define CHANNEL_NOCEMIT 0x400   /* Disallow @cemit */ 
    137140#define CHANNEL_DEFAULT_FLAGS   (CHANNEL_PLAYER) 
    138141#define CL_JOIN 0x1 
     
    172175#define Channel_Admin(c) (ChanType(c) & CHANNEL_ADMIN) 
    173176#define Channel_CanHide(c) (ChanType(c) & CHANNEL_CANHIDE) 
     177#define Channel_NoTitles(c) (ChanType(c) & CHANNEL_NOTITLES) 
     178#define Channel_NoNames(c) (ChanType(c) & CHANNEL_NONAMES) 
     179#define Channel_NoCemit(c) (ChanType(c) & CHANNEL_NOCEMIT) 
    174180#define Chan_Ok_Type(c,o) \ 
    175181        ((IsPlayer(o) && Channel_Player(c)) || \ 
     
    187193     (Chan_Can_Access(c,p) && \ 
    188194     (eval_boolexp(p,ChanSpeakLock(c),p))) 
     195#define Chan_Can_Cemit(c,p) \ 
     196     (!Channel_NoCemit(c) && Chan_Can_Speak(c,p)) 
    189197#define Chan_Can_Modify(c,p) \ 
    190198     (Wizard(p) || (ChanCreator(c) == (p)) || \ 
     
    228236extern void do_chan_desc(dbref player, const char *name, const char *title); 
    229237extern void do_chan_title(dbref player, const char *name, const char *title); 
    230 extern void do_chan_recall(dbref player, const char *name, const char *lines); 
     238extern void do_chan_recall(dbref player, const char *name, const char *lines, 
     239               int quiet); 
    231240extern void do_chan_buffer(dbref player, const char *name, const char *lines); 
    232241extern void init_chat(void); 
  • 1.7.7/hdrs/externs.h

    r439 r441  
    465465                   int cs); 
    466466    extern int quick_wild(const char *RESTRICT tsr, const char *RESTRICT dstr); 
     467    extern int atr_wild(const char *RESTRICT tstr, const char *RESTRICT dstr); 
    467468#define regexp_match(s,d) regexp_match_case(s,d,1) 
    468469#define wild_match(s,d) wild_match_case(s,d,0) 
  • 1.7.7/hdrs/flags.h

    r435 r441  
    123123                 char *args_right[]); 
    124124extern void do_flag_add(dbref player, const char *name, char *args_right[]); 
    125  
     125extern void do_flag_letter(dbref player, const char *name, const char *letter); 
    126126 
    127127#define twiddle_flag_bitmask(bm,b,neg) (neg ? clear_flag_bitmask(bm,b) : \ 
  • 1.7.7/hdrs/lock.h

    r439 r441  
    3131 
    3232/* Our table of lock types, attributes, and default flags */ 
    33 typedef struct lock_info LOCKINFO; 
     33typedef struct lock_msg_info LOCKMSGINFO; 
    3434/** A lock. 
    3535 * This structure represents a lock in the table of lock types 
    3636 */ 
    37 struct lock_info { 
     37struct lock_msg_info { 
    3838  lock_type type;       /**< Type of lock */ 
    3939  const char *succbase;     /**< Base name of success attribute */ 
    4040  const char *failbase;     /**< Base name of failure attribute */ 
    41   int flags;            /**< Default flags */ 
    4241}; 
    4342 
     
    6261void free_locks(lock_list *ll); 
    6362int eval_lock(dbref player, dbref thing, lock_type ltype); 
     63void fail_lock(dbref player, dbref thing, lock_type ltype, const char *def, 
     64           dbref loc); 
    6465void do_unlock(dbref player, const char *name, lock_type type); 
    6566void do_lock(dbref player, const char *name, const char *keyname, 
  • 1.7.7/hdrs/mushdb.h

    r439 r441  
    8686#define Can_Read_Attr(p,x,a)   \ 
    8787   (!((a)->flags & AF_INTERNAL) && \ 
    88     (See_All(p) || \ 
    89      (!((a)->flags & AF_MDARK) && \ 
    90       (controls(p,x) || ((a)->flags & AF_VISUAL) || \ 
    91         (Visual(x) && eval_lock(p,x,Examine_Lock)) || \ 
    92        (!Mistrust(p) && (Owner((a)->creator) == Owner(p))))))) 
     88    (See_All(p) || can_read_attr_internal((p),(x),(a)))) 
    9389 
    9490/* can anyone access attribute a on object x? */ 
    9591#define Is_Visible_Attr(x,a)   \ 
    9692   (!((a)->flags & AF_INTERNAL) && \ 
    97      !((a)->flags & AF_MDARK) && \ 
    98       ((a)->flags & AF_VISUAL)) 
     93     can_read_attr_internal(NOTHING,(x),(a))) 
    9994 
    10095/* can p write attribute a on object x, assuming p may modify x?  
     
    10499 */ 
    105100#define Can_Write_Attr(p,x,a)  \ 
    106    (God(p) || \ 
    107     (!((a)->flags & AF_INTERNAL) && \ 
    108      !((a)->flags & AF_SAFE) && \ 
    109      (Wizard(p) || \ 
    110       (!((a)->flags & AF_WIZARD) && \ 
    111        (((a)->creator == Owner(p)) || !((a)->flags & AF_LOCKED)) \ 
    112    )))) 
     101   (can_write_attr_internal((p),(x),(a),1)) 
    113102#define Can_Write_Attr_Ignore_Safe(p,x,a)  \ 
    114    (God(p) || \ 
    115     (!((a)->flags & AF_INTERNAL) && \ 
    116      (Wizard(p) || \ 
    117       (!((a)->flags & AF_WIZARD) && \ 
    118        (((a)->creator == Owner(p)) || !((a)->flags & AF_LOCKED)) \ 
    119    )))) 
     103   (can_write_attr_internal((p),(x),(a),0)) 
    120104 
    121105 
  • 1.7.7/hdrs/mushtype.h

    r439 r441  
    3232 
    3333/* Boolexps and locks */ 
    34 struct boolexp; 
    3534typedef const char *lock_type; 
    3635typedef struct lock_list lock_list; 
  • 1.7.7/hdrs/switches.h

    r439 r441  
    6161#define SWITCH_IPRINT 60 
    6262#define SWITCH_JOIN 61 
    63 #define SWITCH_LIST 62 
    64 #define SWITCH_LOWERCASE 63 
    65 #define SWITCH_ME 64 
    66 #define SWITCH_MEMBERS 65 
    67 #define SWITCH_MOD 66 
    68 #define SWITCH_MORTAL 67 
    69 #define SWITCH_MOTD 68 
    70 #define SWITCH_MUTE 69 
    71 #define SWITCH_NAME 70 
    72 #define SWITCH_NO 71 
    73 #define SWITCH_NOEVAL 72 
    74 #define SWITCH_NOFLAGCOPY 73 
    75 #define SWITCH_NOISY 74 
    76 #define SWITCH_NOSIG 75 
    77 #define SWITCH_NOSPACE 76 
    78 #define SWITCH_NOTIFY 77 
    79 #define SWITCH_NUKE 78 
    80 #define SWITCH_OFF 79 
    81 #define SWITCH_ON 80 
    82 #define SWITCH_OUTSIDE 81 
    83 #define SWITCH_OVERRIDE 82 
    84 #define SWITCH_PAGING 83 
    85 #define SWITCH_PANIC 84 
    86 #define SWITCH_PARANOID 85 
    87 #define SWITCH_PLAYERS 86 
    88 #define SWITCH_PORT 87 
    89 #define SWITCH_PRESERVE 88 
    90 #define SWITCH_PRINT 89 
    91 #define SWITCH_PRIVS 90 
    92 #define SWITCH_PURGE 91 
    93 #define SWITCH_QUICK 92 
    94 #define SWITCH_QUIET 93 
    95 #define SWITCH_READ 94 
    96 #define SWITCH_REBOOT 95 
    97 #define SWITCH_RECALL 96 
    98 #define SWITCH_REGIONS 97 
    99 #define SWITCH_REGISTER 98 
    100 #define SWITCH_REMOVE 99 
    101 #define SWITCH_RENAME 100 
    102 #define SWITCH_RESTORE 101 
    103 #define SWITCH_RESTRICT 102 
    104 #define SWITCH_RETROACTIVE 103 
    105 #define SWITCH_ROOM 104 
    106 #define SWITCH_ROOMS 105 
    107 #define SWITCH_SEE 106 
    108 #define SWITCH_SEEFLAG 107 
    109 #define SWITCH_SELF 108 
    110 #define SWITCH_SEND 109 
    111 #define SWITCH_SET 110 
    112 #define SWITCH_SILENT 111 
    113 #define SWITCH_SKIPDEFAULTS 112 
    114 #define SWITCH_SPEAK 113 
    115 #define SWITCH_STATS 114 
    116 #define SWITCH_SUMMARY 115 
    117 #define SWITCH_TABLES 116 
    118 #define SWITCH_TAG 117 
    119 #define SWITCH_TELEPORT 118 
    120 #define SWITCH_TF 119 
    121 #define SWITCH_THINGS 120 
    122 #define SWITCH_TITLE 121 
    123 #define SWITCH_TRACE 122 
    124 #define SWITCH_UNCLEAR 123 
    125 #define SWITCH_UNFOLDER 124 
    126 #define SWITCH_UNGAG 125 
    127 #define SWITCH_UNHIDE 126 
    128 #define SWITCH_UNMUTE 127 
    129 #define SWITCH_UNTAG 128 
    130 #define SWITCH_UNTIL 129 
    131 #define SWITCH_URGENT 130 
    132 #define SWITCH_USEFLAG 131 
    133 #define SWITCH_WHAT 132 
    134 #define SWITCH_WHO 133 
    135 #define SWITCH_WIPE 134 
    136 #define SWITCH_WIZ 135 
    137 #define SWITCH_WIZARD 136 
    138 #define SWITCH_YES 137 
    139 #define SWITCH_ZONE 138 
     63#define SWITCH_LETTER 62 
     64#define SWITCH_LIST 63 
     65#define SWITCH_LOWERCASE 64 
     66#define SWITCH_ME 65 
     67#define SWITCH_MEMBERS 66 
     68#define SWITCH_MOD 67 
     69#define SWITCH_MORTAL 68 
     70#define SWITCH_MOTD 69 
     71#define SWITCH_MUTE 70 
     72#define SWITCH_NAME 71 
     73#define SWITCH_NO 72 
     74#define SWITCH_NOEVAL 73 
     75#define SWITCH_NOFLAGCOPY 74 
     76#define SWITCH_NOISY 75 
     77#define SWITCH_NOSIG 76 
     78#define SWITCH_NOSPACE 77 
     79#define SWITCH_NOTIFY 78 
     80#define SWITCH_NUKE 79 
     81#define SWITCH_OFF 80 
     82#define SWITCH_ON 81 
     83#define SWITCH_OUTSIDE 82 
     84#define SWITCH_OVERRIDE 83 
     85#define SWITCH_PAGING 84 
     86#define SWITCH_PANIC 85 
     87#define SWITCH_PARANOID 86 
     88#define SWITCH_PLAYERS 87 
     89#define SWITCH_PORT 88 
     90#define SWITCH_PRESERVE 89 
     91#define SWITCH_PRINT 90 
     92#define SWITCH_PRIVS 91 
     93#define SWITCH_PURGE 92 
     94#define SWITCH_QUICK 93 
     95#define SWITCH_QUIET 94 
     96#define SWITCH_READ 95 
     97#define SWITCH_REBOOT 96 
     98#define SWITCH_RECALL 97 
     99#define SWITCH_REGIONS 98 
     100#define SWITCH_REGISTER 99 
     101#define SWITCH_REMOVE 100 
     102#define SWITCH_RENAME 101 
     103#define SWITCH_RESTORE 102 
     104#define SWITCH_RESTRICT 103 
     105#define SWITCH_RETROACTIVE 104 
     106#define SWITCH_ROOM 105 
     107#define SWITCH_ROOMS 106 
     108#define SWITCH_SEE 107 
     109#define SWITCH_SEEFLAG 108 
     110#define SWITCH_SELF 109 
     111#define SWITCH_SEND 110 
     112#define SWITCH_SET 111 
     113#define SWITCH_SILENT 112 
     114#define SWITCH_SKIPDEFAULTS 113 
     115#define SWITCH_SPEAK 114 
     116#define SWITCH_STATS 115 
     117#define SWITCH_SUMMARY 116 
     118#define SWITCH_TABLES 117 
     119#define SWITCH_TAG 118 
     120#define SWITCH_TELEPORT 119 
     121#define SWITCH_TF 120 
     122#define SWITCH_THINGS 121 
     123#define SWITCH_TITLE 122 
     124#define SWITCH_TRACE 123 
     125#define SWITCH_UNCLEAR 124 
     126#define SWITCH_UNFOLDER 125 
     127#define SWITCH_UNGAG 126 
     128#define SWITCH_UNHIDE 127 
     129#define SWITCH_UNMUTE 128 
     130#define SWITCH_UNTAG 129 
     131#define SWITCH_UNTIL 130 
     132#define SWITCH_URGENT 131 
     133#define SWITCH_USEFLAG 132 
     134#define SWITCH_WHAT 133 
     135#define SWITCH_WHO 134 
     136#define SWITCH_WIPE 135 
     137#define SWITCH_WIZ 136 
     138#define SWITCH_WIZARD 137 
     139#define SWITCH_YES 138 
     140#define SWITCH_ZONE 139 
  • 1.7.7/hdrs/version.h

    r439 r441  
    1 #define VERSION "PennMUSH version 1.7.7 patchlevel 20 [09/04/2003]" 
    2 #define SHORTVN "PennMUSH 1.7.7p20
    3 #define NUMVERSION 001007007020 
     1#define VERSION "PennMUSH version 1.7.7 patchlevel 21 [09/23/2003]" 
     2#define SHORTVN "PennMUSH 1.7.7p21
     3#define NUMVERSION 001007007021 
  • 1.7.7/src/SWITCHES

    r439 r441  
    6060IPRINT 
    6161JOIN 
     62LETTER 
    6263LIST 
    6364LOWERCASE 
  • 1.7.7/src/attrib.c

    r439 r441  
    4747extern PRIV attr_privs[]; 
    4848 
     49/** A flag to show if we're in the middle of a @wipe (this changes 
     50 * behaviour for atr_clr()).  Yes, this is gross and ugly, but it 
     51 * seemed like a better idea than propogating a signature changes 
     52 * for atr_clr() and do_set_atr() through the entire codebase.  If 
     53 * you come up with a better way, PLEASE fix this... 
     54 */ 
     55int we_are_wiping; 
     56 
     57/** A string to hold the name of a missing prefix branch, set by 
     58 * can_write_attr_internal.  Again, gross and ugly.  Please fix. 
     59 */ 
     60static char missing_name[ATTRIBUTE_NAME_LIMIT + 1]; 
     61 
    4962/*======================================================================*/ 
    5063 
     
    8093 * A good attribute name is at least one character long, no more than 
    8194 * ATTRIBUTE_NAME_LIMIT characters long, and every character is a  
    82  * valid character. 
     95 * valid character. An attribute name may not start or end with a backtick. 
     96 * An attribute name may not contain multiple consecutive backticks. 
    8397 * \param s a string to test for validity as an attribute name. 
    8498 */ 
     
    90104  if (!s || !*s) 
    91105    return 0; 
     106  if (*s == '`') 
     107    return 0; 
     108  if (strstr(s, "``")) 
     109    return 0; 
    92110  for (a = (const unsigned char *) s; *a; a++, len++) 
    93111    if (!atr_name_table[*a]) 
    94112      return 0; 
     113  if (*(s + len - 1) == '`') 
     114    return 0; 
    95115  return len <= ATTRIBUTE_NAME_LIMIT; 
    96116} 
     
    104124{ 
    105125  return aname_hash_lookup(string); 
     126} 
     127 
     128/** Find the first attribute branching off the specified attribute. 
     129 * \param branch the attribute to look under 
     130 */ 
     131ATTR * 
     132atr_sub_branch(ATTR *branch) 
     133{ 
     134  char const *name, *n2; 
     135  size_t len; 
     136 
     137  name = AL_NAME(branch); 
     138  len = strlen(name); 
     139  for (branch = AL_NEXT(branch); branch; branch = AL_NEXT(branch)) { 
     140    n2 = AL_NAME(branch); 
     141    if (strlen(n2) <= len) 
     142      return NULL; 
     143    if (n2[len] == '`') { 
     144      if (!strncmp(n2, name, len)) 
     145    return branch; 
     146      else 
     147    return NULL; 
     148    } 
     149  } 
     150  return NULL; 
    106151} 
    107152 
     
    126171    return -1; 
    127172  return f; 
     173} 
     174 
     175/** Convert an attribute flag bitmask into a list of the full 
     176 * names of the flags. 
     177 * \param flags the attribute flags to display. 
     178 * \return a pointer to a static buffer with the full names of the flags. 
     179 */ 
     180const char * 
     181atrflag_to_string(int mask) 
     182{ 
     183  return privs_to_string(attr_privs, mask); 
    128184} 
    129185 
     
    334390/** Remove an attribute from an object. 
    335391 * This function clears an attribute from an object.  
     392 * Permission is denied if the attribute is a branch, not a leaf. 
    336393 * \param thing object to clear attribute from. 
    337394 * \param atr name of attribute to remove. 
     
    341398atr_clr(dbref thing, char const *atr, dbref player) 
    342399{ 
    343   ATTR *ptr, **prev
     400  ATTR *ptr, **prev, *sub
    344401  int comp = 0; 
     402  size_t len; 
    345403 
    346404  prev = &List(thing); 
     
    359417    return -1; 
    360418 
     419  len = strlen(AL_NAME(ptr)); 
     420  sub = atr_sub_branch(ptr); 
     421  if (!we_are_wiping && sub) 
     422    return -1; 
     423 
    361424  if (!IsPlayer(thing) && !(AL_FLAGS(ptr) & AF_NODUMP)) 
    362425    ModTime(thing) = mudtime; 
     
    372435  atr_free_list = ptr; 
    373436  AttrCount(thing)--; 
     437 
     438  if (we_are_wiping && sub) { 
    &nbs