Pasting Feature #92
Aliases: Pasting Feature
3 verbs · 24 properties · 0 children
Verbs
| Verb | Spec | Flags | Definer | Lines |
|---|---|---|---|---|
@paste | any any any | rxd | #92 | 26 |
|* | any any any | rxd | #92 | 9 |
@pasteto @paste-to | any none none | rxd | #92 | 18 |
Properties
| Property | Definer | Flags | Owner | Value |
|---|---|---|---|---|
warehouse | #74 | r | #36 | <clear> |
help_msg | #74 | rc | #36 | "The Pasting Feature is mostly useful to people with fancy clients (such as Emacs) or who connect using a windowing system that allows them to copy text they've already seen. It's intended to give people a way to quote verbatim text at other people in the room." |
feature_verbs | #74 | r | #36 | {"@paste", "|", "@paste-to"} |
feature_ok | #74 | r | #36 | <clear> |
drop_failed_msg | #5 | rc | #36 | <clear> |
drop_succeeded_msg | #5 | rc | #36 | <clear> |
odrop_failed_msg | #5 | rc | #36 | <clear> |
odrop_succeeded_msg | #5 | rc | #36 | <clear> |
otake_succeeded_msg | #5 | rc | #36 | <clear> |
otake_failed_msg | #5 | rc | #36 | <clear> |
take_succeeded_msg | #5 | rc | #36 | <clear> |
take_failed_msg | #5 | rc | #36 | <clear> |
value_base | #102 | r | #2 | <clear> |
damage_base | #102 | r | #2 | <clear> |
x_loc | #102 | r | #36 | <clear> |
y_loc | #102 | r | #36 | <clear> |
ansi_title | #102 | r | #36 | <clear> |
obvious | #102 | r | #36 | <clear> |
build_help | #102 | rc | #36 | <clear> |
key | #1 | c | #36 | <clear> |
aliases | #1 | rc | #36 | {"Pasting Feature"} |
description | #1 | rc | #36 | "Verbs useful to people using a windowing system to paste text at people." |
object_size | #1 | r | #36 | {4838, -1090650497} |
html | #1 | rc | #36 | <clear> |
Ancestry
Ancestors (nearest first): #74 Generic Feature Object → #5 generic thing → #102 subthing → #1 Root Class
Children: none
Call graph
Source
@paste
Referenced by
none
Source
1"Usage: @paste <prefix> <suffix>"; 2"Announce a series of entered lines to the room the player is in."; 3"Before the lines are quoted, player.paste_header is run through"; 4"$string_utils:pronoun_sub(), and if the result contains the player's"; 5"name, it is used as a header. Otherwise player.name centered in a"; 6"line of dashes is used."; 7"A footer comes afterwards, likewise derived from player.paste_footer."; 8"<prefix> and <suffix> are placed before and after each line."; 9""; 10"This verb is, as one might guess, designed for pasting text to MOO using"; 11"GnuEmacs or a windowing system. You should remember that after you"; 12"have pasted the lines in, you must type . on a line by itself, or you'll"; 13"sit around waiting for $command_utils:read_lines() to finish _forever_."; 14{?prefix = "", ?suffix = ""} = args; 15lines = $command_utils:read_lines(); 16header = $string_utils:pronoun_sub_secure($code_utils:verb_or_property(player, "paste_header"), "") || $string_utils:center(player.name, 75, "-"); 17to_tell = {header}; 18for line in (lines) 19to_tell = listappend(to_tell, (prefix + line) + suffix); 20endfor 21to_tell = listappend(to_tell, $string_utils:pronoun_sub_secure($code_utils:verb_or_property(player, "paste_footer"), "") || $string_utils:center("finished", 75, "-")); 22for thing in (player.location.contents) 23(ticks_left() < 4000) && suspend(0); 24thing:tell_lines(to_tell); 25endfor 26player:tell("Done @pasting.");
|*
Referenced by
none
Source
1"Echo a line prefaced by a vertical bar."; 2"Usage:"; 3" |message"; 4"Example:"; 5" Hacker wants to echo to the room what he just saw. He enters (either by hand, or with Emacs or a windowing system):"; 6" |Haakon has disconnected."; 7" The room sees:"; 8" Hacker | Haakon has disconnected."; 9player.location:announce_all((((player.name + " | ") + verb[2..$]) + " ") + argstr);
@pasteto @paste-to
Referenced by
none
Source
1"Syntax: @paste-to <player>"; 2""; 3"Which will then prompt you for the lines to privately send to <player>. The lines will be surrounded by a default footer and header."; 4target = $string_utils:match_player(dobjstr); 5$command_utils:player_match_result(target, dobjstr); 6if (!valid(target)) 7return; 8endif 9prefix = ""; 10suffix = ""; 11lines = $command_utils:read_lines(); 12to_tell = {$string_utils:center("Private message from " + player.name, 75, "-")}; 13for line in (lines) 14to_tell = listappend(to_tell, (prefix + line) + suffix); 15endfor 16to_tell = listappend(to_tell, $string_utils:center("end message", 75, "-")); 17target:tell_lines(to_tell); 18player:tell("Done @pasting.");