| 1 | /* |
| 2 | * Copyright (C) 2000,2001 Onlyer ([email protected]) |
| 3 | * Copyright (C) 2001 sousou ([email protected]) |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or |
| 6 | * modify it under the terms of the GNU General Public License |
| 7 | * as published by the Free Software Foundation; either version 2 |
| 8 | * of the License, or (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program; if not, write to the Free Software |
| 17 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
| 18 | */ |
| 19 | #ifndef INCLUDED_D2CS_D2DBS_LADDER_H |
| 20 | #define INCLUDED_D2CS_D2DBS_LADDER_H |
| 21 | |
| 22 | #include "common/bn_type.h" |
| 23 | #include "common/field_sizes.h" |
| 24 | |
| 25 | namespace pvpgn |
| 26 | { |
| 27 | |
| 28 | typedef struct |
| 29 | { |
| 30 | bn_int type; |
| 31 | bn_int offset; |
| 32 | bn_int number; |
| 33 | } t_d2ladderfile_ladderindex; |
| 34 | |
| 35 | typedef struct |
| 36 | { |
| 37 | bn_int experience; |
| 38 | bn_short status; |
| 39 | bn_byte level; |
| 40 | bn_byte chclass; |
| 41 | char charname[MAX_CHARNAME_LEN]; |
| 42 | } t_d2ladderfile_ladderinfo; |
| 43 | |
| 44 | typedef struct |
| 45 | { |
| 46 | bn_int maxtype; |
| 47 | bn_int checksum; |
| 48 | } t_d2ladderfile_header; |
| 49 | |
| 50 | } |
| 51 | |
| 52 | #define LADDER_FILE_PREFIX "ladder" |
| 53 | |
| 54 | #define D2LADDER_HC_OVERALL 0x00 |
| 55 | #define D2LADDER_STD_OVERALL 0x09 |
| 56 | #define D2LADDER_EXP_HC_OVERALL 0x13 |
| 57 | #define D2LADDER_EXP_STD_OVERALL 0x1B |
| 58 | const unsigned D2CHAR_CLASS_MAX = 0x04; |
| 59 | const unsigned D2CHAR_EXP_CLASS_MAX = 0x06; |
| 60 | |
| 61 | #endif |