自动移动
inherit "obj/biota.c"//执行
void heartbeat(){scan();}void scan(){chat();}//随机走动
int randomMove(){map exits;string *dirs;if (! mapp(exits = environment(this).query("exits")) ) return 0;dirs = keys(exits);if ( sizeof(dirs)<=0 ) return 0;command(this,"go " + dirs[random(0,sizeof(dirs))]);}int chat(){var chatMsgs = query("chatMsg");if( random( 0,120 ) < query("chatChance")) {foreach( cmsg in chatMsgs ){if( mapp(cmsg) ){cmsg["fn"]();}}}}