[DGD] Re: DGD mudlibs
Gregory D Lewis
glewis at maths.adelaide.edu.au
Sun Sep 13 05:12:09 CEST 1998
> Downloaded the pdlib. It's interesting. However I haven't gotten it to
> run on 1.1p6a yet.
> Is there a file anywhere on transfering from the old DGD to the new? Would
> be
> interesting to see it run. I doubt I'd use this lib completely.. but by
> moving around
> on it I could gain an idea of what I'd like to implement in my own lib.
The diff at the end of this mail gets it to the point where it starts and you
get to the login screen when you telnet in. There will no doubt be other
problems.
Main changes were lock -> rlimits and altered behaviour of clone_object.
Hmmm, one interesting thing is that dgd (1.1p6) core dumps for me when I try
to start the original. It definitely writes an error message but crashes
rather than exiting gracefully.
The gdb trace looks like:
(gdb) where
#0 0x200b7c61 in _kill ()
#1 0x200b72f3 in abort ()
#2 0x221c in fatal (format=0x14450 "missing function in driver object: %s",
arg1=0x342a6 "call_object", arg2=0xefbfb980 "\001\001",
arg3=0xefbfb970 "\003\001", arg4=0x0, arg5=0xefbfb76c "P7?o#\003\001",
arg6=0x34307 "\213\rPj\004") at error.c:120
#3 0x14513 in call_driver_object (func=0x342a6 "call_object", narg=1)
at dgd.c:37
#4 0x34307 in kf_call_other (nargs=2) at std.c:79
#5 0x10323 in i_interpret (pc=0x31f4e2 "\0374H}6") at interpret.c:1560
#6 0x104c4 in i_interpret (pc=0x31f4db "\b~\005\0069\201\002\0374H}6")
at interpret.c:1599
#7 0x109f8 in i_funcall (obj=0x61004, p_ctrli=0, funci=0, nargs=0)
at interpret.c:1797
#8 0x10b36 in i_call (obj=0x61004, func=0x13755 "initialize", len=10,
call_static=1, nargs=0) at interpret.c:1867
#9 0x144ff in call_driver_object (func=0x13755 "initialize", narg=0)
at dgd.c:36
#10 0x140a6 in conf_init (configfile=0xefbfdc99 "lpmud", dumpfile=0x0)
at config.c:958
#11 0x1465b in dgd_main (argc=2, argv=0xefbfdc04) at dgd.c:149
#12 0x3a38f in main (argc=2, argv=0xefbfdc04) at local.c:25
-----------------------------------pblib.diff----------------------------------
diff -cNr lib/GAME_START lib.new/GAME_START
*** lib/GAME_START Sun Sep 13 12:19:20 1998
--- lib.new/GAME_START Sun Sep 13 12:19:09 1998
***************
*** 1 ****
! Thu Mar 16 21:07:23 1995Thu Mar 16 21:08:41 1995Thu Mar 16 21:10:55 1995
--- 1 ----
! Sun Sep 13 12:19:00 1998
diff -cNr lib/dgd/lib/auto.c lib.new/dgd/lib/auto.c
*** lib/dgd/lib/auto.c Fri Mar 17 06:21:38 1995
--- lib.new/dgd/lib/auto.c Sat Sep 12 18:29:21 1998
***************
*** 54,60 ****
{
object save_player;
! lock(initialize());
save_player = this_player();
this_object()->create();
--- 54,60 ----
{
object save_player;
! rlimits (-1; -1) { catch(initialize()); };
save_player = this_player();
this_object()->create();
diff -cNr lib/dgd/lib/comm.c lib.new/dgd/lib/comm.c
*** lib/dgd/lib/comm.c Fri Mar 17 06:21:38 1995
--- lib.new/dgd/lib/comm.c Sat Sep 12 18:25:19 1998
***************
*** 142,150 ****
if (player != 0 && ::query_ip_number(player) != 0) {
int res;
! lock(privileged = 1,
! res = player->_F_set_input_to(this_object(), func, flag),
! privileged = 0);
return res;
}
error("False input_to");
--- 142,152 ----
if (player != 0 && ::query_ip_number(player) != 0) {
int res;
! rlimits (-1; -1) {
! privileged = 1;
! catch(res = player->_F_set_input_to(this_object(), func, flag));
! privileged = 0;
! }
return res;
}
error("False input_to");
***************
*** 174,187 ****
*/
for (i = 0, sz = sizeof(u); i < sz; i++)
{
! lock(privileged = 1,
! snooper = u[i]->query_user()->_Q_snoop(),
! privileged = 0);
if (snooper == player->query_user())
{
! lock(privileged = 1,
! u[i]->query_user()->_F_snoop(0),
! privileged = 0);
return 1;
}
}
--- 176,193 ----
*/
for (i = 0, sz = sizeof(u); i < sz; i++)
{
! rlimits (-1; -1) {
! privileged = 1;
! catch(snooper = u[i]->query_user()->_Q_snoop());
! privileged = 0;
! }
if (snooper == player->query_user())
{
! rlimits (-1; -1) {
! privileged = 1;
! catch(u[i]->query_user()->_F_snoop(0));
! privileged = 0;
! }
return 1;
}
}
***************
*** 199,216 ****
{
if (!_MASTER_OB->valid_snoop(player, player, snooper))
return 0;
! lock(privileged = 1,
! obj->query_user()->_F_snoop(0),
! privileged = 0);
}
else
{
snooper = query_snoop(player);
if (snooper == obj) /* avoid recursive snoop */
return 0;
! lock(privileged = 1,
! obj->query_user()->_F_snoop(player->query_user()),
! privileged = 0);
}
return 1;
}
--- 205,226 ----
{
if (!_MASTER_OB->valid_snoop(player, player, snooper))
return 0;
! rlimits (-1; -1) {
! privileged = 1;
! catch(obj->query_user()->_F_snoop(0));
! privileged = 0;
! }
}
else
{
snooper = query_snoop(player);
if (snooper == obj) /* avoid recursive snoop */
return 0;
! rlimits (-1; -1) {
! privileged = 1;
! catch(obj->query_user()->_F_snoop(player->query_user()));
! privileged = 0;
! }
}
return 1;
}
***************
*** 221,234 ****
*/
if (!_MASTER_OB->valid_snoop(player, player, snoopee))
return 0;
! lock(privileged = 1,
! snooper = snoopee->query_user()->_Q_snoop(),
! privileged = 0);
if (snooper)
return 0;
! lock(privileged = 1,
! snoopee->query_user()->_F_snoop(obj->query_user()),
! privileged = 0);
return 1;
}
return 0;
--- 231,248 ----
*/
if (!_MASTER_OB->valid_snoop(player, player, snoopee))
return 0;
! rlimits (-1; -1) {
! privileged = 1;
! catch(snooper = snoopee->query_user()->_Q_snoop());
! privileged = 0;
! }
if (snooper)
return 0;
! rlimits (-1; -1) {
! privileged = 1;
! catch(snoopee->query_user()->_F_snoop(obj->query_user()));
! privileged = 0;
! }
return 1;
}
return 0;
***************
*** 259,277 ****
return 0;
if ((usr = whom->query_user())) {
! lock(privileged = 1,
! usr->switch_player(0), /* possessed persons user object saved */
! puser->switch_player(whom),
! whom->set_user(0),
! puser->_F_snoop(usr),
! privileged = 0);
whom->set_user(puser); /* we are controlled by possesser now */
bywhom->set_user(0);
return 1;
} else {
! lock(privileged = 1,
! puser->switch_player(whom),
! privileged = 0);
whom->set_user(puser);
bywhom->set_user(0);
return 1;
--- 273,295 ----
return 0;
if ((usr = whom->query_user())) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(usr->switch_player(0)); /* possessed persons user object saved */
! catch(puser->switch_player(whom));
! catch(whom->set_user(0));
! catch(puser->_F_snoop(usr));
! privileged = 0;
! }
whom->set_user(puser); /* we are controlled by possesser now */
bywhom->set_user(0);
return 1;
} else {
! rlimits (-1; -1) {
! privileged = 1;
! catch(puser->switch_player(whom));
! privileged = 0;
! }
whom->set_user(puser);
bywhom->set_user(0);
return 1;
***************
*** 310,331 ****
}
if (!usr) {
! lock(privileged = 1,
! puser->switch_player(opl), /* switched back */
! puser->_F_reset_splayer(),
! privileged = 0);
opl->set_user(puser);
opl->set_linkdead(0);
possesser->set_user(0);
return 1;
} else {
! lock(privileged = 1,
! usr->switch_player(pl),
! usr->_F_reset_splayer(),
! puser->switch_player(opl),
! puser->_F_reset_splayer(),
! puser->_F_snoop(0),
! privileged = 0);
pl->set_user(usr);
opl->set_user(puser);
opl->set_linkdead(0);
--- 328,353 ----
}
if (!usr) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(puser->switch_player(opl)); /* switched back */
! catch(puser->_F_reset_splayer());
! privileged = 0;
! }
opl->set_user(puser);
opl->set_linkdead(0);
possesser->set_user(0);
return 1;
} else {
! rlimits (-1; -1) {
! privileged = 1;
! catch(usr->switch_player(pl));
! catch(usr->_F_reset_splayer());
! catch(puser->switch_player(opl));
! catch(puser->_F_reset_splayer());
! catch(puser->_F_snoop(0));
! privileged = 0;
! }
pl->set_user(usr);
opl->set_user(puser);
opl->set_linkdead(0);
***************
*** 350,358 ****
if (!player || ::query_ip_number(obj->query_user()) == 0 ||
player->query_wiz_level() < 41)
return 0;
! lock(privileged = 1,
! snooper = obj->query_user()->_Q_snoop(),
! privileged = 0);
if (snooper)
return snooper->query_player();
else
--- 372,382 ----
if (!player || ::query_ip_number(obj->query_user()) == 0 ||
player->query_wiz_level() < 41)
return 0;
! rlimits (-1; -1) {
! privileged = 1;
! catch(snooper = obj->query_user()->_Q_snoop());
! privileged = 0;
! }
if (snooper)
return snooper->query_player();
else
diff -cNr lib/dgd/lib/creator.c lib.new/dgd/lib/creator.c
*** lib/dgd/lib/creator.c Fri Mar 17 06:21:42 1995
--- lib.new/dgd/lib/creator.c Sat Sep 12 18:13:21 1998
***************
*** 60,68 ****
else
creator = "backbone";
! lock( privileged = 1,
! this_object()->seteuid(creator),
! privileged = 0);
}
--- 60,70 ----
else
creator = "backbone";
! rlimits (-1; -1) {
! privileged = 1;
! catch(this_object()->seteuid(creator));
! privileged = 0;
! }
}
diff -cNr lib/dgd/lib/file.c lib.new/dgd/lib/file.c
*** lib/dgd/lib/file.c Fri Mar 17 06:21:38 1995
--- lib.new/dgd/lib/file.c Sat Sep 12 18:31:18 1998
***************
*** 139,154 ****
error("Illegal start of ed");
}
! lock(privileged = 1,
! editor = usr->_Q_editor(),
! privileged = 0);
if (editor != 0) {
error("Tried to start an ed session, when already active");
}
! lock(privileged = 1,
! editor = clone_object("/dgd/std/editor"),
! usr->_F_editor(editor, exit_func),
! privileged = 0);
if (file == 0) {
editor->edit();
--- 139,158 ----
error("Illegal start of ed");
}
! rlimits (-1; -1) {
! privileged = 1;
! catch(editor = usr->_Q_editor());
! privileged = 0;
! }
if (editor != 0) {
error("Tried to start an ed session, when already active");
}
! rlimits (-1; -1) {
! privileged = 1;
! catch(editor = clone_object("/dgd/std/editor"));
! catch(usr->_F_editor(editor, exit_func));
! privileged = 0;
! }
if (file == 0) {
editor->edit();
***************
*** 264,272 ****
}
line = 1;
if (this_player() && (user = this_player()->query_user())) {
! lock(privileged = 1,
! saved = user->query_file_offset(file),
! privileged = 0);
if (saved != 0) {
line = saved[0];
if (line > 2 * first) {
--- 268,278 ----
}
line = 1;
if (this_player() && (user = this_player()->query_user())) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(saved = user->query_file_offset(file));
! privileged = 0;
! }
if (saved != 0) {
line = saved[0];
if (line > 2 * first) {
***************
*** 337,345 ****
line += first + num;
offset += strlen(implode(lines[0 .. first + num - 1],
"\n")) + 1;
! lock(privileged = 1,
! user->set_file_offset(file, line, offset),
! privileged = 0);
}
return lines[first .. first + num - 1] + ({ "" });
}
--- 343,353 ----
line += first + num;
offset += strlen(implode(lines[0 .. first + num - 1],
"\n")) + 1;
! rlimits (-1; -1) {
! privileged = 1;
! catch(user->set_file_offset(file, line, offset));
! privileged = 0;
! }
}
return lines[first .. first + num - 1] + ({ "" });
}
diff -cNr lib/dgd/lib/global.c lib.new/dgd/lib/global.c
*** lib/dgd/lib/global.c Fri Mar 17 06:21:41 1995
--- lib.new/dgd/lib/global.c Sun Sep 13 12:12:59 1998
***************
*** 5,13 ****
static void set_this_player(object player)
{
if (this_object() != 0) {
! lock(privileged = 1,
! _GLOBAL_OB->set_this_player(player),
! privileged = 0);
}
}
--- 5,15 ----
static void set_this_player(object player)
{
if (this_object() != 0) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(_GLOBAL_OB->set_this_player(player));
! privileged = 0;
! }
}
}
***************
*** 56,64 ****
ARGCHECK(name, set_living_name, 1);
if (this_object() != 0) {
! lock(privileged = 1,
! _GLOBAL_OB->set_living_name(name),
! privileged = 0);
}
}
--- 58,68 ----
ARGCHECK(name, set_living_name, 1);
if (this_object() != 0) {
! rlimits (-1;-1) {
! privileged = 1;
! catch(_GLOBAL_OB->set_living_name(name));
! privileged = 0;
! }
}
}
***************
*** 129,137 ****
private void set_verb(string verb)
{
if (this_object() != 0) {
! lock(privileged = 1,
! _GLOBAL_OB->set_verb(verb),
! privileged = 0);
}
}
--- 133,143 ----
private void set_verb(string verb)
{
if (this_object() != 0) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(_GLOBAL_OB->set_verb(verb));
! privileged = 0;
! }
}
}
***************
*** 160,162 ****
--- 166,189 ----
else
return this_player();
}
+
+ /*
+ * NAME: clone_object()
+ */
+ static
+ object
+ clone_object(mixed obj) {
+ object foo;
+ switch (typeof(obj)) {
+ case T_STRING :
+ foo = find_object(obj) ? find_object(obj) : compile_object(obj);
+ break;
+ case T_OBJECT :
+ foo = (object) obj;
+ break;
+ default :
+ return 0;
+ }
+ return (foo) ? ::clone_object(foo) : 0;
+ }
+
diff -cNr lib/dgd/lib/global.h lib.new/dgd/lib/global.h
*** lib/dgd/lib/global.h Fri Mar 17 06:21:41 1995
--- lib.new/dgd/lib/global.h Sat Sep 12 18:33:20 1998
***************
*** 11,14 ****
--- 11,16 ----
static string query_verb();
static object this_interactive();
+ static object clone_object(mixed obj);
+
# define INIT_GLOBAL()
diff -cNr lib/dgd/lib/inventory.c lib.new/dgd/lib/inventory.c
*** lib/dgd/lib/inventory.c Fri Mar 17 06:21:40 1995
--- lib.new/dgd/lib/inventory.c Sat Sep 12 18:24:29 1998
***************
*** 69,77 ****
{
object *inv;
! lock(privileged = 1,
! inv = obj->_Q_inv(),
! privileged = 0);
return inv;
}
--- 69,79 ----
{
object *inv;
! rlimits (-1; -1) {
! privileged = 1,
! catch(inv = obj->_Q_inv());
! privileged = 0;
! }
return inv;
}
***************
*** 137,143 ****
return;
}
}
! lock(move(obj, env, dest));
if (living(obj)) {
set_this_player(obj);
dest->init();
--- 139,147 ----
return;
}
}
! rlimits (-1; -1) {
! catch(move(obj, env, dest));
! }
if (living(obj)) {
set_this_player(obj);
dest->init();
***************
*** 224,234 ****
int i, sz;
if (ob) {
! lock(privileged = 1,
! (from ? from->_F_rm_inv(ob) : ""),
! ob->_F_move(this_object()),
! this_object()->_F_add_inv(ob),
! privileged = 0);
return;
}
--- 228,240 ----
int i, sz;
if (ob) {
! rlimits (-1; -1) {
! privileged = 1;
! catch((from ? from->_F_rm_inv(ob) : ""));
! catch(ob->_F_move(this_object()));
! catch(this_object()->_F_add_inv(ob));
! privileged = 0;
! }
return;
}
***************
*** 236,247 ****
inventory += all[..];
for (i=0, sz = sizeof(all); i < sz; i++) {
! lock(privileged = 1,
! all[i]->_F_move(this_object()),
! privileged = 0);
! }
! lock(privileged = 1,
! from->_F_rm_all(),
! privileged = 0);
}
--- 242,257 ----
inventory += all[..];
for (i=0, sz = sizeof(all); i < sz; i++) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(all[i]->_F_move(this_object()));
! privileged = 0;
! }
! }
! rlimits (-1; -1) {
! privileged = 1;
! catch(from->_F_rm_all());
! privileged = 0;
! }
}
diff -cNr lib/dgd/lib/living.c lib.new/dgd/lib/living.c
*** lib/dgd/lib/living.c Fri Mar 17 06:21:39 1995
--- lib.new/dgd/lib/living.c Sat Sep 12 18:20:52 1998
***************
*** 62,70 ****
*/
private void remove_actions(object player, object obj)
{
! lock(privileged = 1,
! player->_F_remove_actions(obj),
! privileged = 0);
}
/******************************************************************************
--- 62,72 ----
*/
private void remove_actions(object player, object obj)
{
! rlimits (-1; -1) {
! privileged = 1;
! catch(player->_F_remove_actions(obj));
! privileged = 0;
! }
}
/******************************************************************************
***************
*** 130,138 ****
{
ARGCHECK(func, define_action, 1);
! lock(privileged = 1,
! this_object()->_F_add_action(this_object(), verb, func, flag),
! privileged = 0);
}
/******************************************************************************
--- 132,142 ----
{
ARGCHECK(func, define_action, 1);
! rlimits (-1; -1) {
! privileged = 1;
! catch(this_object()->_F_add_action(this_object(), verb, func, flag));
! privileged = 0;
! }
}
/******************************************************************************
***************
*** 145,153 ****
ARGCHECK(func, define_primary, 1);
ARGCHECK(obj, define_primary, 2);
! lock(privileged = 1,
! this_player()->_D_primary(func, obj),
! privileged = 0);
}
/******************************************************************************
--- 149,159 ----
ARGCHECK(func, define_primary, 1);
ARGCHECK(obj, define_primary, 2);
! rlimits (-1; -1) {
! privileged = 1;
! catch(this_player()->_D_primary(func, obj));
! privileged = 0;
! }
}
/******************************************************************************
***************
*** 176,184 ****
ARGCHECK(func, define_primary, 1);
ARGCHECK(obj, define_primary, 2);
! lock(privileged = 1,
! this_player()->_U_primary(func, obj),
! privileged = 0);
}
/******************************************************************************
--- 182,192 ----
ARGCHECK(func, define_primary, 1);
ARGCHECK(obj, define_primary, 2);
! rlimits (-1; -1) {
! privileged = 1;
! catch(this_player()->_U_primary(func, obj));
! privileged = 0;
! }
}
/******************************************************************************
***************
*** 323,331 ****
arg = ret[1];
}
! lock(privileged = 1,
! primary = player->_Q_primary(),
! privileged = 0);
for (i = 0, sz = sizeof(primary); i < sz; i++)
{
--- 331,341 ----
arg = ret[1];
}
! rlimits (-1; -1) {
! privileged = 1;
! catch(primary = player->_Q_primary());
! privileged = 0;
! }
for (i = 0, sz = sizeof(primary); i < sz; i++)
{
diff -cNr lib/dgd/lib/simfun.c lib.new/dgd/lib/simfun.c
*** lib/dgd/lib/simfun.c Fri Mar 17 06:21:42 1995
--- lib.new/dgd/lib/simfun.c Sat Sep 12 18:23:21 1998
***************
*** 155,168 ****
return;
env = environment(obj);
if (env) {
! lock(remove_inv(obj, env));
}
if ((usr = obj->query_user()) &&
(usr->query_player() == obj))
{
! lock(privileged = 1,
! usr->disconnect(),
! privileged = 0);
}
::destruct_object(obj);
}
--- 155,170 ----
return;
env = environment(obj);
if (env) {
! rlimits (-1; -1) { catch(remove_inv(obj, env)); }
}
if ((usr = obj->query_user()) &&
(usr->query_player() == obj))
{
! rlimits (-1; -1) {
! privileged = 1;
! catch(usr->disconnect());
! privileged = 0;
! }
}
::destruct_object(obj);
}
***************
*** 272,279 ****
static void shutdown()
{
set_this_player(0);
! lock(save_all(),
! ::shutdown());
}
/******************************************************************************
--- 274,283 ----
static void shutdown()
{
set_this_player(0);
! rlimits (-1; -1) {
! catch(save_all());
! catch(::shutdown());
! }
}
/******************************************************************************
***************
*** 309,317 ****
player = this_player();
if (player != 0) {
! lock(privileged = 1,
! player->set_notify_fail(mesg),
! privileged = 0);
}
}
--- 313,323 ----
player = this_player();
if (player != 0) {
! rlimits (-1; -1) {
! privileged = 1,
! catch(player->set_notify_fail(mesg));
! privileged = 0;
! }
}
}
***************
*** 323,331 ****
{
string mesg;
! lock(privileged = 1,
! mesg = this_player()->query_notify_fail(),
! privileged = 0);
if (!mesg)
mesg = "What?\n";
return mesg;
--- 329,339 ----
{
string mesg;
! rlimits (-1; -1) {
! privileged = 1;
! catch(mesg = this_player()->query_notify_fail());
! privileged = 0;
! }
if (!mesg)
mesg = "What?\n";
return mesg;
***************
*** 800,815 ****
}
other = to->query_user();
if (other != 0) {
! lock(privileged = 1,
! other->disconnect(),
! privileged = 0);
}
ARGCHECK(from && (user=from->query_user()), exec, 2);
! lock(privileged = 1,
! user->set_player(to),
! privileged = 0);
if (this_player() == from)
{
set_this_player(to);
--- 808,827 ----
}
other = to->query_user();
if (other != 0) {
! rlimits (-1; -1) {
! privileged = 1;
! catch(other->disconnect());
! privileged = 0;
! }
}
ARGCHECK(from && (user=from->query_user()), exec, 2);
! rlimits (-1; -1) {
! privileged = 1;
! catch(user->set_player(to));
! privileged = 0;
! }
if (this_player() == from)
{
set_this_player(to);
diff -cNr lib/dgd/sys/driver.c lib.new/dgd/sys/driver.c
*** lib/dgd/sys/driver.c Fri Mar 17 06:21:35 1995
--- lib.new/dgd/sys/driver.c Sat Sep 12 18:05:50 1998
***************
*** 28,38 ****
send_message("Setting up ipc.\n");
}
/******************************************************************************
! * NAME: path_ed_read()
* DESCRIPTION: handle an editor read path
*/
! string path_ed_read(string path)
{
object player;
--- 28,46 ----
send_message("Setting up ipc.\n");
}
+ /*
+ * NAME: restored()
+ * DESCRIPTION: Called after the system has restarted from a state dump.
+ */
+ static
+ void
+ restored() { }
+
/******************************************************************************
! * NAME: path_read()
* DESCRIPTION: handle an editor read path
*/
! string path_read(string path)
{
object player;
***************
*** 47,56 ****
}
/******************************************************************************
! * NAME: path_ed_write()
* DESCRIPTION: handle an editor write path
*/
! string path_ed_write(string path)
{
object player;
--- 55,64 ----
}
/******************************************************************************
! * NAME: path_write()
* DESCRIPTION: handle an editor write path
*/
! string path_write(string path)
{
object player;
***************
*** 65,85 ****
}
/******************************************************************************
! * NAME: path_object()
* DESCRIPTION: translate an object path
*/
! string path_object(string path)
{
! return path;
}
/******************************************************************************
! * NAME: path_inherit()
* DESCRIPTION: translate an inherit path
*/
! string path_inherit(string file, string path)
{
! return path;
}
/******************************************************************************
--- 73,96 ----
}
/******************************************************************************
! * NAME: call_object()
* DESCRIPTION: translate an object path
*/
! static
! object call_object(string path)
{
! return (find_object(path) ? find_object(path) : compile_object(path));
}
/******************************************************************************
! * NAME: inherit_program()
* DESCRIPTION: translate an inherit path
*/
! static
! object inherit_program(string file, string program)
{
! return (find_object(program) ? find_object(program) :
! compile_object(program));
}
/******************************************************************************
***************
*** 96,109 ****
return path;
}
! /******************************************************************************
! * NAME: compile_object()
! * DESCRIPTION: (not) used for virtual objects
*/
! static object compile_object(string file)
! {
! return 0;
! }
/******************************************************************************
* NAME: connect()
--- 107,125 ----
return path;
}
! /*
! * NAME: recompile()
*/
! static
! void
! recompile(object obj) { }
!
! /*
! * NAME: interrupt()
! */
! static
! void
! interrupt() { shutdown(); }
/******************************************************************************
* NAME: connect()
***************
*** 120,129 ****
}
/******************************************************************************
! * NAME: log_error()
* DESCRIPTION: log a runtime error
*/
! static void log_error(string error, int caught)
{
mixed **trace;
string progname, objname, function, str, dm, pl, af, file;
--- 136,145 ----
}
/******************************************************************************
! * NAME: runtime_error()
* DESCRIPTION: log a runtime error
*/
! static void runtime_error(string error, int caught, int ticks)
{
mixed **trace;
string progname, objname, function, str, dm, pl, af, file;
***************
*** 226,235 ****
}
/******************************************************************************
! * NAME: compile_log()
! * DESCRIPTION: return the name of a compile time error log
*/
! string compile_log(string file)
{
string *path, fl, dm, pl, af;
--- 242,251 ----
}
/******************************************************************************
! * NAME: compile_error()
! * DESCRIPTION: Handle a compile-time error.
*/
! string compile_error(string file, int line, string err)
{
string *path, fl, dm, pl, af;
***************
*** 244,256 ****
fl = "/d/" + dm + "/log/errors";
else
fl = "/log/errors";
! return fl;
}
! void restored()
! {
! }
! static void recompile(object obj)
! {
! }
--- 260,285 ----
fl = "/d/" + dm + "/log/errors";
else
fl = "/log/errors";
! write_file(fl, file + ":" + line + " " + err + "\n");
}
! /*
! * NAME: compile_rlimits()
! */
! static
! int
! compile_rlimits(string objname) { return (1); }
! /*
! * NAME: runtime_rlimits()
! */
! static
! int
! runtime_rlimits(object obj, int stack, int ticks) { return (-1); }
!
! /*
! * NAME: remove_program()
! */
! static
! void
! remove_program(string objname, int timestamp, int index) { }
diff -cNr lib/lpmud lib.new/lpmud
*** lib/lpmud Mon Dec 12 05:59:10 1994
--- lib.new/lpmud Sun Sep 13 12:18:41 1998
***************
*** 1,10 ****
telnet_port = 3000; /* TCP/IP port number */
binary_port = 4242;
! directory = "/homes/mud/mud/lib/develop"; /* base directory (MUST be absolute) */
users = 55; /* max # of users */
editors = 41; /* max # of editor sessions */
ed_tmpfile = "../dgd_ed"; /* proto editor tmpfile */
! swap_file = "../dgd_swap"; /* swap file */
dump_file = "../dgd_dump";
swap_size = 65534; /* # sectors in swap file */
cache_size = 1024; /* # sectors in swap cache */
--- 1,10 ----
telnet_port = 3000; /* TCP/IP port number */
binary_port = 4242;
! directory = "/home/mudman/libs/pblib/lib.new"; /* base directory (MUST be absolute) */
users = 55; /* max # of users */
editors = 41; /* max # of editor sessions */
ed_tmpfile = "../dgd_ed"; /* proto editor tmpfile */
! swap_file = "../dgd_swap"; /* swap file */
dump_file = "../dgd_dump";
swap_size = 65534; /* # sectors in swap file */
cache_size = 1024; /* # sectors in swap cache */
***************
*** 20,30 ****
driver_object = "/dgd/sys/driver"; /* driver object */
create = "_F_create"; /* name of create function */
- value_stack = 1000; /* value stack */
- call_stack = 60; /* function call stack */
- reserved_cstack = 10; /* reserved function call stack */
- reserved_vstack = 50;
- max_cost = 400000; /* max execution cost */
array_size = 2000; /* max array size */
objects = 20000; /* max # of objects */
call_outs = 5000; /* max # of call_outs */
--- 20,25 ----
--
Greg Lewis Applied Maths Department
Email : glewis at maths.adelaide.edu.au University of Adelaide
--
Magpie, n.:
A bird whose theivish disposition suggested to someone that it
might be taught to talk.
-- Ambrose Bierce, "The Devil's Dictionary"
List config page: http://list.imaginary.com/mailman/listinfo/dgd
More information about the DGD
mailing list