Generic Feature Object #74

Parent #5Owner #36Flags read, fertileSource QuestCore.db

Aliases: Generic Feature Object, Generic .Features_Huh Object, Feature Object, .Features_Huh Object

10 verbs · 23 properties · 7 children

Verbs

VerbSpecFlagsDefinerLines
help_msgthis none thisrxd#7420
look_selfthis none thisrxd#748
using thisthis none thisrxd#7418
examine_commands_okthis none thisrxd#741
set_feature_okthis none thisrxd#745
hidden_verbsthis none thisrxd#7411
set_feature_verbsthis none thisrxd#745
initializethis none thisrxd#746
init_for_corethis none thisrxd#745
feature_removethis none thisrxd#741

Properties

PropertyDefinerFlagsOwnerValue
warehouse#74r#36#101
help_msg#74rc#36"The Generic Feature Object--not to be used as a feature object."
feature_verbs#74r#36{"Using"}
feature_ok#74r#361
drop_failed_msg#5rc#36<clear>
drop_succeeded_msg#5rc#36<clear>
odrop_failed_msg#5rc#36<clear>
odrop_succeeded_msg#5rc#36<clear>
otake_succeeded_msg#5rc#36<clear>
otake_failed_msg#5rc#36<clear>
take_succeeded_msg#5rc#36<clear>
take_failed_msg#5rc#36<clear>
value_base#102r#2<clear>
damage_base#102r#2<clear>
x_loc#102r#36<clear>
y_loc#102r#36<clear>
ansi_title#102r#36<clear>
obvious#102r#36<clear>
build_help#102rc#36<clear>
key#1c#36<clear>
aliases#1rc#36{"Generic Feature Object", "Generic .Features_Huh Object", "Feature Object", ".Features_Huh Object"}
description#1rc#36"This is the Generic Feature Object. It is not meant to be used as a feature object itself, but is handy for making new feature objects."
object_size#1r#36{7045, -1090650497}

Ancestry

Ancestors (nearest first): #5 generic thing#102 subthing#1 Root Class

Children: #92 Pasting Feature, #98 roleplay regulator, #99 scheduler, #100 reaper feature, #124 Mini Social Feature, #143 Public Broadcast System, #144 Puppet Strings

Call graph

calls n74_0 #74:help_msg n52_2 #52:has_verb n74_0->n52_2 n59_11 #59:verb_documentation n74_0->n59_11 n20_6 #20:english_list n74_0->n20_6 n74_1 #74:look_self n1_9 #1:description n74_1->n1_9 n6_79 #6:tell_lines n74_1->n6_79 n6_18 #6:tell n74_1->n6_18 n74_4 #74:set_feature_ok n42_0 #42:controls n74_4->n42_0 n74_5 #74:hidden_verbs n1_32 #1:hidden_verbs n74_5->n1_32 n74_6 #74:set_feature_verbs n74_6->n42_0 n74_7 #74:initialize n74_7->n42_0 n1_0 #1:initialize n74_7->n1_0

Source

help_msg

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1all_help = this.help_msg;
2if (typeof(all_help) == STR)
3all_help = {all_help};
4endif
5helpless = {};
6for vrb in (this.feature_verbs)
7if (loc = $object_utils:has_verb(this, vrb))
8loc = loc[1];
9help = $code_utils:verb_documentation(loc, vrb);
10if (help)
11all_help = {@all_help, "", tostr(loc, ":", verb_info(loc, vrb)[3]), @help};
12else
13helpless = {@helpless, vrb};
14endif
15endif
16endfor
17if (helpless)
18all_help = {@all_help, "", ("No help found on " + $string_utils:english_list(helpless, "nothing", " or ")) + "."};
19endif
20return {@all_help, "----"};

look_self

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1"Definition from #1";
2desc = this:description();
3if (desc)
4player:tell_lines(desc);
5else
6player:tell("You see nothing special.");
7endif
8player:tell("Please type \"help ", this, "\" for more information.");

using this

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1"Proper usage for the Generic Feature Object:";
2"";
3"First of all, the Generic Feature Object is constructed with the idea";
4"that its children will be @moved to #24300, which is kind of a warehouse";
5"for feature objects.  If there's enough interest, I'll try to make the";
6"stuff that works with that in mind optional.";
7"";
8"Make a short description.  This is so I can continue to have looking at";
9"#24300 give the descriptions of each of the objects in its .contents.";
10"The :look_msg automatically includes a pointer to `help <this object>',";
11"so you don't have to.";
12"";
13"Put a list of the commands you want people to use in";
14"<this object>.feature_verbs.  (You need to use the :set_feature_verbs";
15"verb to do this.)";
16"";
17"When someone types `help <this object>', they will be told the comment";
18"strings from each of the verbs named in .feature_verbs.";

examine_commands_ok

Spec this none thisFlags rxdOwner #2Definer #74

Referenced by

none

Source

1return this in args[1].features;

set_feature_ok

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1if ($perm_utils:controls(caller_perms(), this) || (caller == this))
2return this.feature_ok = args[1];
3else
4return E_PERM;
5endif

hidden_verbs

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1"Can't see `get' unless it's in the room; can't see `drop' unless it's in the player.  Should possibly go on $thing.";
2"Should use :contents, but I'm in a hurry.";
3hidden = pass(@args);
4if (this.location != args[1])
5hidden = setadd(hidden, {$thing, verb_info($thing, "drop")[3], {"this", "none", "none"}});
6hidden = setadd(hidden, {$thing, verb_info($thing, "give")[3], {"this", "at/to", "any"}});
7endif
8if (this.location != args[1].location)
9hidden = setadd(hidden, {$thing, verb_info($thing, "get")[3], {"this", "none", "none"}});
10endif
11return hidden;

set_feature_verbs

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1if ($perm_utils:controls(caller_perms(), this) || (caller == this))
2return this.feature_verbs = args[1];
3else
4return E_PERM;
5endif

initialize

Spec this none thisFlags rxdOwner #36Definer #74

Referenced by

none

Source

1if ((caller == this) || $perm_utils:controls(caller_perms(), this))
2pass(@args);
3this.feature_verbs = {};
4else
5return E_PERM;
6endif

init_for_core

Spec this none thisFlags rxdOwner #2Definer #74

Referenced by

Source

1if (($code_utils:verb_location() == this) && caller_perms().wizard)
2this.warehouse = $feature_warehouse;
3`delete_property(this, "guest_ok") ! ANY';
4`delete_verb(this, "set_ok_for_guest_use") ! ANY';
5endif

feature_remove

Spec this none thisFlags rxdOwner #2Definer #74

Referenced by

none

Source

1"This is just a blank verb definition to encourage others to use this verb name if they care when a user is no longer using that feature.";