ANSI Help #96
Aliases: ANSI Help, ah
1 verbs · 23 properties · 0 children
Verbs
| Verb | Spec | Flags | Definer | Lines |
|---|---|---|---|---|
ansi_log | this none this | rxd | #96 | 15 |
Properties
| Property | Definer | Flags | Owner | Value |
|---|---|---|---|---|
ansi-index | #96 | r | #36 | {"*index*", "ANSI Help Topics"} |
ansi-options | #96 | r | #36 | list of 72{"You can customize the way the ANSI Player Class works with the @ansi-options", "command. The format of this command is:", "", "@ansi-option shows the ansi options", "@ansi-option <option> [is] <value> sets <option> to <value>", "@ansi-option <option>=<value> sets <option> to <value>", "@ansi-option +<option> sets <option>", "@ansi-option -<option> resets <option> (equiv. to <option>=0)", "@ansi-option !<option> resets <option> (equiv. to <option>=0)", "@ansi-option <option> displays value of <option>", "", "The ansi options available at this time are:", "", " [bold][green]colors[normal] This option specifies whether the MOO will display", " color sequences (such as [[null]blue] and [[null]red]).", "", " [bold][green]blinking[normal] This option specifies whether the MOO will allow things to", " blink on and off. Most people find this annoying so they", " keep this off most of the time.", "", " [bold][green]bold[normal] This option specifies whether the MOO will allow bright", " colors. This probably isn't very useful unless you happen to", " have a hangover (maybe from a MOO bash, right Chapman ;) and", " the bright colors are hurting your eyes or something.", " (Or unless you're using a stupid windoze client that", " bolds as cyan.. gimme the name of a good freeware one", " and I'll be happy.. -Grant)", "", " [bold][green]misc[normal] This option specifies whether the MOO should display all the", " ANSI codes not covered by the ones above. This should usually", " be on if any of the above ones are on and will probably cause", " some very strange effects if it's not.", "", " [bold][green]extra[normal] This option specifies whether the MOO will send certain", " non-printable characters. So far, this option only includes", " beeps. NOTE: these will probably work even if your terminal", " is not ANSI compatable.", "", " [bold][green]all[normal] This turns on all of the above options. Equivalent to", " '@ansi-options -none' except that it automatically does an", " '@ansi-options -ignore'.", "", " [bold][green]none[normal] This turns off all of the above options. Equivalent to", " @ansi-options -all", "", " [bold][green]escape[normal] This option specifies what character the MOO will send for", " an escape character. The default is an ASCII character 27", " but it can be set to another string in case control characters", " won't get through to your terminal (like say if you are", " multimooing from another MOO or something, see 'help", " ansi-multimooing' for more information on that.)", "", " [bold][green]ignore[normal] This option overrides all the other options and tells the", " MOO to completely ignore any ANSI codes. This means that you", " will see the actual codes (like [[null]blue] or [[null]normal]) instead", " of having them either translated or stripped out like normal.", " This will probably screw up the line wrapping, text centering", " and a bunch of other things and will probably be very spammy", " but it's useful for checking the value of properties and", " other things.", "", " [bold][green]no_connect_status[normal]", " This option specifies whether the ANSI status message", " will be displayed when you log on.", "", " [bold][green]html[normal] This option will translate some of the ANSI codes to HTML", " for clients that interpret inline HTML. It also", " turns on HTML service through description() verbs.", "", " [bold][green]filter_tags[normal] This option will make words encased in < >", " readable when using an HTML client that interprets those", " structures as tags and hides them."} |
ansi-codes | #96 | r | #36 | list of 39{"The ANSI Player Class works by either translating codes into the ANSI sequences for them, or by stripping them out before sending the rest of the text to the player. An ANSI code is made up of the name of the code with a pair of brackets ([]'s) around it. Note to put codes into the documentation, they had to be put with a [[null]null] in between the letters, so something like [[[null]null]green] had to be written (and to make that.. sigh)", "", "These codes can be used in almost anything. MOOmail, messages, names, descriptions, and pages are all good places to put codes. ANSI codes are *not* allowed in player's names though because of all the problems this might cause. You can, however, use the new @ansi-title verb to put codes in your name.", "", "The codes are seperated into 5 main groups:", "", " [bold][yellow]colors[normal] Codes that change the text to another color. These include:", " [[null]red], [[null]green], [[null]yellow], [[null]blue], [[null]purple], [[null]cyan],", " [[null]gray], and [[null]white]. You can also use [[null]magenta] instead", " of [[null]purple] and [[null]grey] instead of [[null]gray] but this isn't", " recommended. NOTE: [[null]gray] implies a [[null]bold] so if you have:", " [[null]gray]This is gray. [[null]red]This is red.[[null]normal]", " The 'This is red.' will be bright red, you must put an", " [[null]unbold] in front of it if you want it to be dark red.", " These can be turned off with '@ansi-options -colors'.", "", " [bold][yellow]bold[normal] Codes that make the text bright or not bright. These include:", " [[null]bold] and [[null]unbold]. You can also use [[null]bright] and", " [[null]unbright] but, again, this is not recommended. These can be", " turned off with '@ansi-options -bold'. This can be used to make", " bright colors by putting a [[null]bold] in front of the color.", " (for example, in: [[null]green]A[[null]bold]B[[null]red]C[[null]unbold]D[[null]normal]", " the A would be dark green, the B would be bright green, the C", " would be bright red, and the D would be dark red)", "", " [bold][yellow]blinking[normal] Codes that turn on and off the blinking. These include:", " [[null]blink] and [[null]unblink]. They can be turned off with", " '@ansi-options -blinking'.", "", " [bold][yellow]misc.[normal] All the codes not covered by the ones above. These include:", " [[null]underline] and [[null]inverse]. NOTE: [[null]underline]", " does not actually underline text on most computers. These can", " be turned off with '@ansi-options -misc'.", "", " [bold][yellow]extra[normal] Codes that are not really ANSI and may work even if your", " terminal is not ANSI compatable . These include:", " [[null]beep]. It can be turned off with '@ansi-options -extra'.", "", "With the HTML option turned on, only settings that can be recreated within a font tag will be translated. This is limited to colors, and an increase in font size for [[null]bold]."} |
ansi-multimooing | #96 | r | #36 | list of 3{"For those of you that are multimooing from another MOO (probably using Sunwiz's excellent MultiMOO PC) and your escape characters are getting stripped out, you can tell the MOO to send a certain string instead of an ASCII character 27 by typing: '@ansi-options escape <string>'. You will then have to set your terminal program to translate <string> into an escape character. I would suggest setting <string> to '~' or some other character that is very rarely used. You probably shouldn't tell anyone what character you are using though, because then they can clear your screen, reposition your cursor, and some other annoying things. To tell the MOO to start sending character 27's for the escape characters again, type '@ansi-options -escape'. ", "", "Other MOOs that have the ANSI PC or other color capability have their own method of transmitting colors, so you should probably set '@ansi-options +ignore' on all the MOOs except the one you are actually telnetting too, this is because inter-MOO connecting can't send escape characters, only ASCII text."} |
ansi-intro | #96 | r | #36 | list of 8{"This ANSI system was written and designed by Don Schwarz <darkowl@mcs.net> aka Dark_Owl. HTML interpretation was added by George Hager <geocorona@yahoo.com>. It is composed of an ANSI Player Class ($ansi_pc), an ANSI utility package ($ansi_utils), an ANSI help database ($ansi_help), and an ANSI option database ($ansi_options).", "It converts ANSI 'codes', which are composed of a word surrounded by brackets ([]'s), into ANSI sequences which are recognized by most terminal programs and are used to display text in certain colors, underlined, inverse, and to make text blink. Not all terminal programs support ANSI though so this will not work for everyone.", "", "You can put these ANSI codes in your descriptions, messages, mails, programs, and virtually anything else that is eventually sent through $player:notify(). See 'help ansi-codes' for a list of valid ANSI codes.", "", "The ANSI PC is controlled with the @ansi-options command, see 'help @ansi-options' for more information on it.", "", "To see a list of other ANSI help topics, see 'help ansi-index'."} |
@ansi-test | #96 | r | #36 | {"*verbdoc*", "$ansi_pc", "@ansi-test"} |
ansi-bugs | #96 | r | #36 | list of 5{"[bold][red]KNOWN BUGS:[normal]", " [bold][blue]1)[normal] Some terminal programs seem to act strangely with lines that start with a [[null]bold] code. I'm pretty sure this isn't a MOO problem so I can't do anything about it. I'd recommend always putting [[null]bold] codes *after* color codes, or if you're using TinyFugue, try typing \"/set emulation raw\".", " [bold][blue]2)[normal] You can still write in black with [[null]gray][[null]unbold]. Not a major problem, but it bugs me.", " [bold][blue]3)[normal] Some terminal programs seem to beep not only when they get a character 7, but also on every escape character they receive on the same line.", " [bold][blue]4)[normal] There's no way to set random replacements with @ansi-title."} |
ansi-programming | #96 | r | #36 | list of 52{"There are a few verbs and properties that programmers might need to know about when programming things that interface with the ANSI system. Some of the more useful ones include:", "", " $ansi_pc:ansi_option (STR option) - returns player's setting for <option>", " $ansi_pc:set_ansi_option (LIST - sets player's options", " options)", " $ansi_utils:add_noansi () - any text sent from the current task", " will not be translated by the ANSI PC.", " $ansi_utils:remove_noansi () - undoes a call to :add_noansi, this", " is not usually necessary because it", " gets removed from the queue when the", " task ends anyway.", " $ansi_utils.noansi_queue - list of tasks that are currently", " being ignored.", " $ansi_utils:contains_codes (STR text) returns true if <text> contains", " any ANSI codes.", " $ansi_utils:delete (STR text) - returns <text> with all the ANSI", " codes stripped.", " $ansi_utils:length (STR text) - returns the length of <text> not", " including the ANSI codes.", " $ansi_utils:index/rindex (STR - same as the builtins index() and", " text, STR text2[, NUM case] rindex() but ignore ANSI codes.", " $ansi_utils:cutoff (STR text, NUM - same as text[start..end] for strings", " start, NUM end) but ignores ANSI codes.", " $ansi_utils:cutoff_assign (STR - same as text[start..end] = replacement", " text, NUM start, NUM end, STR", " replacement)", " $ansi_utils:notify (OBJ plr, STR - Same as raw notify() but replaces", " line) ANSI.", " $ansi_utils:self_diagnostic () - Runs a diagnostic on the ANSI stuff.", " $ansi_utils:trusts (OBJ player) - Is <player> trusted by the ANSI stuff?", " $ansi_utils:cutoff_locs (STR text - Returns a list of the real starting and", " NUM start, NUM end) and ending locations.", " $ansi_utils:setadd (LIST l, ANY - Same as setadd() but doesn't add it if", " element) element is already in the list (ignoring", " ANSI codes)", " $ansi_utils:setremove (LIST l, - Same as setremove() but doesn't add it", " ANY element) if element is already in the list", " (ignoring ANSI codes)", " $ansi_utils:terminate_normal (STR - Returns text with a [[null]normal] code", " text) at the end.", " $ansi_utils:ansi_title (OBJ plr) - Returns <plr>'s name with ANSI codes.", " $ansi_utils:quote_ansi (STR text) - Puts [[null]null] codes in the middle of", " all the other codes so they don't show.", " $ansi_utils:update_player_codes - Should be run whenever <player>'s", " (OBJ player) options are changed.", "", "Trusted Users only:", " $ansi_utils:update_all () - Updates all the caches and regexps", " $ansi_utils:add_group (STR group) - adds <group> to the list of groups", " $ansi_utils:add_code (STR code, - adds <code> to the codes in group", " STR group, ANY sequence) <group> and set's it's ANSI sequence", " to <sequence>."} |
ansi-porting | #96 | r | #36 | list of 8{"[UPDATE 2002: This MOO is run from RPGCore, available at members.aol.com/geocorona/rpgmoo.html The core has ANSI pre-installed. The HTML package may be on a separate updater. The old information for obtaining ANSICore was removed because the links are no longer working.]", "", " NOTE: While the ANSI system is activated in the core, all players", " start out with the ANSI defaulting to off, so you will have to type", " '@ansi-options +all' before you can see any color.", "", "To install the ANSI system on an already existing MOO, you will need the", " installation script. This file should be uploaded into the MOO as a non-wizard (usually the second character of the wizard installing the ANSI) and will port the objects and give you instructions on how to start up the automatic setup program. [UPDATE The original installation script is no longer easy to find.]"} |
@ansi-setup | #96 | r | #36 | {"*verbdoc*", "$ansi_utils", "@ansi-setup"} |
ansi-log | #96 | r | #36 | {"*subst*", "%;this:ansi_log()"} |
ANSI | #96 | r | #36 | {"*forward*", "ansi-intro"} |
@ansi-status | #96 | r | #36 | {"*verbdoc*", "$ansi_pc", "@ansi-status"} |
@ansi-title | #96 | r | #36 | {"*verbdoc*", "$ansi_pc", "@ansi-title"} |
ansi-corehacks | #96 | r | #36 | list of 83{" +-------------+ O F", " | ANSI System |# S u o", " | v2.1 |# N E C e t r", " +_____________+# e n o t l e", " ", "", "", "", "", "", "", " s i r u a s", " object:verb change? t g e p w t", " +-+---------------------------+--------------------------------------------+", " |1| $string_utils:left | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |1| :right | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |1| :center | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |1| :columnize | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |1| :space | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |1| $guest:do_reset | Clearing props on $ansi_pc |X|_|X|X|_|_|_|", " |1| $prog:@list | Ignoring ANSI |X|_|X|X|_|_|_|", " |2| $login:notify | Stripping out ANSI |X|_|X|X|_|_|_|", " |2| :\"@who who\" | $ansi_utils:show_who_listing |X|_|X|X|_|_|_|", " |2| $m_a:display_seq_headers | Formatting |X|_|X|X|_|_|_|", " |2| $bmr:display_seq_headers | Formatting |X|_|X|X|_|_|_|", " |2| $generic_editor:list_line | ignore ANSI |X|_|X|X|_|_|_|", " |2| :fill_string | Redirect to $ansi_utils |X|_|X|X|_|_|_|", " |2| $player_db:insert | Stripping out ANSI |X|_|X|X|_|_|_|", " |2| $prog:@dump | Ignoring ANSI |*|_|X|_|_|_|_|", " |2| $bu:object_audit_string | Formatting |X|_|X|_|_|_|_|", " |2| :do_audit_item | Formatting |X|_|X|_|_|_|_|", " |3| $mail_agent:name | Terminate normal |X|_|X|_|_|_|_|", " |4| $string_utils:from_value | Terminate normal |X|_|_|_|_|_|_|", " |4| :print | Terminate normal |X|_|_|_|_|_|_|", " |4| $player:tell_contents | Formatting |X|_|X|_|_|_|_|", " |4| $cu:find_verbs_containing | Stripping out ANSI |X|_|_|_|_|_|_|", " |4| $player:send_self_netmail | Stripping out ANSI |X|_|_|_|_|_|_|", " | | or $mail_recipient_class | |#|#|#|#|#|#|#|", " | | | |_|_|_|_|_|_|_|", " |===================--- Popular but Non-Core verbs ---=====================|", " |4| MCC FO:xm | Terminate normal |_|_|_|_|_|_|_|", " |5| :organize_columns | Formatting |_|X|_|_|_|_|_|", " |5| :get_name | Colors in people's names |_|_|_|_|_|_|_|", " | | | |_|_|_|_|_|_|_|", " +-+---------------------------+--------------------------------------------+", " ", " +------------------+ +----------------------------------------+", " | X - done |# | 1 - Required for MOO operation |#", " | # - N/A |# | 2 - Necessary for things to work right |#", " | * - extra stuff |# | 3 - Possible security hazard |#", " | _ - not done |# | 4 - Fixes mild annoyance |#", " +__________________+# | 5 - Makes something look better |#", " ", "", "", "", "", "", "", "", "", "# +________________________________________+#", " ", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "#"} |
html-tags | #96 | rc | #36 | list of 3{"Every object in the MOO has an .html property, which can be viewed with the invocation of an object's :description() verb. To turn this option on, type \"@ansi-o +html\". This ANSI option also converts color ANSI codes to HTML, and converts [[null]bold] to font size 4.", "", "If your MOO client is set to interpret HTML tags, words enclosed by less/greater symbols may be lost on screen. Turn off this option in your client settings if it becomes a problem."} |
index | #30 | rc | #36 | <clear> |
index_cache | #30 | r | #36 | {"ansi-index"} |
key | #1 | c | #36 | 0 |
aliases | #1 | rc | #36 | {"ANSI Help", "ah"} |
description | #1 | rc | #36 | "A help database of the standard form in need of a description. See `help $generic_help'..." |
object_size | #1 | r | #36 | {26768, -1090650497} |
html | #1 | rc | #36 | <clear> |
Ancestry
Ancestors (nearest first): #30 Generic Help Database → #1 Root Class
Children: none
Call graph
Source
ansi_log
Referenced by
none
Source
1help = {}; 2linelen = player:linelen(); 3log = $ansi_utils.(verb); 4vmax = 8 + max(@$list_utils:map_builtin($list_utils:slice(log, 1), "length")); 5for x in (log) 6help = {@help, tostr($string_utils:left(tostr("Version ", x[1]), vmax), " ", $string_utils:left($time_utils:time_sub("$N, $Y", x[2]), 25), x[3])}; 7for l in ((typeof(x[4]) == LIST) ? x[4] | {x[4]}) 8for i in ($generic_editor:fill_string(l, (linelen - vmax) - 2)) 9help = {@help, tostr($string_utils:space(vmax + 2), i)}; 10endfor 11endfor 12help = {@help, ""}; 13$command_utils:suspend_if_needed(0); 14endfor 15return help;