Pol  Revision:cb584c9
layers.h
Go to the documentation of this file.
1 
9 #ifndef __LAYERS_H
10 #define __LAYERS_H
11 
12 #include <string>
13 #include <vector>
14 
15 namespace Pol
16 {
17 namespace Core
18 {
19 struct ArmorZone
20 {
21  std::string name;
22  double chance;
23  std::vector<unsigned short> layers;
24 };
25 
27 {
31  NUM_LAYERS = 25,
34 };
35 
36 // TODO: figure out which is left and right
38 {
44  LAYER_HAT = 6,
49  LAYER_HAIR = 11,
53  LAYER_FACE = 15, // UO:KR/SA Face item
64 };
65 
66 /*
67 layering. 'worn items' for a character seem to occupy different
68 'layer' locations. I've seen the following:
69 0x01 1 dagger (right-hand?)
70 0x02 2 left hand - staffs, pitchfork, crook etc.
71 0x03 3 shoes
72 0x04 4 pants
73 0x05 5 shirt
74 0x06 6 hat
75 0x07 7 gloves
76 0x08 8 ring?
77 0x09 9 talismans
78 0x0A 10 gorget
79 0x0B 11 hair
80 0x0C 12 half-apron
81 0x0D 13 (armor)tunic/chest armor, belt pouch (?)
82 0x0E 14 bracelet
83 0x0F 15 backpack (wtf? the "real" backpack sits in layer 21)
84 0x10 16 beard
85 0x11 17 full apron, body sash, doublet, jester suit, tunic, surcoat
86 0x12 18 earrings
87 0x13 19 arms
88 0x14 20 cloak
89 0x15 21 backpack
90 0x16 22 dresses, robes
91 0x17 23 skirt, kilt
92 0x18 24 platemail legs
93 0x19 25 horse?
94 0x1A 26 Buy Container
95 0x1B 27 Resale Container
96 0x1C 28 Sell Container
97 0x1D 29 Bankbox
98 0x1E 30 unknown
99 0x1F 31 unknown
100 
101 
102 
103 I assume that there can only be a single item in each layer.
104 Note that for the most part, the code doesn't need to know this. The
105 data is in tiledata.mul (we don't check this yet), and the client
106 makes sure to drop items only in the correct layer (again, server
107 needs to check this). The only spcial case is the backpack -
108 Character::backpack() uses LAYER_BACKPACK to return the backpack item.
109 */
110 }
111 }
112 #endif
std::vector< unsigned short > layers
Definition: layers.h:23
std::string name
Definition: layers.h:21
LAYER_DETAILED
Definition: layers.h:37
LAYER_INFO
Definition: layers.h:26
Definition: berror.cpp:12