Exemple #1
0
mixed can_drive_obj_str(object ob, string str)
{
   mixed value = environment(this_body())->can_go_somewhere(str);
   if(!stringp(value) && (value == 1))
      return default_checks();
   if(!stringp(value) && (member_array(str, normal_directions) != -1))
      return "It doesn't appear you can go that way.\n";
   return value;
}
Exemple #2
0
mixed can_post_about_str(string str) {
    object brd = 0;
    mixed res;

    foreach (object ob in deep_inventory(environment(this_body()))) {
        if ((int)ob->is_bulletin_board()) {
            if (!brd)
                brd = ob;
            else
                return "Please specify on which board you want to post.\n";
        }
    }

    if (res = brd->indirect_post_on_obj_about_str(str, brd))
        return res;

    return default_checks();
}
Exemple #3
0
mixed can_remove_wrd(string wrd) {
    object brd = 0;
    mixed res;

    foreach (object ob in deep_inventory(environment(this_body()))) {
        if ((int)ob->is_bulletin_board()) {
            if (!brd)
                brd = ob;
            else
                return "Please specify on which board you want to "
                       "remove a note.\n";
        }
    }
    if (!brd)
        return "There's nothing here to remove notes from.\n";

    if ((res = brd->direct_remove_wrd_from_obj(wrd, brd)) != 1)
        return res;

    return default_checks();
}
Exemple #4
0
/* Followups are posted using 'post followup to <id>' */
mixed can_post_wrd_to_wrd(string wrd1, string wrd2) {
    object brd = 0;
    mixed res;

    if (wrd1 != "followup")
        return 0;

    foreach (object ob in deep_inventory(environment(this_body()))) {
        if ((int)ob->is_bulletin_board())
            if (!brd)
                brd = ob;
            else
                return "Please specify the board you want to post on.\n";
    }
    if (!brd)
        return "There is nothing here to post on.\n";

    if ((res = brd->direct_post_wrd_to_wrd_on_obj(wrd1, wrd2, brd)) != 1)
        return res;

    return default_checks();
}
Exemple #5
0
mixed can_post_wrd_to_wrd_on_obj(string wrd1, string wrd2, object ob) {
    if (wrd1 != "followup")
        return 0;

    return default_checks();
}
Exemple #6
0
mixed can_post_on_obj_about_str(object ob, string str) {
    return default_checks();
}
Exemple #7
0
mixed can_remove_wrd_from_obj(string wrd, object ob) {
    return default_checks();
}