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

Comparing deliantra/server/common/loader.C (file contents):
Revision 1.47 by root, Thu Jan 18 19:42:09 2007 UTC vs.
Revision 1.48 by root, Fri Jan 19 17:50:10 2007 UTC

28 28
29 29
30#include <global.h> 30#include <global.h>
31#include <loader.h> 31#include <loader.h>
32#include <sproto.h> 32#include <sproto.h>
33
34// future resource loader base class
35struct loader_base
36{
37 virtual archetype *get_arch (const char *name);
38 virtual void put_arch (archetype *arch);
39
40 virtual object *get_object (const char *name);
41 virtual void put_object (object *op);
42
43 virtual player *get_player ();
44 virtual void put_player (player *pl);
45
46 virtual region *get_region ();
47 virtual void put_region (region *region);
48
49 virtual facetile *get_face (const char *name);
50 virtual void put_face (facetile *face);
51
52 virtual treasurelist *get_treasure (const char *name, bool one = false);
53 virtual void put_treasure (treasurelist *treasure);
54
55 virtual animation *get_animation (const char *name);
56 virtual void put_animation (animation *anim);
57};
58
59// future generic resource loader
60// handles generic stuff valid in most files, such as
61// animations, treasures, faces and so on
62struct loader_generic : loader_base
63{
64 virtual region *get_region ();
65 virtual void put_region (region *region);
66
67 virtual facetile *get_face (const char *name);
68 virtual void put_face (facetile *face);
69
70 virtual treasurelist *get_treasure (const char *name, bool one = false);
71 virtual void put_treasure (treasurelist *treasure);
72
73 virtual animation *get_animation (const char *name);
74 virtual void put_animation (animation *anim);
75};
33 76
34/* Maps the MOVE_* values to names */ 77/* Maps the MOVE_* values to names */
35static const char *const move_name[] = { "walk", "fly_low", "fly_high", "swim", "boat", NULL }; 78static const char *const move_name[] = { "walk", "fly_low", "fly_high", "swim", "boat", NULL };
36 79
37/* This table is only necessary to convert objects that existed before the 80/* This table is only necessary to convert objects that existed before the

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines