# # Patch name: name-ntn # Patch version: 1 # Author's name: Flame # Author's email: flame@access.kuwait.net # Version of PennMUSH: 1.6.7-p6 # Date patch made: 09/02/1996 # Author is willing to support (yes/no): no # Patch format: diff -c # # # This is a contributed PennMUSH patch. Its use is subject to the # same restrictions found in PennMUSH's hdrs/copyrite.h file. # # No warranty is given for this patch. It is not necessarily going # to work on your system, with any version of PennMUSH other than # the one above, etc. # # If the author given above was willing to support the patch, you # should write to the author if you have any questions or problems. Do # *NOT* send email messages to Javelin or any PennMUSH mailing list about # this patch! # # Below this line is the author's description of the patch, # followed by the patch itself. If the patch is in context diff # format, you'll probably apply it by typing: patch < patchfile # in your top-level MUSH directory, unless instructed otherwise # below. # After applying this patch the content of NTN attribute will be shown next to the player's or object's name, if he has his NTN attribute set. for example if Flame types &ntn me=(standing next the window) then any player enters the room or types look or look through a transparent exit will see Contenst: Flame (standing next the window). So this is a great way to show players location inside a room. if nothing in ntn attribute he will see Contents: Flame There are alot of application for this idea. A player can show an action he is doing or an object he is carrying, like a weapon. i.e Player (weilding a phaser). A wizard can @lock this attribute and do great things or you can code it to a table to set the players NTN attribute to make it for example (sitting at the table)...Use your imagination :) *** src/look.orig Mon Sep 2 02:15:11 1996 --- src/look.c Mon Sep 2 02:29:40 1996 *************** *** 123,128 **** dbref loc; const char *contents_name; { dbref thing; dbref can_see_loc; /* check to see if he can see the location */ --- 123,130 ---- dbref loc; const char *contents_name; { + ATTR *b; + char *s; dbref thing; dbref can_see_loc; /* check to see if he can see the location */ *************** *** 139,145 **** notify(player, contents_name); DOLIST(thing, db[loc].contents) { if (can_see(player, thing, can_see_loc)) { ! notify(player, unparse_object(player, thing)); } } break; /* we're done */ --- 141,154 ---- notify(player, contents_name); DOLIST(thing, db[loc].contents) { if (can_see(player, thing, can_see_loc)) { ! b = (ATTR *) atr_get_noparent(thing, "NTN"); ! if (b !=NULL) ! { ! s = (char *) uncompress(b->value); ! notify(player, tprintf("%s %s",unparse_object(player,thing),s)); ! } ! else ! notify(player, tprintf("%s",unparse_object(player,thing))); } } break; /* we're done */ --Message-Boundary-29402--