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

Comparing deliantra/server/include/treasure.h (file contents):
Revision 1.21 by root, Thu Nov 8 19:43:25 2007 UTC vs.
Revision 1.24 by root, Tue May 6 16:55:26 2008 UTC

1/* 1/*
2 * This file is part of Deliantra, the Roguelike Realtime MMORPG. 2 * This file is part of Deliantra, the Roguelike Realtime MMORPG.
3 * 3 *
4 * Copyright (©) 2005,2006,2007 Marc Alexander Lehmann / Robin Redeker / the Deliantra team 4 * Copyright (©) 2005,2006,2007,2008 Marc Alexander Lehmann / Robin Redeker / the Deliantra team
5 * Copyright (©) 2002,2007 Mark Wedel & Crossfire Development Team 5 * Copyright (©) 2002,2007 Mark Wedel & Crossfire Development Team
6 * Copyright (©) 1992,2007 Frank Tore Johansen 6 * Copyright (©) 1992,2007 Frank Tore Johansen
7 * 7 *
8 * Deliantra is free software: you can redistribute it and/or modify 8 * Deliantra is free software: you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by 9 * it under the terms of the GNU General Public License as published by
48 GT_ENVIRONMENT = 0x0001, // put treasure at objetc, not into object 48 GT_ENVIRONMENT = 0x0001, // put treasure at objetc, not into object
49 GT_INVISIBLE = 0x0002, 49 GT_INVISIBLE = 0x0002,
50 GT_STARTEQUIP = 0x0004, 50 GT_STARTEQUIP = 0x0004,
51 GT_APPLY = 0x0008, 51 GT_APPLY = 0x0008,
52 GT_ONLY_GOOD = 0x0010, 52 GT_ONLY_GOOD = 0x0010,
53 GT_UPDATE_INV = 0x0020,
54 GT_MINIMAL = 0x0040, // Do minimal adjustments 53 GT_MINIMAL = 0x0020, // Do minimal adjustments
55}; 54};
56 55
57/* when a treasure got cloned from archlist, we want perhaps change some default 56/* when a treasure got cloned from archlist, we want perhaps change some default
58 * values. All values in this structure will override the default arch. 57 * values. All values in this structure will override the default arch.
59 * TODO: It is a bad way to implement this with a special structure. 58 * TODO: It is a bad way to implement this with a special structure.
76 * to get generated standard treasure when an archetype of that type 75 * to get generated standard treasure when an archetype of that type
77 * is generated (from a generator) 76 * is generated (from a generator)
78*/ 77*/
79struct treasure : zero_initialised 78struct treasure : zero_initialised
80{ 79{
81 struct archetype *item; /* Which item this link can be */ 80 arch_ptr item; /* Which item this link can be */
82 shstr name; /* If non null, name of list to use 81 shstr name; /* If non null, name of list to use
83 instead */ 82 instead */
84 treasure *next; /* Next treasure-item in a linked list */ 83 treasure *next; /* Next treasure-item in a linked list */
85 treasure *next_yes; /* If this item was generated, use */ 84 treasure *next_yes; /* If this item was generated, use */
86 /* this link instead of ->next */ 85 /* this link instead of ->next */
87 treasure *next_no; /* If this item was not generated, */ 86 treasure *next_no; /* If this item was not generated, */
88 /* then continue here */ 87 /* then continue here */
89 struct _change_arch change_arch; /* override default arch values if set in treasure list */ 88 struct _change_arch change_arch; /* override default arch values if set in treasure list */
90 uint16 chance; /* Percent chance for this item */ 89 uint16 chance; /* Percent chance for this item */
91 /* If the entry is a list transition, 90 /* If the entry is a list transition,
92 * 'magic' contains the difficulty 91 * 'magic' contains the difficulty
93 * required to go to the new list 92 * required to go to the new list
94 */ 93 */
95 uint16 nrof; /* random 1 to nrof items are generated */ 94 uint16 nrof; /* random 1 to nrof items are generated */
96 uint8 magic; /* Max magic bonus to item */ 95 uint8 magic; /* Max magic bonus to item */
97 96
98 treasure () 97 treasure ()
99 : chance (100) 98 : chance (100)
100 { } 99 { }
101}; 100};

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines