#include "config.h" #include "mud.h" #include "u.h" #include "y.tab.h" extern char *ctime (); int ub_time (char *who, char *aswho, int ac, Nod * av[], Nod * retnode) { retnode->rv.t = NUM; retnode->rv.iv = time ((time_t *) 0); return (UERR_NONE); } int ub_ctime (char *who, char *aswho, int ac, Nod * av[], Nod * retnode) { time_t tval; if (ac == 0) tval = time ((time_t *) 0); else tval = eval_castint (av[0]); retnode->rv.t = STR; retnode->rv.cv = tmpstr (ctime (&tval)); retnode->rv.cv[24] = '\0'; return (UERR_NONE); }