> > if (world[IN_ROOM(ch)].zone < the_zonenumber_you_wanna_use_here) { > > do somthing; > > return 0; > > } > if (zone_table[world[EXIT(ch, dir)->to_room].zone].number < lower_bound || > zone_table[world[EXIT(ch, dir)->to_room].zone].number > upper_bound) { > do_something(); > return (0); > } What I came up with a bit after sending that yesterday was this: This is a quick snippet to prohibit access to a zone which is "closed". It will only stop players who are moving normally. It is placed in do_simple_move. If you have transportation spells, you will need to place a similar check for them. /* If a room is not open to mortals, they can't go in! */ if ((zone_table[world[EXIT(ch,dir)->to_room].zone].status_mode != 1) && (GET_LEVEL(ch) < LVL_IMMORT)) { send_to_char(ch, "That area is not available to mortals right now!\r\n"); return (0); } This is used with the areas snippet which provides olc editing of open/closed status. (areas.tar.gz in the zones section of the ftp site) Thanks for your replies! -Mathew -- +---------------------------------------------------------------+ | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html | | Newbie List: http://groups.yahoo.com/group/circle-newbies/ | +---------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 06/25/03 PDT