ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/region.h
(Generate patch)

Comparing deliantra/server/include/region.h (file contents):
Revision 1.7 by root, Wed Jul 11 16:55:18 2007 UTC vs.
Revision 1.8 by root, Fri Jul 13 15:54:40 2007 UTC

27 */ 27 */
28 28
29#ifndef REGION_H 29#ifndef REGION_H
30#define REGION_H 30#define REGION_H
31 31
32typedef refptr<region> region_ptr;
33
32/* 34/*
33 * Each map is in a given region of the game world and links to a region definition, so 35 * Each map is in a given region of the game world and links to a region definition, so
34 * they have to appear here in the headers, before the mapdef 36 * they have to appear here in the headers, before the mapdef
35 */ 37 */
36INTERFACE_CLASS (region) 38INTERFACE_CLASS (region)
37struct region : zero_initialised, attachable 39struct region : zero_initialised, attachable
38{ 40{
39 shstr ACC (RW, name); /* Shortend name of the region as maps refer to it */ 41 shstr ACC (RW, name); /* Shortend name of the region as maps refer to it */
40 region *ACC (RW, parent); /* 42 region_ptr ACC (RW, parent); /*
41 * Pointer to the region that is a parent of the current 43 * Pointer to the region that is a parent of the current
42 * region, if a value isn't defined in the current region 44 * region, if a value isn't defined in the current region
43 * we traverse this series of pointers until it is. 45 * we traverse this series of pointers until it is.
44 */ 46 */
45 shstr ACC (RW, longname); /* Official title of the region, this might be defined 47 shstr ACC (RW, longname); /* Official title of the region, this might be defined
58 60
59 static region *default_region (); 61 static region *default_region ();
60 static region *find (const char *name); 62 static region *find (const char *name);
61 static region *find_fuzzy (const char *name); 63 static region *find_fuzzy (const char *name);
62 static region *read (object_thawer &f); 64 static region *read (object_thawer &f);
65
66 void do_destroy ();
63}; 67};
64 68
65typedef object_vector<region, &region::index> regionvec; 69typedef object_vector<region, &region::index> regionvec;
66 70
67extern regionvec regions; 71extern regionvec regions;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines