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

Comparing deliantra/server/server/pets.C (file contents):
Revision 1.32 by root, Thu May 17 15:55:29 2007 UTC vs.
Revision 1.33 by root, Thu May 24 00:28:41 2007 UTC

1/* 1/*
2 * CrossFire, A Multiplayer game for X-windows 2 * CrossFire, A Multiplayer game
3 * 3 *
4 * Copyright (C) 2005, 2006, 2007 Marc Lehmann & Crossfire+ Development Team 4 * Copyright (C) 2005, 2006, 2007 Marc Lehmann & Crossfire+ Development Team
5 * Copyright (C) 2002 Mark Wedel & Crossfire Development Team 5 * Copyright (C) 2002 Mark Wedel & Crossfire Development Team
6 * Copyright (C) 1992 Frank Tore Johansen 6 * Copyright (C) 1992 Frank Tore Johansen
7 * 7 *
293int 293int
294follow_owner (object *ob, object *owner) 294follow_owner (object *ob, object *owner)
295{ 295{
296 if (owner->flag [FLAG_REMOVED]) 296 if (owner->flag [FLAG_REMOVED])
297 return 0; // do nothing if the owner is removed 297 return 0; // do nothing if the owner is removed
298 else if (owner->map && owner->map->in_memory != MAP_IN_MEMORY) 298 else if (!owner->map || owner->map->in_memory != MAP_IN_MEMORY)
299 LOG (llevError, "Owner of the pet not on a map in memory!?\n"); 299 LOG (llevError, "owner '%s' of the pet '%s' not on a map in memory!?\n", &owner->name, &ob->name);
300 else 300 else
301 { 301 {
302 int dir = find_free_spot (ob, owner->map, owner->x, owner->y, 1, SIZEOFFREE); 302 int dir = find_free_spot (ob, owner->map, owner->x, owner->y, 1, SIZEOFFREE);
303 303
304 if (dir >= 0) 304 if (dir >= 0)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines