I've seen a zsave command out there somewhere and i just made one totally not the same just the same name.. you can type zsave to call the function thats used during shutdowns - save_all() but if u specify a zone it'll just save for that zone all info such as shop, zone, mob, obj, room well here it is... ACMD(do_zsave); ACMD(do_zsave) { struct save_list_data *i; int found = 0; zone_rnum tar; // I suggest leaving these two variables alone zone_vnum j; // it'll crash if its not rnum tar one_argument(argument, arg); if (*arg) { j = atoi(arg); for (tar = 0; tar <= top_of_zone_table; tar++) if (zone_table[tar].number == j) break; if (tar < 0 || tar > top_of_zone_table) { send_to_char("Value must be a valid zone.\r\n", ch); return; } for (i = save_list; i; i = i->next) if (i->zone == j) { if (save_types[i->type].save_type == -1) { mudlog("Error in ZSAVE", NRM, LVL_IMPL, TRUE); return; } save_types[i->type].func(tar); sprintf(buf, "You save %s info for zone %d.\r\n", save_types[i->type].message, j); send_to_char(buf, ch); found = 1; } if (!found) send_to_char("That zone has nothing to save!\r\n", ch); return; } if (!save_list) { send_to_char("No zones to save.\r\n", ch); return; } save_all(); send_to_char("You save world info.\r\n", ch); } _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com -- +---------------------------------------------------------------+ | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html | +---------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/11/01 PDT