ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/server/monster.C
(Generate patch)

Comparing deliantra/server/server/monster.C (file contents):
Revision 1.16 by root, Mon Dec 18 03:00:02 2006 UTC vs.
Revision 1.17 by root, Wed Dec 20 09:14:22 2006 UTC

135 if (mflags & P_OUT_OF_MAP) 135 if (mflags & P_OUT_OF_MAP)
136 continue; 136 continue;
137 137
138 if (mflags & P_IS_ALIVE) 138 if (mflags & P_IS_ALIVE)
139 { 139 {
140 tmp = get_map_ob (m, nx, ny); 140 tmp = GET_MAP_OB (m, nx, ny);
141 while (tmp != NULL && !QUERY_FLAG (tmp, FLAG_MONSTER) && !QUERY_FLAG (tmp, FLAG_GENERATOR) && tmp->type != PLAYER) 141 while (tmp != NULL && !QUERY_FLAG (tmp, FLAG_MONSTER) && !QUERY_FLAG (tmp, FLAG_GENERATOR) && tmp->type != PLAYER)
142 tmp = tmp->above; 142 tmp = tmp->above;
143 143
144 if (!tmp) 144 if (!tmp)
145 { 145 {
1433 mflags = get_map_flags (m, &m, sx, sy, &sx, &sy); 1433 mflags = get_map_flags (m, &m, sx, sy, &sx, &sy);
1434 /* If nothing alive on this space, no need to search the space. */ 1434 /* If nothing alive on this space, no need to search the space. */
1435 if ((mflags & P_OUT_OF_MAP) || !(mflags & P_IS_ALIVE)) 1435 if ((mflags & P_OUT_OF_MAP) || !(mflags & P_IS_ALIVE))
1436 continue; 1436 continue;
1437 1437
1438 for (npc = get_map_ob (m, sx, sy); npc != NULL; npc = npc->above) 1438 for (npc = GET_MAP_OB (m, sx, sy); npc != NULL; npc = npc->above)
1439 if (QUERY_FLAG (npc, FLAG_ALIVE) && QUERY_FLAG (npc, FLAG_UNAGGRESSIVE)) 1439 if (QUERY_FLAG (npc, FLAG_ALIVE) && QUERY_FLAG (npc, FLAG_UNAGGRESSIVE))
1440 npc->enemy = op->enemy; 1440 npc->enemy = op->enemy;
1441 } 1441 }
1442} 1442}
1443 1443
1610void 1610void
1611check_earthwalls (object *op, maptile *m, int x, int y) 1611check_earthwalls (object *op, maptile *m, int x, int y)
1612{ 1612{
1613 object *tmp; 1613 object *tmp;
1614 1614
1615 for (tmp = get_map_ob (m, x, y); tmp != NULL; tmp = tmp->above) 1615 for (tmp = GET_MAP_OB (m, x, y); tmp != NULL; tmp = tmp->above)
1616 { 1616 {
1617 if (tmp->type == EARTHWALL) 1617 if (tmp->type == EARTHWALL)
1618 { 1618 {
1619 hit_player (tmp, op->stats.dam, op, AT_PHYSICAL, 1); 1619 hit_player (tmp, op->stats.dam, op, AT_PHYSICAL, 1);
1620 return; 1620 return;
1625void 1625void
1626check_doors (object *op, maptile *m, int x, int y) 1626check_doors (object *op, maptile *m, int x, int y)
1627{ 1627{
1628 object *tmp; 1628 object *tmp;
1629 1629
1630 for (tmp = get_map_ob (m, x, y); tmp != NULL; tmp = tmp->above) 1630 for (tmp = GET_MAP_OB (m, x, y); tmp != NULL; tmp = tmp->above)
1631 { 1631 {
1632 if (tmp->type == DOOR) 1632 if (tmp->type == DOOR)
1633 { 1633 {
1634 hit_player (tmp, 1000, op, AT_PHYSICAL, 1); 1634 hit_player (tmp, 1000, op, AT_PHYSICAL, 1);
1635 return; 1635 return;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines