#include "defs.h" main(arg) { string dest_dir; int i; string where; object room,ob; SECURE if((!arg) || (sscanf(arg,"to %s",where)!=1)) return 0; dest_dir=environment(this_player())->query_dest_dir(); i = 1; if(!dest_dir) { write("Error looking up destinations\n"); return 1;} if (where=="u") where="up"; if (where=="d") where="down"; if (where=="n") where="north"; if (where=="s") where="south"; if (where=="w") where="west"; if (where=="e") where="east"; if (where=="nw") where="northwest"; if (where=="ne") where="northeast"; if (where=="sw") where="southwest"; if (where=="se") where="southeast"; write("You peer around the corner to the "+where+"\n"); while(i < sizeof(dest_dir)) { if (where == dest_dir[i]) { dest_dir[i-1]->long(); room=find_object(dest_dir[i-1]); ob = first_inventory(room); while(ob) { write(ob->short(0)+".\n"); ob = next_inventory(ob); } return 1; } i += 2; } write("Not a direction\n"); return 1; }