finger.c

./lib/secure/udp_cmd_/finger.c · 655 B

From the archive h7v3.0a.tar.gz

Download the archive   « Back to the archive contents

#include <master.cfg>
#include <udp.h>

int udp_finger(mapping data) {
    INETD->send_udp(data[NAME], ([
     REQUEST: REPLY,
     RECIPIENT: data[SENDER],
     ID: data[ID],
     DATA: (string)"/functions/finger"->get_finger_str(data[DATA]),
    ]));
    return 1;
}

string test_data(string str) {
  return (string)"/functions/finger"->get_finger_str(str,1);
}

void finger(string who, string mud) {
  if(!MASTER->valid_player_call(previous_object())) return;
  if(INETD->send_udp(mud, ([
         REQUEST: "finger",
         SENDER:  (string)this_player()->query_name(1),
         DATA:    who,
         ]), 1))
    write("Finger Request Sent.\n");
}

Site Stats

Snippets: 1791
Codebases: 571