-
Notifications
You must be signed in to change notification settings - Fork 3
/
falling.c
67 lines (52 loc) · 2.69 KB
/
falling.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/*
Slash's Merc Snippet
Falling objects
Ok, what this does it causes objects in air sectors to fall. This is
a real nice touch if you have lots of airy zones, like my Aarakocran city,
or the air above Midgaard.
Everything falls. This is pretty funny if you are standing in the
square in Midgaard below the air and corpses of flying monsters start
falling down. It is also pretty funny if you have flying mobiles in air
zones who have treasure and as players loot the corpse the corpse is falling.
Put this code in UPDATE.C in the function obj_update() where you see
if ( obj->timer <= 0 || --obj->timer > 0 )
continue;
Put it before the continue and put braces around the whole thing and
the continue.
if (obj->in_room &&
obj->in_room->sector_type == SECT_AIR &&
(obj->wear_flags & ITEM_TAKE) &&
obj->in_room->exit[5] &&
obj->in_room->exit[5]->to_room)
{
ROOM_INDEX_DATA *new_room = obj->in_room->exit[5]->to_room;
if (( rch = obj->in_room->people ) != NULL )
{
act( "$p falls away.", rch, obj, NULL, TO_ROOM );
act( "$p falls away.", rch, obj, NULL, TO_CHAR );
}
obj_from_room(obj);
obj_to_room(obj, new_room);
if (( rch = obj->in_room->people ) != NULL )
{
act( "$p floats by.", rch, obj, NULL, TO_ROOM );
act( "$p floats by.", rch, obj, NULL, TO_CHAR );
}
}
*/
/*
=============================================================================
/ ______ _______ ____ _____ ___ __ _ ______ ____ ____ _____ /
\ | ____|__ __| _ \ / ____\ / _ \| \ / | ____| / __ \| _ \ / ____\ \
/ | |__ | | | |_| | | | |_| | |\/| | |___ | | | | |_| | | /
/ | ___| | | | ___/| | __| _ | | | | ____| | | | | __/| | ___ \
\ | | | | | | | |___| | | | | | | | |____ | |__| | |\ \| |___| | /
/ |_| |_| |_| o \_____/|_| |_|_| |_|______|o \____/|_| \_|\_____/ \
\ /
============================================================================
------------------------------------------------------------------------------
ftp://ftp.game.org/pub/mud FTP.GAME.ORG http://www.game.org/ftpsite/
------------------------------------------------------------------------------
This file came from FTP.GAME.ORG, the ultimate source for MUD resources.
------------------------------------------------------------------------------
*/