On Friday, August 29, 1997 8:46 PM, Chris Grantham [SMTP:casper@OPTIMA.MME.WSU.EDU] wrote: > Greetings all, > > My name's Chris, I'm the Head Coder at EarthMUD > (mud.assassination.org:2001) <snip add for staff> Normally I don't really read these.. but for some reason I ended up at the ObCircle :-) > > ObCircle: > > I'm currently working on an Air Travel system for the Mud, I was Cool! Do you have a method for people to shoot down your airplanes? Do players have any control over the flight? BTW: What is it called when a forward observer asks for his artillery to fire upon spot X? I've been looking for the term all over the place and I can't seem to sift it out on a search engine either. > wondering is there a stock function out there to automatically close and > lock doors (Ie.. shut the airplane so no one stowsaway) after say.. 1 > tick? Not sure what you mean about the 'after 1 tick'. Do you want to open the doors, then have them auto-close 1 minute after opening? If I were to do that, I would create a system to allow it to function in other areas.. something like so: (assuming a scripting language is in use.) Commands: DELAY xx <cmd> - Do something a while later. SHUTDOORS [vnum] [direction] You can get DELAY from the event code on the ftp site. I started with that and have since added quite a few new event systems to the code. They are very useful for all sorts of things. Some examples might be: Movement/Blood Trails, better timed object management, event based player saves, mob movement zone resets and things like grenades and area affets. Then when the mob gives them their ticket or whatever have it put a reminder to itself to SHUTDOORS in 60 seconds. Of course the obvious next step is OPENDOORS [vnum] [direction] I may just do that.. might come in handy for a few things :-) As to the actual opening/closing of the door, this ought to work. (mailer-code that compiles for me.. haven't actually executed it) int seal_door(int room_vnum, int direction) { struct room_data *room, *other_side= NULL; int rnum; int bad_call=0; if (room_vnum<0) bad_call=1; else { rnum = real_room(room_vnum); if (rnum == NOWHERE) bad_call=1; else room = &world[rnum]; if (room && room->dir_option[direction]) if (!IS_SET(room->dir_option[direction]->exit_info, EX_ISDOOR)) bad_call=1; else { SET_BIT(room->dir_option[direction]->exit_info, EX_CLOSED); if (room->dir_option[direction]->key >0) SET_BIT(room->dir_option[direction]->exit_info, EX_LOCKED); if (room->dir_option[direction]->to_room >0 ) { other_side = &world[room->dir_option[direction]->to_room]; if (IS_SET(other_side->dir_option[direction]->exit_info, EX_ISDOOR)) { SET_BIT(room->dir_option[direction]->exit_info, EX_CLOSED); if (other_side->dir_option[direction]->key >0) SET_BIT(other_side->dir_option[direction]->exit_info, EX_LOCKED); } } } } if (!bad_call) return 1; return 0; } --Mallory I can picture in my mind a world without war, a world without hate. And I can picture us attacking that world, because they'd never expect it. - Jack Handey +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/08/00 PST