Mercurial > mm7
annotate Items.cpp @ 2198:d9caf2b3d8d5
draw FlyAction and WaterWalk icons
author | Ritor1 |
---|---|
date | Sun, 02 Feb 2014 00:10:40 +0600 |
parents | 70b63fe6587c |
children | 3cc3a29f073b |
rev | line source |
---|---|
0 | 1 #include <stdlib.h> |
2 | |
3 #include "Items.h" | |
4 #include "MapInfo.h" | |
461 | 5 #include "GUIWindow.h" |
6 #include "Events2D.h" | |
7 #include "Chest.h" | |
0 | 8 #include "LOD.h" |
9 #include "Monsters.h" | |
10 #include "Party.h" | |
11 #include "FactionTable.h" | |
12 #include "StorylineTextTable.h" | |
189 | 13 #include "texts.h" |
0 | 14 #include "mm7_data.h" |
15 | |
16 | |
17 | |
463 | 18 struct ITEM_VARIATION |
19 { | |
20 unsigned __int16 treasure_level; | |
21 unsigned __int16 item_class[4]; | |
22 }; | |
23 | |
24 | |
1202 | 25 std::array<const char, 5> uItemsAmountPerShopType={ 0, 6, 8, 12, 12}; |
463 | 26 |
526 | 27 const ITEM_VARIATION shopWeap_variation_ord[15] ={ |
463 | 28 { 0, { 0, 0, 0, 0 }}, |
29 { 1, { 23, 27, 20, 20 }}, | |
30 { 1, { 23, 24, 28, 20 }}, | |
31 { 2, { 23, 24, 25, 20 }}, | |
32 { 2, { 27, 27, 26, 26 }}, | |
33 { 4, { 24, 30, 25, 27 }}, | |
34 { 4, { 24, 30, 25, 27 }}, | |
35 { 3, { 30, 24, 20, 20 }}, | |
36 { 2, { 20, 20, 20, 20 }}, | |
37 { 3, { 27, 27, 26, 26 }}, | |
38 { 3, { 28, 28, 25, 25 }}, | |
39 { 2, { 23, 23, 24, 24 }}, | |
40 { 3, { 23, 23, 26, 26 }}, | |
41 { 2, { 30, 26, 26, 26 }}, | |
42 { 2, { 28, 25, 28, 29 }}}; | |
43 | |
526 | 44 const ITEM_VARIATION shopArmr_variation_ord[28] ={ |
463 | 45 { 1, { 35, 35, 38, 38 }}, |
46 { 1, { 31, 31, 31, 34 }}, | |
47 { 1, { 35, 35, 38, 38 }}, | |
48 { 1, { 31, 31, 32, 34 }}, | |
49 { 2, { 35, 35, 38, 38 }}, | |
50 { 2, { 31, 32, 32, 33 }}, | |
51 { 2, { 35, 35, 38, 38 }}, | |
52 { 2, { 31, 31, 32, 32 }}, | |
53 { 4, { 35, 35, 38, 38 }}, | |
54 { 4, { 31, 32, 33, 34 }}, | |
55 { 4, { 35, 35, 38, 38 }}, | |
56 { 4, { 31, 32, 33, 34 }}, | |
57 { 3, { 35, 35, 38, 38 }}, | |
58 { 3, { 31, 31, 31, 31 }}, | |
59 { 2, { 35, 35, 38, 38 }}, | |
60 { 2, { 31, 32, 34, 34 }}, | |
61 { 3, { 35, 35, 38, 38 }}, | |
62 { 3, { 31, 31, 32, 32 }}, | |
63 { 3, { 35, 35, 38, 38 }}, | |
64 { 3, { 32, 32, 32, 33 }}, | |
65 { 3, { 35, 35, 38, 38 }}, | |
66 { 3, { 31, 31, 31, 32 }}, | |
67 { 3, { 35, 35, 38, 38 }}, | |
68 { 3, { 33, 31, 32, 34 }}, | |
69 { 3, { 35, 35, 38, 38 }}, | |
70 { 3, { 33, 31, 32, 34 }}, | |
71 { 4, { 35, 35, 38, 38 }}, | |
72 { 4, { 33, 31, 32, 34 }}}; | |
73 | |
74 | |
75 | |
526 | 76 const unsigned __int16 shopMagic_treasure_lvl[14]= {0, 1, 1, 2, 2, 4, 4, 3, 2, 2, 2, 2, 2, 2}; |
77 const unsigned __int16 shopAlch_treasure_lvl[13] = {0, 1, 1, 2, 2, 3, 3, 4, 4, 2, 2, 2, 2}; | |
463 | 78 |
526 | 79 const ITEM_VARIATION shopWeap_variation_spc[15]={ |
463 | 80 { 0, { 0, 0, 0, 0 }}, |
470 | 81 { 2, { 25, 30, 20, 20}}, |
82 { 2, { 23, 24, 28, 20}}, | |
83 { 3, { 23, 24, 25, 20}}, | |
84 { 3, { 27, 27, 26, 26}}, | |
85 { 5, { 23, 26, 28, 27}}, | |
86 { 5, { 23, 26, 28, 27}}, | |
87 { 4, { 30, 24, 20, 20}}, | |
88 { 3, { 20, 20, 20, 20}}, | |
89 { 4, { 27, 27, 26, 26}}, | |
90 { 4, { 28, 28, 25, 25}}, | |
91 { 4, { 23, 23, 24, 24}}, | |
92 { 4, { 24, 24, 27, 20}}, | |
93 { 4, { 30, 26, 26, 26}}, | |
94 { 4, { 28, 25, 28, 29}}}; | |
463 | 95 |
526 | 96 const ITEM_VARIATION shopArmr_variation_spc[28]={ |
470 | 97 { 2, { 35, 35, 38, 38 }}, |
98 { 2, { 31, 31, 31, 34 }}, | |
99 { 2, { 35, 35, 38, 38 }}, | |
100 { 2, { 31, 31, 32, 34 }}, | |
101 { 3, { 35, 35, 38, 38 }}, | |
102 { 3, { 31, 32, 32, 33 }}, | |
103 { 3, { 35, 35, 38, 38 }}, | |
104 { 3, { 31, 31, 32, 32 }}, | |
105 { 5, { 35, 35, 38, 38 }}, | |
106 { 5, { 31, 32, 33, 34 }}, | |
107 { 5, { 35, 35, 38, 38 }}, | |
108 { 5, { 31, 32, 33, 34 }}, | |
109 { 4, { 35, 35, 38, 38 }}, | |
110 { 4, { 31, 31, 31, 31 }}, | |
111 { 3, { 35, 35, 38, 38 }}, | |
112 { 3, { 31, 32, 34, 34 }}, | |
113 { 4, { 35, 35, 38, 38 }}, | |
114 { 4, { 31, 31, 32, 33 }}, | |
115 { 4, { 35, 35, 38, 38 }}, | |
116 { 4, { 32, 32, 33, 34 }}, | |
117 { 4, { 35, 35, 38, 38 }}, | |
118 { 4, { 31, 31, 31, 32 }}, | |
119 { 4, { 35, 35, 38, 38 }}, | |
120 { 4, { 32, 32, 32, 32 }}, | |
121 { 4, { 35, 35, 38, 38 }}, | |
122 { 4, { 34, 34, 34, 34 }}, | |
123 { 5, { 35, 35, 38, 38 }}, | |
124 { 5, { 33, 33, 33, 33 }} | |
125 }; | |
463 | 126 |
526 | 127 const unsigned __int16 shopMagicSpc_treasure_lvl[14] = {0, 2, 2, 3, 3, 5, 5, 4, 3, 3, 3, 3, 3, 3}; |
128 const unsigned __int16 shopAlchSpc_treasure_lvl[13] = {0, 2, 2, 3, 3, 4, 4, 5, 5, 3, 2, 2, 2}; | |
129 | |
130 | |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
131 std::array< std::array<char, 14>, 7> byte_4E8168={{ //byte_4E8178 |
526 | 132 { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}, |
133 { 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2}, | |
134 { 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3}, | |
135 { 2, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4}, | |
136 { 2, 2, 2, 2, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5}, | |
137 { 2, 2, 2, 2, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6}, | |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
138 { 2, 2, 2, 2, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7}}}; |
0 | 139 |
475 | 140 int sub_4BE571(int a1, int *a2, int a3, int a4); |
0 | 141 |
1682 | 142 ItemGen *ptr_50C9A4_ItemToEnchant; |
0 | 143 |
315 | 144 struct ItemsTable *pItemsTable; // 005D29E0 |
0 | 145 |
146 | |
147 | |
148 | |
149 | |
150 //----- (00439DF3) -------------------------------------------------------- | |
385 | 151 int ItemGen::_439DF3_get_additional_damage(int *damage_type, bool *draintargetHP) |
152 { | |
1933
5fcf6023f9c3
DamageMonsterFromParty some additional vars removed, changed the ordering part to something more readable
Grumpy7
parents:
1920
diff
changeset
|
153 *draintargetHP = false; |
385 | 154 *damage_type = 0; |
155 if ( !uItemID ) | |
156 return 0; | |
157 UpdateTempBonus(pParty->uTimePlayed); | |
158 if (uItemID == 501 ) //Iron Feather -sword | |
159 { | |
160 *damage_type = 1; | |
161 return rand() % 10 + 6; | |
162 } | |
163 if (uItemID == 507 ) //Ghoulsbane -axe | |
164 { | |
165 *damage_type = 0; | |
166 return rand() % 16 + 3; | |
167 } | |
168 if ( uItemID == 510 ) //Ullyses -bow | |
169 { | |
170 *damage_type = 2; | |
171 return rand() % 4 + 9; | |
172 } | |
173 if ( uItemID == 517 ) //Old Nick -dagger | |
174 { | |
175 *damage_type = 8; | |
176 return 8; | |
177 } | |
0 | 178 |
385 | 179 switch (uSpecEnchantmentType) |
180 { | |
181 case 4: //Adds 3-4 points of Cold damage. | |
182 *damage_type = 2; | |
183 return rand() % 2 + 3; | |
184 break; | |
185 case 5: //Adds 6-8 points of Cold damage. | |
186 *damage_type = 2; | |
187 return rand() % 3 + 6; | |
188 break; | |
189 case 6: //Adds 9-12 points of Cold damage. | |
190 *damage_type = 2; | |
191 return rand() % 4 + 9; | |
192 break; | |
193 case 7: //Adds 2-5 points of Electrical damage. | |
194 *damage_type = 1; | |
195 return rand() % 4 + 2; | |
196 break; | |
197 case 8: //Adds 4-10 points of Electrical damage. | |
198 *damage_type = 1; | |
199 return rand() % 7 + 4; | |
200 break; | |
201 case 9: //Adds 6-15 points of Electrical damage. | |
202 *damage_type = 1; | |
203 return rand() % 10 + 6; | |
204 break; | |
205 case 10: //Adds 1-6 points of Fire damage. | |
206 *damage_type = 0; | |
207 return GetDiceResult(1, 6); | |
208 break; | |
209 case 11: //Adds 2-12 points of Fire damage. | |
210 *damage_type = 0; | |
211 return GetDiceResult(2, 6); | |
212 break; | |
213 case 12: //Adds 3-18 points of Fire damage. | |
214 *damage_type = 0; | |
215 return GetDiceResult(3, 6); | |
216 break; | |
217 case 13: //Adds 5 points of Body damage. | |
218 *damage_type = 8; | |
219 return 5; | |
220 break; | |
221 case 14: //Adds 8 points of Body damage. | |
222 *damage_type = 8; | |
223 return 8; | |
224 break; | |
225 case 15: //Adds 12 points of Body damage. | |
226 *damage_type = 8; | |
227 return 12; | |
228 break; | |
229 case 16: //Drain Hit Points from target. | |
230 case 41: //Drain Hit Points from target and Increased Weapon speed. | |
231 *damage_type = 10; | |
232 *draintargetHP = true; | |
233 return 0; | |
234 break; | |
235 case 46: //Adds 10-20 points of Fire damage and +25 Might. | |
236 *damage_type = 0; | |
237 return rand() % 11 + 10; | |
238 break; | |
239 default: | |
240 *damage_type = 0; | |
241 return 0; | |
242 | |
243 } | |
244 | |
245 } | |
0 | 246 |
247 | |
248 //----- (00402F07) -------------------------------------------------------- | |
249 void ItemGen::Reset() | |
250 { | |
377 | 251 this->uHolderPlayer = 0; |
0 | 252 this->uAttributes = 0; |
253 this->uNumCharges = 0; | |
377 | 254 this->uSpecEnchantmentType = 0; |
1599 | 255 this->m_enchantmentStrength = 0; |
570 | 256 this->uEnchantmentType = 0; |
0 | 257 this->uItemID = 0; |
258 this->uBodyAnchor = 0; | |
259 this->uExpireTime = 0i64; | |
260 } | |
261 | |
262 //----- (00458260) -------------------------------------------------------- | |
263 void ItemGen::UpdateTempBonus(__int64 uTimePlayed) | |
264 { | |
463 | 265 if ( this->uAttributes & ITEM_TEMP_BONUS ) |
0 | 266 { |
267 if ( uTimePlayed > (signed __int64)this->uExpireTime ) | |
268 { | |
570 | 269 this->uEnchantmentType = 0; |
377 | 270 this->uSpecEnchantmentType = 0; |
463 | 271 this->uAttributes = this->uAttributes&(~ITEM_TEMP_BONUS); |
0 | 272 } |
273 } | |
274 } | |
275 | |
276 //----- (0045814E) -------------------------------------------------------- | |
374 | 277 void ItemsTable::Release() |
0 | 278 { |
279 if ( pMonstersTXT_Raw ) | |
1583 | 280 free(pMonstersTXT_Raw); |
0 | 281 if ( pMonsterPlacementTXT_Raw ) |
1583 | 282 free(pMonsterPlacementTXT_Raw); |
0 | 283 if ( pSkillDescTXT_Raw ) |
1583 | 284 free(pSkillDescTXT_Raw); |
374 | 285 if (pSpcItemsTXT_Raw ) |
1583 | 286 free(pSpcItemsTXT_Raw); |
374 | 287 if ( pStdItemsTXT_Raw ) |
1583 | 288 free(pStdItemsTXT_Raw); |
374 | 289 if ( pRndItemsTXT_Raw ) |
1583 | 290 free(pRndItemsTXT_Raw); |
374 | 291 if ( pItemsTXT_Raw ) |
1583 | 292 free(pItemsTXT_Raw); |
0 | 293 if ( pHostileTXT_Raw ) |
1583 | 294 free(pHostileTXT_Raw); |
0 | 295 if ( pHistoryTXT_Raw ) |
1583 | 296 free(pHistoryTXT_Raw); |
0 | 297 if ( pPotionsTXT_Raw ) |
1583 | 298 free(pPotionsTXT_Raw); |
0 | 299 if ( pPotionNotesTXT_Raw ) |
1583 | 300 free(pPotionNotesTXT_Raw); |
374 | 301 pSpcItemsTXT_Raw = NULL; |
302 pSkillDescTXT_Raw = NULL; | |
303 pStdItemsTXT_Raw = NULL; | |
304 pRndItemsTXT_Raw = NULL; | |
305 pItemsTXT_Raw = NULL; | |
0 | 306 } |
307 | |
1082 | 308 |
0 | 309 //----- (00456D84) -------------------------------------------------------- |
310 void ItemsTable::Initialize() | |
224 | 311 { |
312 int i,j; | |
313 char* test_string; | |
229 | 314 unsigned char c; |
224 | 315 bool break_loop; |
316 unsigned int temp_str_len; | |
317 char* tmp_pos; | |
318 int decode_step; | |
319 int item_counter; | |
320 | |
321 pMapStats = new MapStats; | |
322 pMapStats->Initialize(); | |
323 | |
324 pMonsterStats = new MonsterStats; | |
325 pMonsterStats->Initialize(); | |
326 pMonsterStats->InitializePlacements(); | |
327 | |
328 pSpellStats = new SpellStats; | |
329 pSpellStats->Initialize(); | |
330 | |
331 LoadPotions(); | |
332 LoadPotionNotes(); | |
333 | |
334 pFactionTable = new FactionTable; | |
335 pFactionTable->Initialize(); | |
336 | |
337 pStorylineText = new StorylineText; | |
338 pStorylineText->Initialize(); | |
0 | 339 |
224 | 340 pStdItemsTXT_Raw = NULL; |
341 pStdItemsTXT_Raw = (char *)pEvents_LOD->LoadRaw("stditems.txt", 0); | |
342 strtok(pStdItemsTXT_Raw, "\r"); | |
343 strtok(NULL, "\r"); | |
344 strtok(NULL, "\r"); | |
345 strtok(NULL, "\r"); | |
346 //Standard Bonuses by Group | |
347 for (i=0;i<24;++i) | |
348 { | |
349 test_string = strtok(NULL, "\r") + 1; | |
350 break_loop = false; | |
351 decode_step=0; | |
352 do | |
353 { | |
354 c = *(unsigned char*)test_string; | |
355 temp_str_len = 0; | |
356 while((c!='\t')&&(c>0)) | |
357 { | |
358 ++temp_str_len; | |
359 c=test_string[temp_str_len]; | |
360 } | |
361 tmp_pos=test_string+temp_str_len; | |
362 if (*tmp_pos == 0) | |
363 break_loop = true; | |
364 *tmp_pos = 0; | |
365 if (temp_str_len) | |
366 { | |
367 switch (decode_step) | |
368 { | |
369 case 0: | |
370 pEnchantments[i].pBonusStat=RemoveQuotes(test_string); | |
371 break; | |
372 case 1: | |
373 pEnchantments[i].pOfName= RemoveQuotes(test_string); | |
374 break; | |
375 default: | |
376 pEnchantments[i].to_item[decode_step-2]=atoi(test_string); | |
377 } | |
378 } | |
379 else | |
380 { | |
570 | 381 if (decode_step) |
224 | 382 break_loop = true; |
383 } | |
384 ++decode_step; | |
385 test_string=tmp_pos+1; | |
386 } while ((decode_step<11)&&!break_loop); | |
387 } | |
0 | 388 |
224 | 389 memset(&pEnchantmentsSumm, 0, 36); |
390 for(i=0;i<9;++i) | |
391 { | |
392 for (j=0;j<24;++j) | |
393 pEnchantmentsSumm[i]+=pEnchantments[j].to_item[i]; | |
394 } | |
0 | 395 |
224 | 396 //Bonus range for Standard by Level |
397 strtok(NULL, "\r"); | |
398 strtok(NULL, "\r"); | |
399 strtok(NULL, "\r"); | |
400 strtok(NULL, "\r"); | |
401 strtok(NULL, "\r"); | |
402 for(i=0;i<6;++i) //counted from 1 | |
403 { | |
404 test_string = strtok(NULL, "\r") + 1; | |
405 break_loop = false; | |
406 decode_step=0; | |
407 do | |
408 { | |
409 c = *(unsigned char*)test_string; | |
410 temp_str_len = 0; | |
411 while((c!='\t')&&(c>0)) | |
412 { | |
413 ++temp_str_len; | |
414 c=test_string[temp_str_len]; | |
415 } | |
416 tmp_pos=test_string+temp_str_len; | |
417 if (*tmp_pos == 0) | |
418 break_loop = true; | |
419 *tmp_pos = 0; | |
420 if (decode_step==2) | |
421 bonus_ranges[i].minR = atoi(test_string); | |
422 else if (decode_step==3) | |
423 bonus_ranges[i].maxR =atoi(test_string); | |
424 ++decode_step; | |
425 test_string=tmp_pos+1; | |
426 } while ((decode_step<4)&&!break_loop); | |
427 } | |
428 | |
222 | 429 |
224 | 430 pSpcItemsTXT_Raw = 0; |
431 pSpcItemsTXT_Raw = (char *)pEvents_LOD->LoadRaw("spcitems.txt", 0); | |
432 strtok(pSpcItemsTXT_Raw, "\r"); | |
433 strtok(NULL, "\r"); | |
434 strtok(NULL, "\r"); | |
435 strtok(NULL, "\r"); | |
436 for (i=0;i<72;++i) | |
437 { | |
438 test_string = strtok(NULL, "\r") + 1; | |
439 break_loop = false; | |
440 decode_step=0; | |
441 do | |
442 { | |
443 c = *(unsigned char*)test_string; | |
444 temp_str_len = 0; | |
445 while((c!='\t')&&(c>0)) | |
446 { | |
447 ++temp_str_len; | |
448 c=test_string[temp_str_len]; | |
449 } | |
450 tmp_pos=test_string+temp_str_len; | |
451 if (*tmp_pos == 0) | |
452 break_loop = true; | |
453 *tmp_pos = 0; | |
454 if (temp_str_len) | |
455 { | |
456 switch (decode_step) | |
457 { | |
458 case 0: | |
459 pSpecialEnchantments[i].pBonusStatement=RemoveQuotes(test_string); | |
460 break; | |
461 case 1: | |
462 pSpecialEnchantments[i].pNameAdd= RemoveQuotes(test_string); | |
463 break; | |
464 case 14: | |
465 int res; | |
466 res=atoi(test_string); | |
467 if(!res) | |
468 { | |
469 ++test_string; | |
470 while (*test_string==' ')//fix X 2 case | |
471 ++test_string; | |
222 | 472 res=atoi(test_string); |
224 | 473 } |
474 pSpecialEnchantments[i].iValue=res; | |
475 break; | |
476 case 15: | |
477 pSpecialEnchantments[i].iTreasureLevel= tolower(*test_string) - 97;; | |
478 break; | |
479 default: | |
480 pSpecialEnchantments[i].to_item_apply[decode_step-2]=atoi(test_string); | |
481 } | |
482 } | |
483 else | |
484 { | |
570 | 485 if (decode_step) |
224 | 486 break_loop = true; |
487 } | |
488 ++decode_step; | |
489 test_string=tmp_pos+1; | |
490 } while ((decode_step<16)&&!break_loop); | |
491 } | |
492 | |
493 pSpecialEnchantments_count = 71; | |
494 memset(&pSpecialEnchantmentsSumm, 0, 96); | |
495 for(i=0;i<12;++i) | |
496 { | |
570 | 497 for (j=0;j<=pSpecialEnchantments_count;++j) |
224 | 498 pSpecialEnchantmentsSumm[i]+=pSpecialEnchantments[j].to_item_apply[i]; |
499 } | |
222 | 500 |
224 | 501 Initialize2DA(); |
222 | 502 |
224 | 503 pItemsTXT_Raw = NULL; |
504 pItemsTXT_Raw = (char*) pEvents_LOD->LoadRaw("items.txt", 0); | |
505 strtok(pItemsTXT_Raw, "\r"); | |
506 strtok(NULL, "\r"); | |
507 uAllItemsCount = 0; | |
508 item_counter = 0; | |
222 | 509 while (true) |
510 { | |
511 test_string = strtok(NULL, "\r") + 1; | |
512 break_loop = false; | |
513 decode_step=0; | |
514 do | |
515 { | |
516 c = *(unsigned char*)test_string; | |
517 temp_str_len = 0; | |
518 while((c!='\t')&&(c>0)) | |
519 { | |
520 ++temp_str_len; | |
521 c=test_string[temp_str_len]; | |
522 } | |
523 tmp_pos=test_string+temp_str_len; | |
524 if (*tmp_pos == 0) | |
525 break_loop = true; | |
526 *tmp_pos = 0; | |
527 if (temp_str_len) | |
528 { | |
529 switch (decode_step) | |
530 { | |
531 case 0: //Item # | |
532 item_counter=atoi(test_string); | |
533 uAllItemsCount=item_counter; | |
534 break; | |
535 case 1: //Pic File | |
536 pItems[item_counter].pIconName = RemoveQuotes(test_string); | |
537 break; | |
538 case 2: //Name | |
539 pItems[item_counter].pName = RemoveQuotes(test_string); | |
540 break; | |
541 case 3: //Value | |
542 pItems[item_counter].uValue=atoi(test_string); | |
543 break; | |
544 case 4: //Equip Stat | |
545 { | |
1104 | 546 if ( !_stricmp(test_string, "weapon") ) |
222 | 547 { |
1989 | 548 pItems[item_counter].uEquipType = EQUIP_SINGLE_HANDED; |
222 | 549 break; |
550 } | |
1104 | 551 if ( !_stricmp(test_string, "weapon2") ) |
222 | 552 { |
1989 | 553 pItems[item_counter].uEquipType = EQUIP_TWO_HANDED; |
222 | 554 break; |
555 } | |
1104 | 556 if ( !_stricmp(test_string, "weapon1or2") ) |
222 | 557 { |
1989 | 558 pItems[item_counter].uEquipType = EQUIP_SINGLE_HANDED; |
222 | 559 break; |
560 } | |
1104 | 561 if ( !(_stricmp(test_string, "missile")&&_stricmp(test_string, "bow"))) |
222 | 562 { |
365 | 563 pItems[item_counter].uEquipType = EQUIP_BOW; |
222 | 564 break; |
565 } | |
1104 | 566 if ( !_stricmp(test_string, "armor") ) |
222 | 567 { |
365 | 568 pItems[item_counter].uEquipType = EQUIP_ARMOUR; |
222 | 569 break; |
570 } | |
1104 | 571 if ( !_stricmp(test_string, "shield") ) |
222 | 572 { |
365 | 573 pItems[item_counter].uEquipType = EQUIP_SHIELD; |
222 | 574 break; |
575 } | |
1104 | 576 if ( !_stricmp(test_string, "helm") ) |
222 | 577 { |
365 | 578 pItems[item_counter].uEquipType = EQUIP_HELMET; |
222 | 579 break; |
580 } | |
1104 | 581 if ( !_stricmp(test_string, "belt") ) |
222 | 582 { |
365 | 583 pItems[item_counter].uEquipType = EQUIP_BELT; |
222 | 584 break; |
585 } | |
1104 | 586 if ( !_stricmp(test_string, "cloak") ) |
222 | 587 { |
365 | 588 pItems[item_counter].uEquipType = EQUIP_CLOAK; |
222 | 589 break; |
590 } | |
1104 | 591 if ( !_stricmp(test_string, "gauntlets") ) |
222 | 592 { |
365 | 593 pItems[item_counter].uEquipType = EQUIP_GAUNTLETS; |
222 | 594 break; |
595 } | |
1104 | 596 if ( !_stricmp(test_string, "boots") ) |
222 | 597 { |
365 | 598 pItems[item_counter].uEquipType = EQUIP_BOOTS; |
222 | 599 break; |
600 } | |
1104 | 601 if ( !_stricmp(test_string, "ring") ) |
222 | 602 { |
365 | 603 pItems[item_counter].uEquipType = EQUIP_RING; |
222 | 604 break; |
605 } | |
1104 | 606 if ( !_stricmp(test_string, "amulet") ) |
222 | 607 { |
365 | 608 pItems[item_counter].uEquipType = EQUIP_AMULET; |
222 | 609 break; |
610 } | |
1104 | 611 if ( !_stricmp(test_string, "weaponw") ) |
222 | 612 { |
365 | 613 pItems[item_counter].uEquipType = EQUIP_WAND; |
222 | 614 break; |
615 } | |
1104 | 616 if ( !(_stricmp(test_string, "herb")&&_stricmp(test_string, "reagent"))) |
222 | 617 { |
365 | 618 pItems[item_counter].uEquipType = EQUIP_REAGENT; |
222 | 619 break; |
620 } | |
1104 | 621 if ( !_stricmp(test_string, "bottle") ) |
222 | 622 { |
365 | 623 pItems[item_counter].uEquipType = EQUIP_POTION; |
222 | 624 break; |
625 } | |
1104 | 626 if ( !_stricmp(test_string, "sscroll") ) |
222 | 627 { |
374 | 628 pItems[item_counter].uEquipType = EQUIP_SPELL_SCROLL; |
222 | 629 break; |
630 } | |
1104 | 631 if ( !_stricmp(test_string, "book") ) |
222 | 632 { |
365 | 633 pItems[item_counter].uEquipType = EQUIP_BOOK; |
222 | 634 break; |
635 } | |
1104 | 636 if ( !_stricmp(test_string, "mscroll") ) |
222 | 637 { |
374 | 638 pItems[item_counter].uEquipType = EQUIP_MESSAGE_SCROLL; |
222 | 639 break; |
640 } | |
1104 | 641 if ( !_stricmp(test_string, "gold") ) |
222 | 642 { |
365 | 643 pItems[item_counter].uEquipType = EQUIP_GOLD; |
222 | 644 break; |
645 } | |
1104 | 646 if ( !_stricmp(test_string, "gem") ) |
222 | 647 { |
365 | 648 pItems[item_counter].uEquipType = EQUIP_GEM; |
222 | 649 break; |
650 } | |
365 | 651 pItems[item_counter].uEquipType = EQUIP_NONE; |
222 | 652 break; |
653 } | |
654 case 5: //Skill Group | |
655 { | |
1104 | 656 if ( !_stricmp(test_string, "staff") ) |
222 | 657 { |
374 | 658 pItems[item_counter].uSkillType = PLAYER_SKILL_STAFF; |
222 | 659 break; |
660 } | |
1104 | 661 if ( !_stricmp(test_string, "sword") ) |
222 | 662 { |
374 | 663 pItems[item_counter].uSkillType = PLAYER_SKILL_SWORD; |
222 | 664 break; |
665 } | |
1104 | 666 if ( !_stricmp(test_string, "dagger") ) |
222 | 667 { |
374 | 668 pItems[item_counter].uSkillType = PLAYER_SKILL_DAGGER; |
222 | 669 break; |
670 } | |
1104 | 671 if ( !_stricmp(test_string, "axe") ) |
222 | 672 { |
374 | 673 pItems[item_counter].uSkillType = PLAYER_SKILL_AXE; |
222 | 674 break; |
675 } | |
1104 | 676 if ( !_stricmp(test_string, "spear") ) |
222 | 677 { |
374 | 678 pItems[item_counter].uSkillType = PLAYER_SKILL_SPEAR; |
222 | 679 break; |
680 } | |
1104 | 681 if ( !_stricmp(test_string, "bow") ) |
222 | 682 { |
374 | 683 pItems[item_counter].uSkillType = PLAYER_SKILL_BOW; |
222 | 684 break; |
685 } | |
1104 | 686 if ( !_stricmp(test_string, "mace") ) |
222 | 687 { |
374 | 688 pItems[item_counter].uSkillType = PLAYER_SKILL_MACE; |
222 | 689 break; |
690 } | |
1104 | 691 if ( !_stricmp(test_string, "blaster") ) |
222 | 692 { |
374 | 693 pItems[item_counter].uSkillType = PLAYER_SKILL_BLASTER; |
222 | 694 break; |
695 } | |
1104 | 696 if ( !_stricmp(test_string, "shield") ) |
222 | 697 { |
374 | 698 pItems[item_counter].uSkillType = PLAYER_SKILL_SHIELD; |
222 | 699 break; |
700 } | |
1104 | 701 if ( !_stricmp(test_string, "leather") ) |
222 | 702 { |
374 | 703 pItems[item_counter].uSkillType = PLAYER_SKILL_LEATHER; |
222 | 704 break; |
705 } | |
1104 | 706 if ( !_stricmp(test_string, "chain") ) |
222 | 707 { |
374 | 708 pItems[item_counter].uSkillType = PLAYER_SKILL_CHAIN; |
222 | 709 break; |
710 } | |
1104 | 711 if ( !_stricmp(test_string, "plate") ) |
222 | 712 { |
374 | 713 pItems[item_counter].uSkillType = PLAYER_SKILL_PLATE; |
222 | 714 break; |
715 } | |
1104 | 716 if ( !_stricmp(test_string, "club") ) |
222 | 717 { |
374 | 718 pItems[item_counter].uSkillType = PLAYER_SKILL_CLUB; |
222 | 719 break; |
720 } | |
385 | 721 pItems[item_counter].uSkillType = PLAYER_SKILL_MISC; |
222 | 722 break; |
723 } | |
724 case 6: //Mod1 | |
725 { | |
726 int ii; | |
727 char* test_char; | |
728 int tst_len; | |
729 tst_len=strlen(test_string); | |
730 pItems[item_counter].uDamageDice=0; | |
731 pItems[item_counter].uDamageRoll=0; | |
732 test_char=test_string; | |
733 for (ii=0; ii<tst_len; ++ii) | |
734 { | |
735 if (tolower(*test_char)=='d') | |
736 { | |
737 *test_char=0; | |
738 pItems[item_counter].uDamageDice=atoi(test_string); | |
739 pItems[item_counter].uDamageRoll=atoi(test_char+1); | |
740 *test_char='d'; | |
741 break; | |
742 } | |
743 ++test_char; | |
744 } | |
745 test_char=test_string; | |
559 | 746 if ((ii==tst_len)&&(tolower(*test_char)!='s')) |
222 | 747 { |
559 | 748 pItems[item_counter].uDamageDice=atoi(test_char); |
222 | 749 pItems[item_counter].uDamageRoll=1; |
750 } | |
751 break; | |
752 } | |
753 case 7: //Mod2 | |
754 pItems[item_counter].uDamageMod=atoi(test_string); | |
755 break; | |
756 case 8: //material | |
757 { | |
1104 | 758 if ( !_stricmp(test_string, "artifact") ) |
222 | 759 { |
377 | 760 pItems[item_counter].uMaterial = MATERIAL_ARTEFACT; |
222 | 761 break; |
762 } | |
1104 | 763 if ( !_stricmp(test_string, "relic") ) |
222 | 764 { |
377 | 765 pItems[item_counter].uMaterial = MATERIAL_RELIC; |
222 | 766 break; |
767 } | |
1104 | 768 if ( !_stricmp(test_string, "special") ) |
222 | 769 { |
377 | 770 pItems[item_counter].uMaterial = MATERIAL_SPECIAL; |
222 | 771 break; |
772 } | |
377 | 773 pItems[item_counter].uMaterial = MATERIAL_COMMON; |
222 | 774 break;} |
775 case 9: //ID/Rep/St | |
776 pItems[item_counter].uItemID_Rep_St=atoi(test_string); | |
777 break; | |
778 case 10: //Not identified name | |
779 pItems[item_counter].pUnidentifiedName = RemoveQuotes(test_string); | |
780 break; | |
781 case 11: //Sprite Index | |
782 pItems[item_counter].uSpriteID=atoi(test_string); | |
783 break; | |
784 case 12: //VarA | |
224 | 785 { |
222 | 786 pItems[item_counter]._additional_value=0; |
787 pItems[item_counter]._bonus_type=0; | |
377 | 788 if (pItems[item_counter].uMaterial==MATERIAL_SPECIAL) |
222 | 789 { |
224 | 790 for(int ii=0; ii<24; ++ii) |
791 { | |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
792 if (!_stricmp(test_string,pEnchantments[ii].pOfName)) |
224 | 793 { |
794 pItems[item_counter]._bonus_type=ii+1; | |
222 | 795 break; |
224 | 796 } |
797 } | |
798 if (!pItems[item_counter]._bonus_type) | |
799 { | |
800 for(int ii=0; ii<72; ++ii) | |
801 { | |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
802 if (!_stricmp(test_string,pSpecialEnchantments[ii].pNameAdd)) |
222 | 803 { |
224 | 804 pItems[item_counter]._additional_value=ii+1; |
222 | 805 } |
224 | 806 } |
807 } | |
222 | 808 } |
224 | 809 |
222 | 810 break; |
224 | 811 } |
222 | 812 case 13: //VarB |
377 | 813 if ((pItems[item_counter].uMaterial==MATERIAL_SPECIAL)&&(pItems[item_counter]._bonus_type)) |
222 | 814 { |
815 char b_s=atoi(test_string); | |
816 if (b_s) | |
817 pItems[item_counter]._bonus_strength=b_s; | |
818 else | |
819 pItems[item_counter]._bonus_strength=1; | |
820 } | |
821 else | |
822 pItems[item_counter]._bonus_strength=0; | |
823 break; | |
824 case 14: //Equip X | |
825 pItems[item_counter].uEquipX=atoi(test_string); | |
826 break; | |
827 case 15: //Equip Y | |
828 pItems[item_counter].uEquipY=atoi(test_string); | |
829 break; | |
830 case 16: //Notes | |
831 pItems[item_counter].pDescription = RemoveQuotes(test_string); | |
832 break; | |
224 | 833 |
222 | 834 } |
835 } | |
836 else | |
837 { | |
570 | 838 if (decode_step) |
222 | 839 break_loop = true; |
840 } | |
841 ++decode_step; | |
842 test_string=tmp_pos+1; | |
843 } while ((decode_step<17)&&!break_loop); | |
844 ++item_counter; | |
845 if (item_counter>799) | |
846 break; | |
847 } | |
848 | |
224 | 849 |
850 pRndItemsTXT_Raw = NULL; | |
851 uAllItemsCount = item_counter; | |
852 pRndItemsTXT_Raw = (char *)pEvents_LOD->LoadRaw("rnditems.txt", 0); | |
853 strtok(pRndItemsTXT_Raw, "\r"); | |
854 strtok(NULL, "\r"); | |
855 strtok(NULL, "\r"); | |
856 strtok(NULL, "\r"); | |
857 item_counter = 0; | |
858 while (true) | |
859 { | |
860 test_string = strtok(NULL, "\r") + 1; | |
861 break_loop = false; | |
862 decode_step=0; | |
863 do | |
864 { | |
865 c = *(unsigned char*)test_string; | |
866 temp_str_len = 0; | |
867 while((c!='\t')&&(c>0)) | |
868 { | |
869 ++temp_str_len; | |
870 c=test_string[temp_str_len]; | |
871 } | |
872 tmp_pos=test_string+temp_str_len; | |
873 if (*tmp_pos == 0) | |
874 break_loop = true; | |
875 *tmp_pos = 0; | |
876 if (temp_str_len) | |
877 { | |
878 switch (decode_step) | |
879 { | |
880 case 0: | |
881 item_counter=atoi(test_string); | |
882 break; | |
883 case 2: | |
884 pItems[item_counter].uChanceByTreasureLvl1=atoi(test_string); | |
885 break; | |
886 case 3: | |
887 pItems[item_counter].uChanceByTreasureLvl2=atoi(test_string); | |
888 break; | |
889 case 4: | |
890 pItems[item_counter].uChanceByTreasureLvl3=atoi(test_string); | |
891 break; | |
892 case 5: | |
893 pItems[item_counter].uChanceByTreasureLvl4=atoi(test_string); | |
894 break; | |
895 case 6: | |
896 pItems[item_counter].uChanceByTreasureLvl5=atoi(test_string); | |
897 break; | |
898 case 7: | |
899 pItems[item_counter].uChanceByTreasureLvl6=atoi(test_string); | |
900 break; | |
901 } | |
902 } | |
903 else | |
904 { | |
570 | 905 if (decode_step) |
224 | 906 break_loop = true; |
907 } | |
908 ++decode_step; | |
909 test_string=tmp_pos+1; | |
910 } while ((decode_step<8)&&!break_loop); | |
911 ++item_counter; | |
912 if (item_counter>618) | |
913 break; | |
914 } | |
915 | |
1006 | 916 //ChanceByTreasureLvl Summ - to calculate chance |
224 | 917 memset(&uChanceByTreasureLvlSumm, 0, 24); |
918 for(i=0;i<6;++i) | |
919 { | |
598 | 920 for (j=1;j<item_counter;++j) |
224 | 921 uChanceByTreasureLvlSumm[i]+=pItems[j].uChanceByTreasureLvl[i]; |
922 } | |
222 | 923 |
224 | 924 strtok(NULL, "\r"); |
925 strtok(NULL, "\r"); | |
926 strtok(NULL, "\r"); | |
927 strtok(NULL, "\r"); | |
928 strtok(NULL, "\r"); | |
929 for (i=0;i<3;++i) | |
930 { | |
931 test_string = strtok(NULL, "\r") + 1; | |
932 break_loop = false; | |
933 decode_step=0; | |
934 do | |
935 { | |
936 c = *(unsigned char*)test_string; | |
937 temp_str_len = 0; | |
938 while((c!='\t')&&(c>0)) | |
939 { | |
940 ++temp_str_len; | |
941 c=test_string[temp_str_len]; | |
942 } | |
943 tmp_pos=test_string+temp_str_len; | |
944 if (*tmp_pos == 0) | |
945 break_loop = true; | |
946 *tmp_pos = 0; | |
947 if (temp_str_len) | |
948 { | |
949 switch (decode_step) | |
950 { | |
951 case 2: | |
952 switch (i) | |
953 { | |
954 case 0: | |
955 uBonusChanceStandart[0]=atoi(test_string); | |
956 break; | |
957 case 1: | |
958 uBonusChanceSpecial[0]=atoi(test_string); | |
959 break; | |
960 case 2: | |
961 uBonusChanceWpSpecial[0]=atoi(test_string); | |
962 break; | |
963 } | |
964 break; | |
965 case 3: | |
966 switch (i) | |
967 { | |
968 case 0: | |
969 uBonusChanceStandart[1]=atoi(test_string); | |
970 break; | |
971 case 1: | |
972 uBonusChanceSpecial[1]=atoi(test_string); | |
973 break; | |
974 case 2: | |
975 uBonusChanceWpSpecial[1]=atoi(test_string); | |
976 break; | |
977 } | |
978 break; | |
979 case 4: | |
980 switch (i) | |
981 { | |
982 case 0: | |
983 uBonusChanceStandart[2]=atoi(test_string); | |
984 break; | |
985 case 1: | |
986 uBonusChanceSpecial[2]=atoi(test_string); | |
987 break; | |
988 case 2: | |
989 uBonusChanceWpSpecial[2]=atoi(test_string); | |
990 break; | |
991 } | |
992 break; | |
993 case 5: | |
994 switch (i) | |
995 { | |
996 case 0: | |
997 uBonusChanceStandart[3]=atoi(test_string); | |
998 break; | |
999 case 1: | |
1000 uBonusChanceSpecial[3]=atoi(test_string); | |
1001 break; | |
1002 case 2: | |
1003 uBonusChanceWpSpecial[3]=atoi(test_string); | |
1004 break; | |
1005 } | |
1006 break; | |
1007 case 6: | |
1008 switch (i) | |
1009 { | |
1010 case 0: | |
1011 uBonusChanceStandart[4]=atoi(test_string); | |
1012 break; | |
1013 case 1: | |
1014 uBonusChanceSpecial[4]=atoi(test_string); | |
1015 break; | |
1016 case 2: | |
1017 uBonusChanceWpSpecial[4]=atoi(test_string); | |
1018 break; | |
1019 } | |
1020 break; | |
1021 case 7: | |
1022 switch (i) | |
1023 { | |
1024 case 0: | |
1025 uBonusChanceStandart[5]=atoi(test_string); | |
1026 break; | |
1027 case 1: | |
1028 uBonusChanceSpecial[5]=atoi(test_string); | |
1029 break; | |
1030 case 2: | |
1031 uBonusChanceWpSpecial[5]=atoi(test_string); | |
1032 break; | |
1033 } | |
1034 break; | |
1035 } | |
1036 } | |
1037 else | |
1038 { | |
570 | 1039 if (decode_step) |
224 | 1040 break_loop = true; |
1041 } | |
1042 ++decode_step; | |
1043 test_string=tmp_pos+1; | |
1044 } while ((decode_step<8)&&!break_loop); | |
1045 } | |
222 | 1046 |
705 | 1047 if ( pRndItemsTXT_Raw ) |
1048 { | |
1583 | 1049 free(pRndItemsTXT_Raw); |
705 | 1050 pRndItemsTXT_Raw = NULL; |
1051 } | |
1052 | |
224 | 1053 pSkillDescTXT_Raw = NULL; |
1054 pSkillDescTXT_Raw = (char *)pEvents_LOD->LoadRaw("skilldes.txt", 0); | |
1055 strtok(pSkillDescTXT_Raw, "\r"); | |
1056 for (i=0; i<37; ++i) | |
1057 { | |
1058 test_string = strtok(NULL, "\r") + 1; | |
1059 break_loop = false; | |
1060 decode_step=0; | |
1061 do | |
1062 { | |
1063 c = *(unsigned char*)test_string; | |
1064 temp_str_len = 0; | |
1065 while((c!='\t')&&(c>0)) | |
1066 { | |
1067 ++temp_str_len; | |
1068 c=test_string[temp_str_len]; | |
1069 } | |
1070 tmp_pos=test_string+temp_str_len; | |
1071 if (*tmp_pos == 0) | |
1072 break_loop = true; | |
1073 *tmp_pos = 0; | |
1074 if (temp_str_len) | |
1075 { | |
1076 switch (decode_step) | |
1077 { | |
1078 case 1: | |
1079 pSkillDesc[i] = RemoveQuotes(test_string); | |
1080 break; | |
1081 case 2: | |
1082 pNormalSkillDesc[i] = RemoveQuotes(test_string); | |
1083 break; | |
1084 case 3: | |
1085 pExpertSkillDesc[i] = RemoveQuotes(test_string); | |
1086 break; | |
1087 case 4: | |
1088 pMasterSkillDesc[i] = RemoveQuotes(test_string); | |
1089 break; | |
1090 case 5: | |
1091 pGrandSkillDesc[i] = RemoveQuotes(test_string); | |
1092 break; | |
1093 } | |
1094 } | |
1095 else | |
1096 { | |
570 | 1097 if (decode_step) |
224 | 1098 break_loop = true; |
1099 } | |
1100 ++decode_step; | |
1101 test_string=tmp_pos+1; | |
1102 } while ((decode_step<6)&&!break_loop); | |
1103 } | |
1104 | |
1105 pStatsTXT_Raw = 0; | |
1106 pStatsTXT_Raw = (char *)pEvents_LOD->LoadRaw("stats.txt", 0); | |
1107 strtok(pStatsTXT_Raw, "\r"); | |
1108 for (i=0; i<26; ++i) | |
1109 { | |
1110 test_string = strtok(NULL, "\r") + 1; | |
1111 break_loop = false; | |
1112 decode_step=0; | |
1113 do | |
1114 { | |
1115 c = *(unsigned char*)test_string; | |
1116 temp_str_len = 0; | |
1117 while((c!='\t')&&(c>0)) | |
1118 { | |
1119 ++temp_str_len; | |
1120 c=test_string[temp_str_len]; | |
1121 } | |
1122 tmp_pos=test_string+temp_str_len; | |
1123 if (*tmp_pos == 0) | |
1124 break_loop = true; | |
1125 *tmp_pos = 0; | |
1126 if (temp_str_len) | |
1127 { | |
1128 switch (i) | |
1129 { | |
1130 case 0: | |
1131 case 1: | |
1132 case 2: | |
1133 case 3: | |
1134 case 4: | |
1135 case 5: | |
1136 case 6: | |
1137 pAttributeDescriptions[i] = RemoveQuotes(test_string); | |
1138 break; | |
1139 case 7: | |
1140 pHealthPointsAttributeDescription = RemoveQuotes(test_string); | |
1141 break; | |
1142 case 8: | |
1143 pArmourClassAttributeDescription = RemoveQuotes(test_string); | |
1144 break; | |
1145 case 9: | |
1146 pSpellPointsAttributeDescription = RemoveQuotes(test_string); | |
1147 break; | |
1148 case 10: | |
1149 pPlayerConditionAttributeDescription = RemoveQuotes(test_string); | |
1150 break; | |
1151 case 11: | |
1152 pFastSpellAttributeDescription = RemoveQuotes(test_string); | |
1153 break; | |
1154 case 12: | |
1155 pPlayerAgeAttributeDescription = RemoveQuotes(test_string); | |
1156 break; | |
1157 case 13: | |
1158 pPlayerLevelAttributeDescription = RemoveQuotes(test_string); | |
1159 break; | |
1160 case 14: | |
1161 pPlayerExperienceAttributeDescription = RemoveQuotes(test_string); | |
1162 break; | |
1163 case 15: | |
1164 pAttackBonusAttributeDescription = RemoveQuotes(test_string); | |
1165 break; | |
1166 case 16: | |
1167 pAttackDamageAttributeDescription = RemoveQuotes(test_string); | |
1168 break; | |
1169 case 17: | |
1170 pMissleBonusAttributeDescription = RemoveQuotes(test_string); | |
1171 break; | |
1172 case 18: | |
1173 pMissleDamageAttributeDescription = RemoveQuotes(test_string); | |
1174 break; | |
1175 case 19: | |
1176 pFireResistanceAttributeDescription = RemoveQuotes(test_string); | |
1177 break; | |
1178 case 20: | |
1179 pAirResistanceAttributeDescription = RemoveQuotes(test_string); | |
1180 break; | |
1181 case 21: | |
1182 pWaterResistanceAttributeDescription = RemoveQuotes(test_string); | |
1183 break; | |
1184 case 22: | |
1185 pEarthResistanceAttributeDescription = RemoveQuotes(test_string); | |
1186 break; | |
1187 case 23: | |
1188 pMindResistanceAttributeDescription = RemoveQuotes(test_string); | |
1189 break; | |
1190 case 24: | |
1191 pBodyResistanceAttributeDescription = RemoveQuotes(test_string); | |
1192 break; | |
1193 case 25: | |
1194 pSkillPointsAttributeDescription = RemoveQuotes(test_string); | |
1195 break; | |
1196 } | |
1197 } | |
1198 else | |
1199 { | |
570 | 1200 if (decode_step) |
224 | 1201 break_loop = true; |
1202 } | |
1203 ++decode_step; | |
1204 test_string=tmp_pos+1; | |
1205 } while ((decode_step<2)&&!break_loop); | |
1206 } | |
222 | 1207 |
1208 | |
224 | 1209 pClassTXT_Raw = 0; |
1210 pClassTXT_Raw = (char *)pEvents_LOD->LoadRaw("class.txt", 0); | |
1211 strtok(pClassTXT_Raw, "\r"); | |
1212 for (i=0; i<36; ++i) | |
1213 { | |
1214 test_string = strtok(NULL, "\r") + 1; | |
1215 break_loop = false; | |
1216 decode_step=0; | |
1217 do | |
1218 { | |
1219 c = *(unsigned char*)test_string; | |
1220 temp_str_len = 0; | |
1221 while((c!='\t')&&(c>0)) | |
1222 { | |
1223 ++temp_str_len; | |
1224 c=test_string[temp_str_len]; | |
1225 } | |
1226 tmp_pos=test_string+temp_str_len; | |
1227 if (*tmp_pos == 0) | |
1228 break_loop = true; | |
1229 *tmp_pos = 0; | |
1230 if (temp_str_len) | |
1231 { | |
229 | 1232 //if(i) |
224 | 1233 pClassDescriptions[i]=RemoveQuotes(test_string); |
1234 } | |
1235 else | |
1236 { | |
570 | 1237 if (decode_step) |
224 | 1238 break_loop = true; |
1239 } | |
1240 ++decode_step; | |
1241 test_string=tmp_pos+1; | |
1242 } while ((decode_step<2)&&!break_loop); | |
1243 } | |
222 | 1244 |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1245 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1246 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1247 ItemGen::PopulateSpecialBonusMap(); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1248 ItemGen::PopulateArtifactBonusMap(); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1249 ItemGen::PopulateRegularBonusMap(); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1250 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1251 |
224 | 1252 } |
0 | 1253 |
1254 //----- (00456D17) -------------------------------------------------------- | |
1255 void ItemsTable::SetSpecialBonus(ItemGen *pItem) | |
1256 { | |
385 | 1257 if ( pItems[pItem->uItemID].uMaterial == MATERIAL_SPECIAL ) |
0 | 1258 { |
570 | 1259 pItem->uEnchantmentType = pItems[pItem->uItemID]._bonus_type; |
385 | 1260 pItem->uSpecEnchantmentType = pItems[pItem->uItemID]._additional_value; |
1599 | 1261 pItem->m_enchantmentStrength = pItems[pItem->uItemID]._bonus_strength; |
0 | 1262 } |
1263 } | |
1264 | |
1265 //----- (00456D43) -------------------------------------------------------- | |
377 | 1266 bool ItemsTable::IsMaterialSpecial(ItemGen *pItem) |
0 | 1267 { |
377 | 1268 return this->pItems[pItem->uItemID].uMaterial == MATERIAL_SPECIAL; |
0 | 1269 } |
1270 | |
1271 //----- (00456D5E) -------------------------------------------------------- | |
377 | 1272 bool ItemsTable::IsMaterialNonCommon(ItemGen *pItem) |
0 | 1273 { |
385 | 1274 return pItems[pItem->uItemID].uMaterial == MATERIAL_SPECIAL || |
1275 pItems[pItem->uItemID].uMaterial == MATERIAL_RELIC || | |
1276 pItems[pItem->uItemID].uMaterial == MATERIAL_ARTEFACT; | |
0 | 1277 } |
1278 | |
1279 | |
1280 //----- (00453B3C) -------------------------------------------------------- | |
1281 void ItemsTable::LoadPotions() | |
222 | 1282 { |
0 | 1283 |
222 | 1284 CHAR Text[90]; // [sp+Ch] [bp-6Ch]@26 |
1285 char* test_string; | |
1286 unsigned int uRow; | |
1287 unsigned int uColumn; | |
1288 unsigned __int8 potion_value; | |
1289 | |
1290 if ( pPotionsTXT_Raw ) | |
1583 | 1291 free(pPotionsTXT_Raw); |
222 | 1292 pPotionsTXT_Raw = NULL; |
1293 pPotionsTXT_Raw = (char *)pEvents_LOD->LoadRaw("potion.txt", 0); | |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1294 test_string = strtok(pPotionsTXT_Raw,"\t\r\n"); |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1295 while ( 1 ) |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1296 { |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1297 if ( !test_string ) |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1298 { |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1299 MessageBoxA(0, "Error Pre-Parsing Potion Table", "Load Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1300 return; |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1301 } |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1302 if ( !strcmp(test_string, "222") ) |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1303 break; |
222 | 1304 |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1305 test_string = strtok(NULL, "\t\r\n"); |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1306 } |
222 | 1307 while ( 1 ) |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1308 { |
222 | 1309 test_string = strtok(NULL, "\t\r\n"); |
1310 | |
1311 if ( !test_string ) | |
1312 { | |
1313 MessageBoxA(0, "Error Pre-Parsing Potion Table", "Load Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); | |
1314 return; | |
1315 } | |
1316 if ( !strcmp(test_string, "222") ) | |
1317 break; | |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1318 } |
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1319 |
222 | 1320 for (uRow = 0;uRow < 50; ++uRow) |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1321 { |
222 | 1322 int skip_count; |
1323 for (skip_count = 0;skip_count < 6; ++skip_count) | |
1324 { | |
1325 if ( !strtok(NULL, "\r\t\n") ) | |
1326 break; | |
1327 } | |
1328 if ( skip_count != 6 ) | |
1329 break; | |
1330 for (uColumn = 0; uColumn < 50; ++uColumn) | |
1331 { | |
1332 test_string = strtok(NULL, "\r\t\n"); | |
1333 if ( !test_string ) | |
1334 break; | |
1335 potion_value = atoi(test_string); | |
233 | 1336 unsigned char c=*test_string; |
222 | 1337 if ( !potion_value ) |
1338 { | |
1339 if ( tolower(c) == 'e' ) | |
1340 potion_value = atoi(test_string + 1); | |
1341 else | |
1342 potion_value = 0; | |
1343 } | |
1344 this->potion_data[uRow][uColumn]=potion_value; | |
1345 } | |
1346 if ( uColumn != 50 ) | |
1347 break; | |
1348 strtok(NULL, "\r\t\n"); | |
1349 } | |
193
821fd955c379
fixed potion data parsing. Somehow 3d render was affected
Gloval
parents:
189
diff
changeset
|
1350 |
222 | 1351 if ( uRow != 50 ) |
1352 { | |
1353 wsprintfA(Text, "Error Parsing Potion Table at Row: %d Column: %d", uRow, uColumn); | |
1354 MessageBoxA(0, Text, "Parsing Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); | |
1355 } | |
1356 if ( pPotionsTXT_Raw ) | |
1357 { | |
1583 | 1358 free(pPotionsTXT_Raw); |
222 | 1359 pPotionsTXT_Raw = 0; |
1360 } | |
1361 } | |
0 | 1362 |
1363 //----- (00453CE5) -------------------------------------------------------- | |
1364 void ItemsTable::LoadPotionNotes() | |
222 | 1365 { |
1366 | |
1367 CHAR Text[90]; | |
1368 char* test_string; | |
1369 unsigned int uRow; | |
1370 unsigned int uColumn; | |
1371 unsigned __int8 potion_note; | |
1372 | |
1373 if ( pPotionNotesTXT_Raw ) | |
1583 | 1374 free(pPotionNotesTXT_Raw); |
222 | 1375 pPotionNotesTXT_Raw = NULL; |
1376 pPotionNotesTXT_Raw = (char *)pEvents_LOD->LoadRaw("potnotes.txt", 0); | |
1377 test_string = strtok(pPotionNotesTXT_Raw ,"\t\r\n"); | |
1378 while ( 1 ) | |
1379 { | |
1380 if ( !test_string ) | |
1381 { | |
1382 MessageBoxA(0, "Error Pre-Parsing Potion Table", "Load Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); | |
1383 return; | |
1384 } | |
1385 if ( !strcmp(test_string, "222") ) | |
1386 break; | |
1387 test_string = strtok(NULL, "\t\r\n"); | |
1388 } | |
1389 while ( 1 ) | |
1390 { | |
1391 test_string = strtok(NULL, "\t\r\n"); | |
1392 | |
1393 if ( !test_string ) | |
1394 { | |
1395 MessageBoxA(0, "Error Pre-Parsing Potion Table", "Load Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); | |
1396 return; | |
1397 } | |
1398 if ( !strcmp(test_string, "222") ) | |
1399 break; | |
1400 } | |
0 | 1401 |
222 | 1402 for (uRow = 0;uRow < 50; ++uRow) |
1403 { | |
1404 int skip_count; | |
1405 for (skip_count = 0;skip_count < 6; ++skip_count) | |
1406 { | |
1407 if ( !strtok(NULL, "\r\t\n") ) | |
1408 break; | |
1409 } | |
1410 if ( skip_count != 6 ) | |
1411 break; | |
1412 for (uColumn = 0; uColumn < 50; ++uColumn) | |
1413 { | |
1414 test_string = strtok(NULL, "\r\t\n"); | |
1415 if ( !test_string ) | |
1416 break; | |
1417 potion_note = atoi(test_string); | |
233 | 1418 unsigned char c=*test_string; |
222 | 1419 if ( !potion_note ) |
1420 { | |
1421 if ( tolower(c) == 'e' ) | |
1422 potion_note = atoi(test_string + 1); | |
1423 else | |
1424 potion_note = 0; | |
1425 } | |
1426 this->potion_note[uRow][uColumn]=potion_note; | |
1427 } | |
1428 if ( uColumn != 50 ) | |
1429 break; | |
1430 strtok(NULL, "\r\t\n"); | |
1431 } | |
1432 if ( uRow != 50 ) | |
1433 { | |
1434 wsprintfA(Text, "Error Parsing Potion Table at Row: %d Column: %d", uRow, uColumn); | |
1435 MessageBoxA(0, Text, "Parsing Error", MB_ICONHAND|MB_CANCELTRYCONTINUE); | |
1436 } | |
1437 } | |
0 | 1438 |
1439 | |
1440 //----- (00456442) -------------------------------------------------------- | |
1441 unsigned int ItemGen::GetValue() | |
463 | 1442 { |
1443 unsigned int uBaseValue; // edi@1 | |
1444 unsigned int bonus; | |
0 | 1445 |
463 | 1446 uBaseValue = pItemsTable->pItems[this->uItemID].uValue; |
1447 if ( this->uAttributes & ITEM_TEMP_BONUS || pItemsTable->IsMaterialNonCommon(this) ) | |
1448 return uBaseValue; | |
570 | 1449 if (uEnchantmentType ) |
1599 | 1450 return uBaseValue + 100 * m_enchantmentStrength;; |
463 | 1451 if (uSpecEnchantmentType ) |
1452 { | |
1453 bonus = pItemsTable->pSpecialEnchantments[uSpecEnchantmentType].iTreasureLevel; | |
1454 if ( bonus > 10 ) | |
1455 return uBaseValue + bonus; | |
1456 else | |
1457 return uBaseValue * bonus; | |
1458 } | |
1459 return uBaseValue; | |
1460 } | |
0 | 1461 |
1462 //----- (00456499) -------------------------------------------------------- | |
1463 const char *ItemGen::GetDisplayName() | |
1464 { | |
1567
9f8b3e904e14
Player::ReceiveDamage, very small edits; prepended "Is" to item functions returning bool values (broken, indetified, stolen)
Grumpy7
parents:
1545
diff
changeset
|
1465 if (IsIdentified()) |
366 | 1466 return GetIdentifiedName(); |
0 | 1467 else |
366 | 1468 return pItemsTable->pItems[uItemID].pUnidentifiedName; |
0 | 1469 } |
1470 | |
1471 //----- (004564B3) -------------------------------------------------------- | |
1472 const char *ItemGen::GetIdentifiedName() | |
1473 { | |
377 | 1474 unsigned __int8 equip_type; |
1475 const char *player_name; | |
1476 const char *nameModificator; | |
1477 const char *format_str; | |
0 | 1478 |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1479 equip_type = GetItemEquipType(); |
377 | 1480 if ( (equip_type == EQUIP_REAGENT) || (equip_type == EQUIP_POTION) || (equip_type == EQUIP_GOLD) ) |
0 | 1481 { |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1482 sprintf(item__getname_buffer.data(), "%s", pItemsTable->pItems[uItemID].pName); |
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1483 return item__getname_buffer.data(); |
0 | 1484 } |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1485 sprintf(item__getname_buffer.data(), "%s", pItemsTable->pItems[uItemID].pName); |
1358
61010a655c94
a few itemID changed to their enum values + added a few new ones
Grumpy7
parents:
1297
diff
changeset
|
1486 if ( uItemID == ITEM_LICH_JAR_FULL ) //Lich Jar |
0 | 1487 { |
377 | 1488 if ( (uHolderPlayer >0 )&& (uHolderPlayer <= 4) ) |
0 | 1489 { |
377 | 1490 player_name = pPlayers[uHolderPlayer]->pName; |
1491 if ( player_name[strlen(player_name) - 1] == 's' ) | |
1492 format_str = pGlobalTXT_LocalizationStrings[655]; //"%s' Jar" | |
0 | 1493 else |
377 | 1494 format_str = pGlobalTXT_LocalizationStrings[654]; //"%s's Jar" |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1495 sprintf(item__getname_buffer.data(), format_str, pPlayers[uHolderPlayer]->pName); |
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1496 return item__getname_buffer.data(); |
0 | 1497 } |
1498 } | |
377 | 1499 if ( !pItemsTable->IsMaterialNonCommon(this) ) |
0 | 1500 { |
570 | 1501 if ( uEnchantmentType ) |
0 | 1502 { |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1503 strcat(item__getname_buffer.data(), " "); |
570 | 1504 nameModificator = pItemsTable->pEnchantments[uEnchantmentType-1].pOfName; |
0 | 1505 } |
1506 else | |
1507 { | |
377 | 1508 if ( !uSpecEnchantmentType ) |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1509 return item__getname_buffer.data(); |
377 | 1510 if ( uSpecEnchantmentType == 16 //Drain Hit Points from target. |
1511 || uSpecEnchantmentType == 39 //Double damage vs Demons. | |
1512 || uSpecEnchantmentType == 40 //Double damage vs Dragons | |
1513 || uSpecEnchantmentType == 45 //+5 Speed and Accuracy | |
1514 || uSpecEnchantmentType == 56 //+5 Might and Endurance. | |
1515 || uSpecEnchantmentType == 57 //+5 Intellect and Personality. | |
1516 || uSpecEnchantmentType == 58 //Increased Value. | |
1517 || uSpecEnchantmentType == 60 //+3 Unarmed and Dodging skills | |
1518 || uSpecEnchantmentType == 61 //+3 Stealing and Disarm skills. | |
1519 || uSpecEnchantmentType == 59 //Increased Weapon speed. | |
1520 || uSpecEnchantmentType == 63 //Double Damage vs. Elves. | |
1521 || uSpecEnchantmentType == 64 //Double Damage vs. Undead. | |
1522 || uSpecEnchantmentType == 67 //Adds 5 points of Body damage and +2 Disarm skill. | |
1523 || uSpecEnchantmentType == 68 ) //Adds 6-8 points of Cold damage and +5 Armor Class. | |
1524 { //enchantment and name positions inverted! | |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1525 sprintf( item__getname_buffer.data(), "%s %s", |
377 | 1526 pItemsTable->pSpecialEnchantments[uSpecEnchantmentType-1].pNameAdd, |
1527 pItemsTable->pItems[uItemID].pName); | |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1528 return item__getname_buffer.data(); |
0 | 1529 } |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1530 strcat(item__getname_buffer.data(), " "); |
377 | 1531 nameModificator = pItemsTable->pSpecialEnchantments[uSpecEnchantmentType-1].pNameAdd; |
0 | 1532 } |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1533 strcat(item__getname_buffer.data(), nameModificator); |
0 | 1534 } |
1205
8c02e6f74b29
arrays to std::arrays phase 2 - mm7_data.h converted
Grumpy7
parents:
1202
diff
changeset
|
1535 return item__getname_buffer.data(); |
0 | 1536 } |
1537 | |
1538 | |
1539 //----- (00456620) -------------------------------------------------------- | |
385 | 1540 void ItemsTable::GenerateItem(int treasure_level, unsigned int uTreasureType, ItemGen *out_item) |
559 | 1541 { |
0 | 1542 |
559 | 1543 ItemsTable *v5; // edi@1 |
1544 int v6; // ebx@3 | |
1545 int *v7; // ecx@33 | |
1546 //int v8; // eax@34 | |
1547 //int v9; // eax@39 | |
1548 int current_chance; // ebx@43 | |
1549 int tmp_chance; // ecx@47 | |
1550 unsigned int *v12; // edx@48 | |
1551 unsigned int v13; // eax@49 | |
1552 signed int v14; // ebx@52 | |
1553 int v15; // eax@53 | |
1554 signed int v16; // eax@55 | |
1555 int v17; // ebx@57 | |
1556 int v18; // edx@62 | |
1557 signed int v19; // ebx@70 | |
1558 unsigned __int8 v20; // al@81 | |
1559 int v21; // eax@84 | |
1560 int v22; // ebx@85 | |
1561 int v23; // eax@86 | |
1562 int v24; // ebx@86 | |
1563 int special_chance; // edx@86 | |
1564 int v26; // edx@89 | |
1565 unsigned int v27; // eax@89 | |
1566 int i; // ebx@89 | |
1567 unsigned int v29; // ecx@90 | |
1568 int v30; // ebx@91 | |
1569 int v31; // eax@91 | |
1570 int v32; // ecx@91 | |
1571 int v33; // eax@91 | |
1572 int v34; // eax@97 | |
1573 unsigned __int8 v35; // sf@97 | |
1574 unsigned __int8 v36; // of@97 | |
1575 int v37; // ebx@98 | |
1576 int v38; // edx@99 | |
1577 signed int v39; // ebx@101 | |
1578 int v40; // ecx@102 | |
1579 char v41; // zf@107 | |
1580 char v42; // al@108 | |
1581 char v43; // al@111 | |
1582 int *v44; // edx@118 | |
1583 int v45; // eax@120 | |
1584 int v46; // edx@120 | |
1585 int j; // eax@121 | |
1586 unsigned int v48; // ecx@123 | |
1587 int v49; // eax@123 | |
1588 int v50; // eax@123 | |
1589 int val_list[800]; // [sp+Ch] [bp-C88h]@33 | |
1590 int total_chance; // [sp+C8Ch] [bp-8h]@33 | |
1591 int v53; // [sp+C90h] [bp-4h]@1 | |
1592 int v54; // [sp+C9Ch] [bp+8h]@3 | |
1593 //int v55; // [sp+CA0h] [bp+Ch]@34 | |
1594 signed int v56; // [sp+CA0h] [bp+Ch]@55 | |
1595 int v57; // [sp+CA0h] [bp+Ch]@62 | |
1596 int *v58; // [sp+CA0h] [bp+Ch]@102 | |
1597 int v59; // [sp+CA0h] [bp+Ch]@123 | |
1598 //signed int a2a; // [sp+CA4h] [bp+10h]@33 | |
1599 int a2b; // [sp+CA4h] [bp+10h]@101 | |
1600 int a2c; // [sp+CA4h] [bp+10h]@120 | |
1601 | |
1602 v5 = this; | |
1603 if (!out_item) | |
1583 | 1604 out_item = (ItemGen *)malloc(sizeof(ItemGen)); |
559 | 1605 memset(out_item, 0, sizeof(*out_item)); |
1606 | |
228
46ae2602aceb
Item generation doesn't crash (thou still generates weird stuff)
Nomad
parents:
224
diff
changeset
|
1607 |
559 | 1608 v6 = treasure_level - 1; |
1609 v54 = treasure_level - 1; | |
1610 if ( uTreasureType ) //generate known treasure type | |
0 | 1611 { |
559 | 1612 ITEM_EQUIP_TYPE requested_equip; |
1613 PLAYER_SKILL_TYPE requested_skill = PLAYER_SKILL_INVALID; | |
1614 switch (uTreasureType) | |
1615 { | |
1989 | 1616 case 20: requested_equip = EQUIP_SINGLE_HANDED; break; |
559 | 1617 case 21: requested_equip = EQUIP_ARMOUR; break; |
1618 case 22: requested_skill = PLAYER_SKILL_MISC; break; | |
1619 case 23: requested_skill = PLAYER_SKILL_SWORD; break; | |
1620 case 24: requested_skill = PLAYER_SKILL_DAGGER; break; | |
1621 case 25: requested_skill = PLAYER_SKILL_AXE; break; | |
1622 case 26: requested_skill = PLAYER_SKILL_SPEAR; break; | |
1623 case 27: requested_skill = PLAYER_SKILL_BOW; break; | |
1624 case 28: requested_skill = PLAYER_SKILL_MACE; break; | |
1625 case 29: requested_skill = PLAYER_SKILL_CLUB; break; | |
1626 case 30: requested_skill = PLAYER_SKILL_STAFF; break; | |
1627 case 31: requested_skill = PLAYER_SKILL_LEATHER; break; | |
1628 case 32: requested_skill = PLAYER_SKILL_CHAIN; break; | |
1629 case 33: requested_skill = PLAYER_SKILL_PLATE; break; | |
1630 case 34: requested_equip = EQUIP_SHIELD; break; | |
1631 case 35: requested_equip = EQUIP_HELMET; break; | |
1632 case 36: requested_equip = EQUIP_BELT; break; | |
1633 case 37: requested_equip = EQUIP_CLOAK; break; | |
1634 case 38: requested_equip = EQUIP_GAUNTLETS; break; | |
1635 case 39: requested_equip = EQUIP_BOOTS; break; | |
1636 case 40: requested_equip = EQUIP_RING; break; | |
1637 case 41: requested_equip = EQUIP_AMULET; break; | |
1638 case 42: requested_equip = EQUIP_WAND; break; | |
1639 case 43: requested_equip = EQUIP_SPELL_SCROLL; break; | |
1640 case 44: requested_equip = EQUIP_POTION; break; | |
1641 case 45: requested_equip = EQUIP_REAGENT; break; | |
1642 case 46: requested_equip = EQUIP_GEM; break; | |
1643 default: | |
1644 __debugbreak(); // check this condition | |
1645 requested_equip = (ITEM_EQUIP_TYPE)(uTreasureType - 1); | |
1646 break; | |
1647 } | |
1648 memset(val_list, 0, sizeof(val_list)); | |
1649 total_chance = 0; | |
1650 j=0; | |
1651 //a2a = 1; | |
1652 if (requested_skill == PLAYER_SKILL_INVALID) // no skill for this item needed | |
1653 { | |
1654 for (uint i = 1; i < 500; ++i) | |
1655 { | |
1656 if (pItems[i].uEquipType == requested_equip) | |
1657 { | |
1658 val_list[j] = i; | |
1659 ++j; | |
1660 total_chance += pItems[i].uChanceByTreasureLvl[treasure_level - 1]; | |
1661 } | |
1662 } | |
1663 } | |
1664 else //have needed skill | |
1665 { | |
1666 for (uint i = 1; i < 500; ++i) | |
1667 { | |
1668 if (pItems[i].uSkillType == requested_skill) | |
1669 { | |
1670 val_list[j] = i; | |
1671 ++j; | |
1672 total_chance += pItems[i].uChanceByTreasureLvl[treasure_level - 1]; | |
1673 } | |
1674 } | |
1675 } | |
1676 | |
1677 current_chance = 0; | |
1678 if ( total_chance ) | |
1679 current_chance = rand() % total_chance; | |
1680 | |
1681 out_item->uItemID = val_list[0]; | |
1682 if (!out_item->uItemID) | |
1683 out_item->uItemID = 1; | |
1684 | |
1685 if ( pItems[out_item->uItemID].uChanceByTreasureLvl[treasure_level - 1] < current_chance ) | |
1686 { | |
1687 j=0; | |
1688 tmp_chance=pItems[out_item->uItemID].uChanceByTreasureLvl[treasure_level - 1]; | |
1689 do | |
1690 { | |
1691 ++j; | |
1692 out_item->uItemID = val_list[j]; | |
1693 tmp_chance += pItems[val_list[j]].uChanceByTreasureLvl[treasure_level - 1]; | |
1694 } | |
1695 while ( tmp_chance < current_chance ); | |
1696 } | |
1697 | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1698 if (out_item->GetItemEquipType() == EQUIP_POTION && out_item->uItemID != ITEM_POTION_BOTTLE ) |
559 | 1699 {// if it potion set potion spec |
570 | 1700 out_item->uEnchantmentType = 0; |
559 | 1701 for (int i=0; i<2; ++i) |
570 | 1702 out_item->uEnchantmentType += rand() % 4 + 1; |
1703 out_item->uEnchantmentType = out_item->uEnchantmentType * treasure_level; | |
559 | 1704 } |
0 | 1705 } |
559 | 1706 else |
0 | 1707 { |
559 | 1708 //artifact |
1709 v56 = 0; | |
1710 for(int i=0; i<29; ++i) | |
1711 v56 += pParty->pIsArtifactFound[i]; | |
228
46ae2602aceb
Item generation doesn't crash (thou still generates weird stuff)
Nomad
parents:
224
diff
changeset
|
1712 |
559 | 1713 v17 = rand() % 29; |
385 | 1714 |
559 | 1715 if ( v6 == 5 && (rand() % 100 < 5) && !pParty->pIsArtifactFound[v17] && v56 < 13 ) |
1716 { | |
1717 pParty->pIsArtifactFound[v17] = 1; | |
1718 out_item->uAttributes = 0; | |
1719 out_item->uItemID = v17 + 500; | |
1720 SetSpecialBonus(out_item); | |
1721 return; | |
1722 } | |
1723 | |
1724 v57 = 0; | |
1725 v18 = rand() % v5->uChanceByTreasureLvlSumm[treasure_level - 1]; | |
1726 out_item->uItemID = 0; | |
1727 if ( v18 > 0 ) | |
1728 { | |
1729 do | |
598 | 1730 { |
1731 v57 += pItems[out_item->uItemID + 1].uChanceByTreasureLvl[v6]; | |
1732 ++out_item->uItemID; | |
1733 } | |
559 | 1734 while ( v57 < v18 ); |
1735 } | |
1736 | |
1737 if ( !v18 ) | |
1738 out_item->uItemID = 1; | |
1739 if ( !out_item->uItemID ) | |
1740 out_item->uItemID = 1; | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1741 if (out_item->GetItemEquipType() == EQUIP_POTION && out_item->uItemID != ITEM_POTION_BOTTLE ) |
559 | 1742 {// if it potion set potion spec |
570 | 1743 out_item->uEnchantmentType = 0; |
559 | 1744 for (int i=0; i<2; ++i) |
570 | 1745 out_item->uEnchantmentType += rand() % 4 + 1; |
1746 out_item->uEnchantmentType = out_item->uEnchantmentType * treasure_level; | |
559 | 1747 } |
570 | 1748 out_item->uEnchantmentType = out_item->uEnchantmentType * treasure_level; |
559 | 1749 } |
1750 | |
1751 if ( out_item->uItemID == ITEM_SPELLBOOK_LIGHT_DIVINE_INTERVENTION | |
1752 && !(unsigned __int16)_449B57_test_bit(pParty->_quest_bits, 239) ) | |
1753 out_item->uItemID = ITEM_SPELLBOOK_LIGHT_SUN_BURST; | |
1754 if ( pItemsTable->pItems[out_item->uItemID + 1].uItemID_Rep_St ) | |
1755 out_item->uAttributes = 0; | |
1756 else | |
1757 out_item->uAttributes = 1; | |
385 | 1758 |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1759 if ( out_item->GetItemEquipType() != EQUIP_POTION ) |
559 | 1760 { |
1761 out_item->uSpecEnchantmentType = 0; | |
570 | 1762 out_item->uEnchantmentType = 0; |
559 | 1763 } |
1764 //try get special enhansment | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1765 switch (out_item->GetItemEquipType()) |
559 | 1766 { |
1989 | 1767 case EQUIP_SINGLE_HANDED: |
1768 case EQUIP_TWO_HANDED : | |
559 | 1769 case EQUIP_BOW : |
1770 if ( !uBonusChanceWpSpecial[v6] ) | |
1771 return; | |
1772 if ((rand() % 100)>=uBonusChanceWpSpecial[v6]) | |
1773 return; | |
1774 break; | |
1775 case EQUIP_ARMOUR : | |
1776 case EQUIP_SHIELD : | |
1777 case EQUIP_HELMET : | |
1778 case EQUIP_BELT : | |
1779 case EQUIP_CLOAK : | |
1780 case EQUIP_GAUNTLETS : | |
1781 case EQUIP_BOOTS : | |
1782 case EQUIP_RING : | |
570 | 1783 |
559 | 1784 if ( !uBonusChanceStandart[v6] ) |
1785 return; | |
1786 special_chance = rand() % 100; | |
1787 if ( special_chance < uBonusChanceStandart[v6]) | |
1788 { | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1789 v26 = rand() %pEnchantmentsSumm[out_item->GetItemEquipType()-3]; |
570 | 1790 out_item->uEnchantmentType = 0; |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1791 v27=pEnchantments[out_item->uEnchantmentType].to_item[out_item->GetItemEquipType()-3]; |
570 | 1792 if (v26>v27 ) |
1793 { | |
1794 do | |
559 | 1795 { |
570 | 1796 ++out_item->uEnchantmentType; |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1797 v27+=pEnchantments[out_item->uEnchantmentType].to_item[out_item->GetItemEquipType()-3]; |
570 | 1798 } while (v26>v27); |
1799 } | |
1800 ++out_item->uEnchantmentType; | |
1801 | |
1802 v33 = rand() % (bonus_ranges[v6].maxR - bonus_ranges[v6].minR + 1); | |
1599 | 1803 out_item->m_enchantmentStrength = v33 + bonus_ranges[v6].minR; |
570 | 1804 v32 = out_item->uEnchantmentType - 1; |
1805 if ( v32 == 21 || v32 == 22 || v32 == 23 ) //Armsmaster skill, Dodge skill, Unarmed skill | |
1599 | 1806 out_item->m_enchantmentStrength = out_item->m_enchantmentStrength/2; |
1807 if ( out_item->m_enchantmentStrength <= 0 ) | |
1808 out_item->m_enchantmentStrength = 1; | |
559 | 1809 return; |
1810 | |
1811 } | |
570 | 1812 if ( !uBonusChanceSpecial[v6]) |
1813 return; | |
559 | 1814 v34 = uBonusChanceStandart[v6] + uBonusChanceSpecial[v6]; |
570 | 1815 if ( special_chance>v34 ) |
559 | 1816 return; |
1817 break; | |
1818 case EQUIP_WAND: | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1819 out_item->uNumCharges = rand() % 6 + out_item->GetDamageMod() + 1; |
559 | 1820 out_item->uMaxCharges = out_item->uNumCharges; |
1821 default: | |
224 | 1822 return; |
559 | 1823 } |
1824 | |
1825 j=0; | |
1826 int spc_sum=0; | |
1827 int spc; | |
1828 memset(&val_list, 0, 3200); | |
1829 for (int i=0; i<pSpecialEnchantments_count;++i) | |
1830 { | |
1831 int tr_lv= pSpecialEnchantments[i].iTreasureLevel; | |
1832 switch ( treasure_level - 1 ) | |
1833 { | |
0 | 1834 case 2: |
559 | 1835 if ((tr_lv==1)||(tr_lv==0)) |
1836 { | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1837 spc=pSpecialEnchantments[i].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1838 spc_sum+=spc; |
1839 if(spc) | |
1840 { | |
1841 val_list[j++]=i; | |
1842 } | |
1843 } | |
1844 break; | |
0 | 1845 case 3: |
559 | 1846 if ((tr_lv==2)||(tr_lv==1)||(tr_lv==0)) |
1847 { | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1848 spc=pSpecialEnchantments[i].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1849 spc_sum+=spc; |
1850 if(spc) | |
1851 { | |
1852 val_list[j++]=i; | |
1853 } | |
1854 } | |
1855 break; | |
1856 case 4: | |
1857 if ((tr_lv==3)||(tr_lv==2)||(tr_lv==1)) | |
1858 { | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1859 spc=pSpecialEnchantments[i].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1860 spc_sum+=spc; |
1861 if(spc) | |
1862 { | |
1863 val_list[j++]=i; | |
1864 } | |
1865 } | |
1866 break; | |
1867 case 5: | |
1868 if (tr_lv==3) | |
1869 { | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1870 spc=pSpecialEnchantments[i].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1871 spc_sum+=spc; |
1872 if(spc) | |
1873 { | |
1874 val_list[j++]=i; | |
1875 } | |
1876 } | |
1877 break; | |
0 | 1878 } |
559 | 1879 } |
1880 | |
1881 v46 = rand()%spc_sum+1; | |
1882 j=0; | |
1883 out_item->uSpecEnchantmentType =val_list[j]; | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1884 v45=pSpecialEnchantments[val_list[j]].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1885 if (v45<v46) |
1886 { | |
1887 do | |
245 | 1888 { |
559 | 1889 ++j; |
1890 out_item->uSpecEnchantmentType=val_list[j]; | |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
1891 v45+=pSpecialEnchantments[val_list[j]].to_item_apply[out_item->GetItemEquipType()]; |
559 | 1892 } while (v45<v46); |
1893 } | |
1894 ++out_item->uSpecEnchantmentType; | |
0 | 1895 } |
1896 | |
1897 //----- (004505CC) -------------------------------------------------------- | |
1898 bool ItemGen::GenerateArtifact() | |
1899 { | |
1900 signed int uNumArtifactsNotFound; // esi@1 | |
463 | 1901 int artifacts_list[32]; |
0 | 1902 |
385 | 1903 memset(artifacts_list, 0,sizeof(artifacts_list)); |
0 | 1904 uNumArtifactsNotFound = 0; |
385 | 1905 |
1906 for (int i=500;i<529;++i) | |
484 | 1907 if ( !pParty->pIsArtifactFound[i-500] ) |
385 | 1908 artifacts_list[uNumArtifactsNotFound++] = i; |
1909 | |
1910 Reset(); | |
0 | 1911 if ( uNumArtifactsNotFound ) |
1912 { | |
385 | 1913 uItemID = artifacts_list[rand() % uNumArtifactsNotFound]; |
1914 pItemsTable->SetSpecialBonus(this); | |
1915 return true; | |
0 | 1916 } |
1917 else | |
385 | 1918 return false; |
1919 | |
0 | 1920 } |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1921 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1922 std::map<int, std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* >ItemGen::regularBonusMap; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1923 std::map<int, std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* >ItemGen::specialBonusMap; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1924 std::map<int, std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* >ItemGen::artifactBonusMap; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1925 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1926 #define NEWBONUSINTOSPECIALLIST(x,y) AddToMap(ItemGen::specialBonusMap, enchId, x, y); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1927 #define NEWBONUSINTOSPECIALLIST2(x,y,z) AddToMap(ItemGen::specialBonusMap, enchId, x, y, z); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1928 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1929 #define NEWBONUSINTOREGULARLIST(x) AddToMap(ItemGen::regularBonusMap, enchId, x); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1930 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1931 #define NEWBONUSINTOARTIFACTLIST(x,y) AddToMap(ItemGen::artifactBonusMap, itemId, x, y); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1932 #define NEWBONUSINTOARTIFACTLIST2(x,y,z) AddToMap(ItemGen::artifactBonusMap, itemId, x, y, z); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1933 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1934 void ItemGen::AddToMap( std::map<int, std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* > &maptoadd, int enchId, CHARACTER_ATTRIBUTE_TYPE attrId, int bonusValue /*= 0*/, unsigned __int16 Player::* skillPtr /*= NULL*/ ) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1935 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1936 auto key = maptoadd.find(enchId); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1937 std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* currMap; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1938 if (key == maptoadd.end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1939 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1940 currMap = new std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1941 maptoadd[enchId] = currMap; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1942 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1943 else |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1944 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1945 currMap = key->second; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1946 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1947 Assert(currMap->find(attrId) == currMap->end(), "Attribute %d already present for enchantment %d", attrId, enchId); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1948 (*currMap)[attrId] = new CEnchantment(bonusValue, skillPtr); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1949 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1950 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1951 void ItemGen::PopulateSpecialBonusMap() |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1952 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1953 int enchId = 1;// of Protection, +10 to all Resistances |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1954 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1955 NEWBONUSINTOSPECIALLIST( CHARACTER_ATTRIBUTE_RESIST_AIR, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1956 NEWBONUSINTOSPECIALLIST( CHARACTER_ATTRIBUTE_RESIST_WATER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1957 NEWBONUSINTOSPECIALLIST( CHARACTER_ATTRIBUTE_RESIST_EARTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1958 NEWBONUSINTOSPECIALLIST( CHARACTER_ATTRIBUTE_RESIST_MIND, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1959 NEWBONUSINTOSPECIALLIST( CHARACTER_ATTRIBUTE_RESIST_BODY, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1960 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1961 enchId = 2;//of The Gods, +10 to all Seven Statistics |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1962 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_STRENGTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1963 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1964 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1965 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1966 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ACCURACY, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1967 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_SPEED, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1968 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_LUCK, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1969 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1970 enchId = 26;//of Air Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1971 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_AIR,0, &Player::skillAir); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1972 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1973 enchId = 27;//of Body Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1974 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_BODY,0, &Player::skillBody); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1975 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1976 enchId = 28;//of Dark Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1977 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_DARK,0, &Player::skillDark); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1978 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1979 enchId = 29;//of Earth Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1980 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_EARTH,0, &Player::skillEarth); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1981 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1982 enchId = 30;//of Fire Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1983 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_FIRE,0, &Player::skillFire); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1984 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1985 enchId = 31;//of Light Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1986 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_LIGHT,0, &Player::skillLight); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1987 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1988 enchId = 32;//of Mind Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1989 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_MIND,0, &Player::skillMind); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1990 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1991 enchId = 33;//of Spirit Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1992 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_SPIRIT,0, &Player::skillSpirit); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1993 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1994 enchId = 34;//of Water Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1995 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_WATER,0, &Player::skillWater); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1996 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1997 enchId = 42;//of Doom |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1998 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_STRENGTH, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
1999 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2000 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2001 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2002 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ACCURACY, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2003 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_SPEED, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2004 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_LUCK, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2005 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_HEALTH, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2006 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_MANA, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2007 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_AC_BONUS, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2008 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2009 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2010 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_WATER, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2011 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_EARTH, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2012 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_MIND, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2013 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_BODY, 1); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2014 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2015 enchId = 43;//of Earth |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2016 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2017 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_AC_BONUS, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2018 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_HEALTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2019 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2020 enchId = 44;//of Life |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2021 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_HEALTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2022 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2023 enchId = 45;//Rogues |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2024 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_SPEED, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2025 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ACCURACY, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2026 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2027 enchId = 46;//of The Dragon |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2028 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_STRENGTH, 25); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2029 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2030 enchId = 47;//of The Eclipse |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2031 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_MANA, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2032 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2033 enchId = 48;//of The Golem |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2034 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2035 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_AC_BONUS, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2036 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2037 enchId = 49;//of The Moon |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2038 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2039 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_LUCK, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2040 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2041 enchId = 50;//of The Phoenix |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2042 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, 30); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2043 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2044 enchId = 51;//of The Sky |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2045 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_MANA, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2046 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_SPEED, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2047 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2048 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2049 enchId = 52;//of The Stars |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2050 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2051 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ACCURACY, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2052 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2053 enchId = 53;//of The Sun |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2054 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_STRENGTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2055 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2056 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2057 enchId = 54;//of The Troll |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2058 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2059 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2060 enchId = 55;//of The Unicorn |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2061 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_LUCK, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2062 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2063 enchId = 56;//Warriors |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2064 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_STRENGTH, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2065 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2066 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2067 enchId = 57;//Wizards |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2068 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2069 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2070 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2071 enchId = 60;//Monks' |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2072 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_DODGE, 3, &Player::skillDodge); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2073 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_UNARMED, 3, &Player::skillUnarmed); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2074 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2075 enchId = 61;//Thieves' |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2076 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 3, &Player::skillStealing); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2077 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_STEALING, 3, &Player::skillDisarmTrap); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2078 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2079 enchId = 62;//of Identifying |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2080 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_ITEM_ID, 3, &Player::skillItemId); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2081 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_MONSTER_ID, 3, &Player::skillMonsterId); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2082 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2083 enchId = 67;//Assassins' |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2084 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 2, &Player::skillDisarmTrap); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2085 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2086 enchId = 68;//Barbarians' |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2087 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_AC_BONUS, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2088 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2089 enchId = 69;//of the Storm |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2090 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, 20); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2091 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2092 enchId = 70;//of the Ocean |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2093 NEWBONUSINTOSPECIALLIST(CHARACTER_ATTRIBUTE_RESIST_WATER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2094 NEWBONUSINTOSPECIALLIST2(CHARACTER_ATTRIBUTE_SKILL_ALCHEMY, 2, &Player::skillAlchemy); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2095 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2096 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2097 void ItemGen::PopulateRegularBonusMap() |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2098 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2099 int enchId = 1;//of Might |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2100 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_STRENGTH); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2101 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2102 enchId = 2;//of Thought |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2103 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2104 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2105 enchId = 3;//of Charm |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2106 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_WILLPOWER); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2107 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2108 enchId = 4;//of Vigor |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2109 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_ENDURANCE); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2110 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2111 enchId = 5;//of Precision |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2112 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_ACCURACY); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2113 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2114 enchId = 6;//of Speed |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2115 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SPEED); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2116 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2117 enchId = 7;//of Luck |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2118 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_LUCK); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2119 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2120 enchId = 8;//of Health |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2121 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_HEALTH); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2122 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2123 enchId = 9;//of Magic |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2124 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_MANA); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2125 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2126 enchId = 10;//of Defense |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2127 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_AC_BONUS); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2128 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2129 enchId = 11;//of Fire Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2130 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2131 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2132 enchId = 12;//of Air Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2133 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_AIR); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2134 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2135 enchId = 13;//of Water Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2136 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_WATER); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2137 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2138 enchId = 14;//of Earth Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2139 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_EARTH); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2140 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2141 enchId = 15;//of Mind Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2142 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_MIND); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2143 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2144 enchId = 16;//of Body Resistance |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2145 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_RESIST_BODY); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2146 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2147 enchId = 17;//of Alchemy |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2148 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_ALCHEMY); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2149 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2150 enchId = 18;//of Stealing |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2151 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_STEALING); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2152 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2153 enchId = 19;//of Disarming |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2154 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2155 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2156 enchId = 20;//of Items |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2157 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_ITEM_ID); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2158 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2159 enchId = 21;//of Monsters |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2160 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_MONSTER_ID); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2161 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2162 enchId = 22;//of Arms |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2163 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_ARMSMASTER); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2164 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2165 enchId = 23;//of Dodging |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2166 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_DODGE); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2167 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2168 enchId = 24;//of the Fist |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2169 NEWBONUSINTOREGULARLIST(CHARACTER_ATTRIBUTE_SKILL_UNARMED); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2170 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2171 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2172 void ItemGen::PopulateArtifactBonusMap() |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2173 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2174 int itemId; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2175 itemId = ITEM_ARTIFACT_PUCK; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2176 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2177 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2178 itemId = ITEM_ARTIFACT_IRON_FEATHER; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2179 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2180 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2181 itemId = ITEM_ARTIFACT_WALLACE; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2182 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2183 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_ARMSMASTER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2184 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2185 itemId = ITEM_ARTIFACT_CORSAIR; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2186 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_LUCK, 40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2187 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2188 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_STEALING, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2189 |
1648 | 2190 itemId = ITEM_ARTIFACT_GOVERNORS_ARMOR; |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2191 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2192 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2193 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2194 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2195 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ACCURACY, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2196 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2197 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_LUCK, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2198 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2199 itemId = ITEM_ARTIFACT_YORUBA; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2200 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 25); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2201 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2202 itemId = ITEM_ARTIFACT_SPLITTER; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2203 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2204 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2205 itemId = ITEM_ARTEFACT_ULLYSES, |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2206 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ACCURACY, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2207 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2208 itemId = ITEM_ARTEFACT_HANDS_OF_THE_MASTER, |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2209 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_DODGE, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2210 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_UNARMED, 10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2211 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2212 itemId = ITEM_ARTIFACT_LEAGUE_BOOTS; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2213 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, 40); |
1826 | 2214 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_WATER, 0, &Player::skillWater); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2215 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2216 itemId = ITEM_ARTIFACT_RULERS_RING; |
1826 | 2217 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_MIND, 0, &Player::skillMind); |
2218 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_DARK, 0, &Player::skillDark); | |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2219 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2220 itemId = ITEM_RELIC_MASH; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2221 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 150); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2222 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2223 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2224 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2225 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2226 itemId = ITEM_RELIC_ETHRICS_STAFF; |
1826 | 2227 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_DARK, 0, &Player::skillDark); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2228 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_MEDITATION, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2229 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2230 itemId = ITEM_RELIC_HARECS_LEATHER; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2231 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2232 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_STEALING, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2233 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_LUCK, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2234 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2235 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_WATER, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2236 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2237 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_EARTH, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2238 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_MIND, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2239 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_BODY, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2240 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2241 itemId = ITEM_RELIC_OLD_NICK; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2242 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_TRAP_DISARM, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2243 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2244 itemId = ITEM_RELIC_AMUCK; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2245 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 100); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2246 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 100); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2247 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_AC_BONUS, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2248 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2249 itemId = ITEM_RELIC_GLORY_SHIELD; |
1826 | 2250 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_SPIRIT, 0, &Player::skillSpirit); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2251 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_SHIELD, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2252 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_MIND, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2253 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_BODY, -10); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2254 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2255 itemId = ITEM_RELIC_KELEBRIM; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2256 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2257 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_EARTH, -30); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2258 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2259 itemId = ITEM_RELIC_TALEDONS_HELM; |
1826 | 2260 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_LIGHT, 0, &Player::skillLight); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2261 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2262 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2263 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_LUCK, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2264 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2265 itemId = ITEM_RELIC_SCHOLARS_CAP; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2266 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_LEARNING, +15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2267 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, -50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2268 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2269 itemId = ITEM_RELIC_PHYNAXIAN_CROWN; |
1826 | 2270 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_FIRE, 0, &Player::skillFire); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2271 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_WATER, +50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2272 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 30); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2273 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_AC_BONUS, -20); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2274 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2275 itemId = ITEM_RILIC_TITANS_BELT; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2276 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 75); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2277 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2278 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2279 itemId = ITEM_RELIC_TWILIGHT; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2280 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2281 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_LUCK, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2282 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2283 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_WATER, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2284 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2285 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_EARTH, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2286 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_MIND, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2287 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_BODY, -15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2288 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2289 itemId = ITEM_RELIC_ANIA_SELVING; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2290 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ACCURACY, 150); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2291 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_BOW, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2292 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_AC_BONUS, -25); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2293 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2294 itemId = ITEM_RELIC_JUSTICE; |
1826 | 2295 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_MIND, 0, &Player::skillMind); |
2296 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_BODY, 0, &Player::skillBody); | |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2297 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, -40); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2298 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2299 itemId = ITEM_RELIC_MEKORIGS_HAMMER; |
1826 | 2300 NEWBONUSINTOARTIFACTLIST2(CHARACTER_ATTRIBUTE_SKILL_SPIRIT, 0, &Player::skillSpirit); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2301 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 75); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2302 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, -50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2303 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2304 itemId = ITEM_ARTIFACT_HERMES_SANDALS; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2305 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, 100); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2306 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ACCURACY, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2307 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_AIR, 50); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2308 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2309 itemId = ITEM_ARTIFACT_CLOAK_OF_THE_SHEEP; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2310 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, -20); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2311 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, -20); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2312 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2313 itemId = ITEM_ARTIFACT_MINDS_EYE; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2314 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_WILLPOWER, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2315 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_INTELLIGENCE, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2316 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2317 itemId = ITEM_ELVEN_CHAINMAIL; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2318 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SPEED, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2319 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ACCURACY, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2320 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2321 itemId = ITEM_FORGE_GAUNTLETS; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2322 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2323 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_ENDURANCE, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2324 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_RESIST_FIRE, 30); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2325 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2326 itemId = ITEM_ARTIFACT_HEROS_BELT; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2327 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_STRENGTH, 15); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2328 NEWBONUSINTOARTIFACTLIST(CHARACTER_ATTRIBUTE_SKILL_ARMSMASTER, 5); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2329 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2330 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2331 void ItemGen::GetItemBonusSpecialEnchantment( Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* additiveBonus, int* halfSkillBonus ) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2332 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2333 auto bonusList = ItemGen::specialBonusMap.find(this->uSpecEnchantmentType); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2334 if (bonusList == ItemGen::specialBonusMap.end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2335 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2336 return; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2337 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2338 std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* currList = bonusList->second; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2339 if (currList->find(attrToGet) != currList->end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2340 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2341 CEnchantment* currBonus = (*currList)[attrToGet]; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2342 if (currBonus->statPtr != NULL) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2343 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2344 if (currBonus->statBonus == 0) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2345 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2346 *halfSkillBonus = owner->*currBonus->statPtr / 2; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2347 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2348 else |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2349 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2350 if (*additiveBonus < currBonus->statBonus) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2351 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2352 *additiveBonus = currBonus->statBonus; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2353 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2354 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2355 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2356 else |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2357 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2358 *additiveBonus += currBonus->statBonus; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2359 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2360 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2361 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2362 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2363 void ItemGen::GetItemBonusArtifact( Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* bonusSum ) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2364 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2365 auto bonusList = ItemGen::artifactBonusMap.find(this->uItemID); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2366 if (bonusList == ItemGen::artifactBonusMap.end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2367 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2368 return; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2369 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2370 std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* currList = bonusList->second; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2371 if (currList->find(attrToGet) != currList->end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2372 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2373 CEnchantment* currBonus = (*currList)[attrToGet]; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2374 if (currBonus->statPtr != NULL) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2375 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2376 *bonusSum = owner->*currBonus->statPtr / 2; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2377 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2378 else |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2379 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2380 *bonusSum += currBonus->statBonus; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2381 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2382 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2383 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2384 |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2385 bool ItemGen::IsRegularEnchanmentForAttribute( CHARACTER_ATTRIBUTE_TYPE attrToGet ) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2386 { |
1685
2a309997c42f
Player::StealFromShop started cleanup, fixing a few errors caused by not commiting everything
Grumpy7
parents:
1682
diff
changeset
|
2387 auto bonusList = ItemGen::specialBonusMap.find(this->uEnchantmentType); |
1604
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2388 if (bonusList == ItemGen::specialBonusMap.end()) |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2389 { |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2390 return false; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2391 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2392 std::map<CHARACTER_ATTRIBUTE_TYPE, CEnchantment*>* currList = bonusList->second; |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2393 return (currList->find(attrToGet) != currList->end()); |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2394 } |
4b79ff62df3a
Moved enchantment attribute bonus list to items.cpp/h, created static function that create the enchantments + helper functions to get the enchantment strength, moved the whole logic of Player::GetItemsBonus to a case
Grumpy7
parents:
1603
diff
changeset
|
2395 |
1709
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2396 ITEM_EQUIP_TYPE ItemGen::GetItemEquipType() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2397 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2398 return pItemsTable->pItems[this->uItemID].uEquipType; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2399 } |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2400 |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2401 unsigned char ItemGen::GetPlayerSkillType() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2402 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2403 return pItemsTable->pItems[this->uItemID].uSkillType; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2404 } |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2405 |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2406 char* ItemGen::GetIconName() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2407 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2408 return pItemsTable->pItems[this->uItemID].pIconName; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2409 } |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2410 |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2411 unsigned __int8 ItemGen::GetDamageDice() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2412 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2413 return pItemsTable->pItems[this->uItemID].uDamageDice; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2414 } |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2415 |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2416 unsigned __int8 ItemGen::GetDamageRoll() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2417 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2418 return pItemsTable->pItems[this->uItemID].uDamageRoll; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2419 } |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2420 |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2421 unsigned __int8 ItemGen::GetDamageMod() |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2422 { |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2423 return pItemsTable->pItems[this->uItemID].uDamageMod; |
8251e59fd7c1
ITEM_ENCHANTED to ITEM_HARDENED, created helper functions to get params from itemtable for ItemGens
Grumpy7
parents:
1685
diff
changeset
|
2424 } |
461 | 2425 //----- (004B8E3D) -------------------------------------------------------- |
463 | 2426 void GenerateStandartShopItems() |
1920 | 2427 { |
2428 signed int item_count; | |
2429 signed int shop_index; | |
2430 int treasure_lvl; | |
2431 int item_class; | |
2432 int mdf; | |
463 | 2433 |
1920 | 2434 shop_index = (signed int)window_SpeakInHouse->ptr_1C; |
2435 if ( uItemsAmountPerShopType[p2DEvents[shop_index - 1].uType] ) | |
2436 { | |
2437 for (item_count = 0; item_count < uItemsAmountPerShopType[p2DEvents[shop_index - 1].uType]; ++item_count ) | |
2438 { | |
2439 if (shop_index <= 14) //weapon shop | |
2440 { | |
2441 treasure_lvl = shopWeap_variation_ord[shop_index].treasure_level; | |
2442 item_class = shopWeap_variation_ord[shop_index].item_class[rand() % 4]; | |
2443 } | |
2444 else if (shop_index <= 28) //armor shop | |
2445 { | |
2446 mdf = 0; | |
2447 if (item_count > 3) | |
2448 ++mdf;// rechek offsets | |
2449 treasure_lvl = shopArmr_variation_ord[2*(shop_index - 15) + mdf].treasure_level; | |
2450 item_class = shopArmr_variation_ord[2*(shop_index - 15) + mdf].item_class[rand() % 4]; | |
2451 } | |
2452 else if (shop_index <= 41) //magic shop | |
2453 { | |
2454 treasure_lvl = shopMagic_treasure_lvl[shop_index - 28]; | |
2455 item_class = 22; //misc | |
2456 } | |
2457 else if (shop_index <= 53) //alchemist shop | |
2458 { | |
2459 if (item_count < 6) | |
2460 { | |
2461 pParty->StandartItemsInShops[shop_index][item_count].Reset(); | |
2462 pParty->StandartItemsInShops[shop_index][item_count].uItemID = 220; //potion bottle | |
2463 continue; | |
2464 } | |
2465 else | |
2466 { | |
2467 treasure_lvl = shopAlch_treasure_lvl[shop_index - 41]; | |
2468 item_class = 45; //reagent | |
2469 } | |
2470 } | |
2471 pItemsTable->GenerateItem(treasure_lvl, item_class, &pParty->StandartItemsInShops[shop_index][item_count]); | |
2472 pParty->StandartItemsInShops[shop_index][item_count].SetIdentified(); //identified | |
2473 } | |
2474 } | |
2475 pParty->InTheShopFlags[shop_index] = 0; | |
2476 } | |
463 | 2477 |
2478 //----- (004B8F94) -------------------------------------------------------- | |
2479 void GenerateSpecialShopItems() | |
1920 | 2480 { |
2481 signed int item_count; | |
2482 signed int shop_index; | |
2483 int treasure_lvl; | |
2484 int item_class; | |
2485 int mdf; | |
463 | 2486 |
1920 | 2487 shop_index = (signed int)window_SpeakInHouse->ptr_1C; |
2488 if ( uItemsAmountPerShopType[p2DEvents[shop_index - 1].uType] ) | |
2489 { | |
2490 for ( item_count = 0; item_count < uItemsAmountPerShopType[p2DEvents[shop_index - 1].uType]; ++item_count ) | |
2491 { | |
2492 if (shop_index <= 14) //weapon shop | |
2493 { | |
2494 treasure_lvl = shopWeap_variation_spc[shop_index].treasure_level; | |
2495 item_class = shopWeap_variation_spc[shop_index].item_class[rand() % 4]; | |
2496 } | |
2497 else if (shop_index <= 28) //armor shop | |
2498 { | |
2499 mdf = 0; | |
2500 if (item_count > 3) | |
2501 ++mdf; | |
2502 treasure_lvl = shopArmr_variation_spc[2*(shop_index - 15) + mdf].treasure_level; | |
2503 item_class = shopArmr_variation_spc[2*(shop_index - 15) + mdf].item_class[rand() % 4]; | |
2504 } | |
2505 else if (shop_index <= 41) //magic shop | |
2506 { | |
2507 treasure_lvl = shopMagicSpc_treasure_lvl[shop_index - 28]; | |
2508 item_class = 22; //misc | |
2509 } | |
2510 else if (shop_index <= 53) //alchemist shop | |
2511 { | |
2512 if (item_count < 6) | |
2513 { | |
2514 pParty->SpecialItemsInShops[shop_index][item_count].Reset(); | |
2515 pParty->SpecialItemsInShops[shop_index][item_count].uItemID = rand() % 32 + 740; //mscrool | |
2516 continue; | |
2517 } | |
2518 else | |
2519 { | |
2520 treasure_lvl = shopAlchSpc_treasure_lvl[shop_index - 41]; | |
2521 item_class = 44; //potion | |
2522 } | |
2523 } | |
2524 pItemsTable->GenerateItem(treasure_lvl, item_class, &pParty->SpecialItemsInShops[shop_index][item_count]); | |
2525 pParty->SpecialItemsInShops[shop_index][item_count].SetIdentified(); //identified | |
2526 } | |
2527 } | |
2528 pParty->InTheShopFlags[shop_index] = 0; | |
2529 } | |
461 | 2530 |
2531 | |
463 | 2532 //----- (00450218) -------------------------------------------------------- |
598 | 2533 void GenerateItemsInChest() |
526 | 2534 { |
598 | 2535 unsigned int v0; // eax@1 |
2536 Chest *v1; // ebx@1 | |
2537 MapInfo *v2; // esi@1 | |
2538 ItemGen *v3; // ebx@2 | |
2539 int v4; // ebp@4 | |
2540 int v5; // edi@4 | |
2541 int v6; // esi@4 | |
2542 int v7; // eax@4 | |
2543 signed int v8; // esi@4 | |
2544 int v9; // edx@4 | |
2545 int v10; // esi@8 | |
2546 int v11; // ebp@25 | |
2547 int v12; // esi@25 | |
2548 signed int v13; // ebp@27 | |
2549 ItemGen *v14; // edi@28 | |
2550 signed int v15; // edx@32 | |
2551 signed __int64 v16; // qtt@32 | |
2552 int v17; // esi@34 | |
2553 signed int v18; // [sp+10h] [bp-18h]@1 | |
2554 int v19; // [sp+14h] [bp-14h]@4 | |
2555 MapInfo *v20; // [sp+18h] [bp-10h]@1 | |
2556 Chest *v21; // [sp+1Ch] [bp-Ch]@1 | |
2557 int v22; // [sp+20h] [bp-8h]@26 | |
2558 signed int v23; // [sp+24h] [bp-4h]@2 | |
461 | 2559 |
598 | 2560 v18 = rand() % 100; //main random |
1477
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1358
diff
changeset
|
2561 v0 = pMapStats->GetMapInfo(pCurrentMapName); |
598 | 2562 // v1 = pChests; |
2563 v2 = &pMapStats->pInfos[v0]; | |
2564 //v21 = pChests; | |
2565 //v20 = &pMapStats->pInfos[v0]; | |
2566 for(int i=1; i<20;++i) | |
2567 { | |
2568 for(int j=0; j<140;++j) | |
2569 { | |
526 | 2570 |
598 | 2571 v3 = &pChests[i].igChestItems[j]; |
2572 if ( v3->uItemID < 0 ) | |
2573 { | |
2574 v4 = rand() % 5; //additional items in chect | |
2575 v5 = (unsigned __int8)byte_4E8168[abs((int)v3->uItemID)-1][2*v2->Treasure_prob]; | |
2576 v6 = (unsigned __int8)byte_4E8168[abs((int)v3->uItemID)-1][2*v2->Treasure_prob+1]; | |
2577 v8 = v6 - v5 + 1; | |
2578 v9 = v5 + rand() % v8; //treasure level | |
2579 if (v9<7) | |
2580 { | |
2581 if (v18<20) | |
2582 { | |
2583 v3->Reset(); | |
2584 } | |
2585 else if (v18<60) //generate gold | |
2586 { | |
2587 v10=0; | |
2588 v3->Reset(); | |
2589 switch (v9) | |
2590 { | |
2591 case 1: //small gold | |
2592 v10 = rand() % 51 + 50; | |
2593 v3->uItemID = 197; | |
2594 break; | |
2595 case 2://small gold | |
2596 v10 = rand() % 101 + 100; | |
2597 v3->uItemID = 197; | |
2598 break; | |
2599 case 3: //medium | |
2600 v10 = rand() % 301 + 200; | |
2601 v3->uItemID = 198; | |
2602 break; | |
2603 case 4: //medium | |
2604 v10 = rand() % 501 + 500; | |
2605 v3->uItemID = 198; | |
2606 break; | |
2607 case 5: //big | |
2608 v10 = rand() % 1001 + 1000; | |
2609 v3->uItemID = 199; | |
2610 break; | |
2611 case 6: //big | |
2612 v10 = rand() % 3001 + 2000; | |
2613 v3->uItemID = 199; | |
2614 break; | |
2615 } | |
2616 v3->SetIdentified(); | |
2617 v3->uSpecEnchantmentType = v10; | |
2618 } | |
2619 else | |
2620 { | |
2621 pItemsTable->GenerateItem(v9, 0, v3); | |
2622 } | |
2623 | |
2624 v12 = 0; | |
2625 //generate more items | |
2626 for (v11=0; v11<v4; ++v11) | |
2627 { | |
2628 | |
2629 if ( v12 >= 140 ) | |
2630 break; | |
2631 while ( !(pChests[i].igChestItems[v12].uItemID==0) &&(v12<140)) | |
2632 { | |
2633 ++v12; | |
2634 } | |
2635 v14=&pChests[i].igChestItems[v12]; | |
2636 v18 = rand() % 100; | |
2637 if (v18<20) | |
2638 { | |
2639 v3->Reset(); | |
2640 } | |
2641 else if (v18<60) //generate gold | |
2642 { | |
2643 v10=0; | |
2644 v3->Reset(); | |
2645 switch (v9) | |
2646 { | |
2647 case 1: //small gold | |
2648 v10 = rand() % 51 + 50; | |
2649 v14->uItemID = 197; | |
2650 break; | |
2651 case 2://small gold | |
2652 v10 = rand() % 101 + 100; | |
2653 v14->uItemID = 197; | |
2654 break; | |
2655 case 3: //medium | |
2656 v10 = rand() % 301 + 200; | |
2657 v14->uItemID = 198; | |
2658 break; | |
2659 case 4: //medium | |
2660 v10 = rand() % 501 + 500; | |
2661 v14->uItemID = 198; | |
2662 break; | |
2663 case 5: //big | |
2664 v10 = rand() % 1001 + 1000; | |
2665 v14->uItemID = 199; | |
2666 break; | |
2667 case 6: //big | |
2668 v10 = rand() % 3001 + 2000; | |
2669 v14->uItemID = 199; | |
2670 break; | |
2671 } | |
2672 v14->SetIdentified(); | |
2673 v14->uSpecEnchantmentType = v10; | |
2674 } | |
2675 else | |
2676 { | |
2677 pItemsTable->GenerateItem(v9, 0, v14); | |
2678 } | |
2679 ++v12; | |
2680 } | |
2681 } | |
2682 else | |
2683 v3->GenerateArtifact(); | |
526 | 2684 } |
598 | 2685 } |
2686 } | |
2687 | |
2688 } | |
461 | 2689 |
2690 | |
2691 | |
2692 | |
463 | 2693 // 4505CC: using guessed type int var_A0[32]; |
2694 //----- (004B3703) -------------------------------------------------------- | |
473 | 2695 void FillAviableSkillsToTeach( int _this ) |
2696 { | |
1838 | 2697 const char *v30; // ecx@65 |
473 | 2698 unsigned int v29; // edx@56 |
2699 int v15; // ecx@19 | |
2700 int v33; // [sp-4h] [bp-2Ch]@23 | |
2701 int v34; // [sp-4h] [bp-2Ch]@43 | |
2702 int v21; // ecx@34 | |
2703 int v35[5]; // [sp+Ch] [bp-1Ch]@8 | |
2704 int v37=0; // [sp+24h] [bp-4h]@1* | |
2705 int i=0; | |
2706 | |
2707 dword_F8B1DC = 0; | |
2708 | |
2709 switch (_this) | |
463 | 2710 { |
473 | 2711 case 1: //shop weapon |
2712 for (int i=0; i<2; ++i) | |
2713 { | |
2714 for (int j=0; j<4; ++j) | |
2715 { | |
2716 if ( i ) | |
2717 v21 = shopWeap_variation_spc[(unsigned int)window_SpeakInHouse->ptr_1C].item_class[j]; | |
2718 else | |
2719 v21 = shopWeap_variation_ord[(unsigned int)window_SpeakInHouse->ptr_1C].item_class[j]; | |
463 | 2720 |
473 | 2721 switch (v21) |
463 | 2722 { |
473 | 2723 case 23: v34 = 37; break; |
2724 case 24: v34 = 38; break; | |
2725 case 25: v34 = 39; break; | |
2726 case 26: v34 = 40; break; | |
2727 case 27: v34 = 41; break; | |
2728 case 28: v34 = 42; break; | |
2729 case 30: v34 = 36; break; | |
2730 default: | |
2731 continue; | |
2732 } | |
2733 v37 = sub_4BE571(v34, v35, v37, 5); | |
463 | 2734 } |
2735 } | |
473 | 2736 break; |
2737 case 2: //shop armor | |
2738 | |
2739 for (int i=0; i<2; ++i) | |
463 | 2740 { |
473 | 2741 for (int j=0; j<2; ++j) |
463 | 2742 { |
473 | 2743 for (int k=0; k<4; ++k) |
463 | 2744 { |
473 | 2745 if ( i ) |
2746 v15 = shopArmr_variation_spc[(unsigned int)window_SpeakInHouse->ptr_1C-15+j].item_class[k]; | |
2747 else | |
2748 v15 = shopArmr_variation_ord[(unsigned int)window_SpeakInHouse->ptr_1C-15+j].item_class[k]; | |
2749 switch (v15) | |
463 | 2750 { |
473 | 2751 case 31: v33 = 45; break; |
2752 case 32: v33 = 46; break; | |
2753 case 33: v33 = 47; break; | |
2754 case 34: v33 = 44; break; | |
2755 default: | |
2756 continue; | |
463 | 2757 } |
473 | 2758 v37 = sub_4BE571(v33, v35, v37, 5); |
463 | 2759 } |
2760 } | |
2761 } | |
473 | 2762 break; |
2763 case 3: //shop magic | |
2764 v37 = 2; | |
2765 v35[0] = 57; | |
2766 v35[1] = 59; | |
2767 break; | |
2768 case 4: //shop alchemist | |
2769 v37 = 2; | |
2770 v35[0] = 71; | |
2771 v35[1] = 68; | |
2772 break; | |
2773 case 21: //tavern | |
2774 v37 = 3; | |
2775 v35[0] = 70; | |
2776 v35[1] = 65; | |
2777 v35[2] = 62; | |
2778 break; | |
2779 case 23: //temple | |
2780 v37 = 3; | |
2781 v35[0] = 67; | |
2782 v35[1] = 66; | |
2783 v35[2] = 58; | |
2784 break; | |
2785 case 30: ///trainig | |
2786 v37 = 2; | |
2787 v35[0] = 69; | |
2788 v35[1] = 60; | |
2789 break; | |
2790 } | |
2791 for(i=0;i<v37;++i) | |
2792 { | |
2793 v29=v35[i]; | |
2794 switch(v29) | |
463 | 2795 { |
473 | 2796 case 40 :v30 = pSkillNames[4]; break; |
2797 case 5 : v30 = pSkillNames[23]; break; | |
2798 case 36 :v30 = pSkillNames[0]; break; | |
2799 case 37 :v30 = pSkillNames[1]; break; | |
2800 case 38 :v30 = pSkillNames[2]; break; | |
2801 case 39 :v30 = pSkillNames[3]; break; | |
2802 case 41 :v30 = pSkillNames[5]; break; | |
2803 case 42 :v30 = pSkillNames[6]; break; | |
2804 case 44 :v30 = pSkillNames[8]; break; | |
2805 case 45 :v30 = pSkillNames[9]; break; | |
2806 case 46 :v30 = pSkillNames[10]; break; | |
2807 case 47 :v30 = pSkillNames[11]; break; | |
2808 case 66 :v30 = pSkillNames[30]; break; | |
2809 case 57 :v30 = pSkillNames[21]; break; | |
2810 case 58 :v30 = pSkillNames[22]; break; | |
2811 case 60 :v30 = pSkillNames[24]; break; | |
2812 case 62 :v30 = pSkillNames[26]; break; | |
2813 case 65 :v30 = pSkillNames[29]; break; | |
2814 case 67:v30 = pSkillNames[31]; break; | |
2815 case 68:v30 = pSkillNames[32]; break; | |
2816 case 69:v30 = pSkillNames[33]; break; | |
2817 case 70:v30 = pSkillNames[34]; break; | |
2818 case 71:v30 = pSkillNames[35]; break; | |
2819 default: | |
463 | 2820 v30 = pGlobalTXT_LocalizationStrings[127]; //"No Text!" |
2821 } | |
1843
2e6d3cd052e0
some char* cast removal + adding const_casts where appropriate
Grumpy7
parents:
1838
diff
changeset
|
2822 pShopOptions[dword_F8B1DC] = const_cast<char *>(v30); |
473 | 2823 ++dword_F8B1DC; |
2824 CreateButtonInColumn(i+1, v29); | |
463 | 2825 } |
972 | 2826 pDialogueWindow->_41D08F_set_keyboard_control_group(i, 1, 0, 2); |
473 | 2827 dword_F8B1E0 = pDialogueWindow->pNumPresenceButton; |
2828 } | |
475 | 2829 |
2830 //----- (004BE571) -------------------------------------------------------- | |
2831 int sub_4BE571(int a1, int *a2, int a3, int a4) | |
2832 { | |
2833 int result; // eax@1 | |
2834 int i; // esi@3 | |
2835 | |
2836 result = a3; | |
2837 if ( a3 < a4 ) | |
2838 { | |
2839 for ( i = 0; i < a3; ++i ) | |
2840 { | |
2841 if ( a1 == a2[i] ) | |
2842 break; | |
2843 } | |
2844 if ( i == a3 ) | |
2845 { | |
2846 a2[a3] = a1; | |
2847 result = a3 + 1; | |
2848 } | |
2849 return result; | |
2850 } | |
2851 else | |
2852 { | |
2853 return a4; | |
2854 } | |
2855 } | |
1297 | 2856 //----- (0043C91D) -------------------------------------------------------- |
2857 int __fastcall GetItemTextureFilename(char *pOut, signed int item_id, int index, int shoulder) | |
2858 { | |
2859 int result; // eax@2 | |
2860 char v5; // zf@3 | |
2861 const char *v6; // [sp-Ch] [bp-18h]@88 | |
2862 signed int v7; // [sp-8h] [bp-14h]@61 | |
2863 int v8; // [sp-4h] [bp-10h]@61 | |
2864 signed int v9; // [sp-4h] [bp-10h]@69 | |
475 | 2865 |
1297 | 2866 result = 0; //BUG fn is void |
2867 if ( item_id <= 500 ) | |
2868 { | |
2869 //v5 = *((char *)&pBloodsplatContainer->std__vector_pBloodsplats[62].field_20 + a2 + 2) == 0; | |
2870 v5 = party_has_equipment[(item_id - 100) + 32 + 2] == 0; | |
2871 switch ( item_id ) | |
2872 { | |
2873 case 516: | |
2874 v5 = byte_5111F6[2] == 0; | |
2875 break; | |
2876 case 505: | |
2877 v5 = byte_5111F6[1] == 0; | |
2878 break; | |
2879 case 504: | |
2880 v5 = byte_5111F6[0] == 0; | |
2881 break; | |
2882 case 533: | |
2883 v5 = byte_5111F6[16] == 0; | |
2884 break; | |
2885 case 512: | |
2886 v5 = byte_5111F6[3] == 0; | |
2887 break; | |
2888 case 521: | |
2889 v5 = byte_5111F6[4] == 0; | |
2890 break; | |
2891 case 522: | |
2892 v5 = byte_5111F6[5] == 0; | |
2893 break; | |
2894 case 523: | |
2895 v5 = byte_5111F6[6] == 0; | |
2896 break; | |
2897 case 532: | |
2898 v5 = byte_5111F6[7] == 0; | |
2899 break; | |
2900 case 544: | |
2901 v5 = byte_5111F6[8] == 0; | |
2902 break; | |
2903 case 524: | |
2904 v5 = byte_5111F6[9] == 0; | |
2905 break; | |
2906 case 535: | |
2907 v5 = byte_5111F6[10] == 0; | |
2908 break; | |
2909 case 525: | |
2910 v5 = byte_5111F6[11] == 0; | |
2911 break; | |
2912 case 530: | |
2913 v5 = byte_5111F6[12] == 0; | |
2914 break; | |
2915 case 547: | |
2916 v5 = byte_5111F6[13] == 0; | |
2917 break; | |
2918 case 548: | |
2919 v5 = byte_5111F6[14] == 0; | |
2920 break; | |
2921 case 550: | |
2922 v5 = byte_5111F6[15] == 0; | |
2923 break; | |
2924 default: | |
2925 break; | |
2926 } | |
2927 if ( v5 ) | |
2928 return result; | |
2929 result = 516; | |
2930 if ( item_id < 66 || item_id > 78 ) | |
2931 { | |
2932 if ( item_id == 516 ) | |
2933 { | |
2934 if ( !shoulder ) | |
2935 return sprintf(pOut, "item%3.3dv%d", 234, index); | |
2936 if ( shoulder == 1 ) | |
2937 return sprintf(pOut, "item%3.3dv%da1", 234, index); | |
2938 if ( shoulder == 2 ) | |
2939 return sprintf(pOut, "item%3.3dv%da2", 234, index); | |
2940 } | |
2941 if ( item_id != 504 && item_id != 505 && item_id != 533 ) | |
2942 { | |
2943 if ( (item_id < 100 || item_id > 104) && item_id != 524 && item_id != 535 ) | |
2944 { | |
2945 if ( item_id >= 115 && item_id <= 119 || item_id == 512 ) | |
2946 { | |
2947 if ( item_id == 512 ) | |
2948 item_id = 312; | |
2949 return sprintf(pOut, "item%3.3dv%d", item_id, index); | |
2950 } | |
2951 if ( (item_id < 89 || item_id > 99) && item_id != 521 && item_id != 522 && item_id != 523 && item_id != 532 && item_id != 544 ) | |
2952 { | |
2953 result = 525; | |
2954 if ( (item_id < 105 || item_id > 109) && item_id != 525 && item_id != 530 && item_id != 547 && item_id != 548 && item_id != 550 ) | |
2955 return result; | |
2956 switch ( item_id ) | |
2957 { | |
2958 case 525: | |
2959 item_id = 325; | |
2960 break; | |
2961 case 530: | |
2962 item_id = 330; | |
2963 break; | |
2964 case 547: | |
2965 item_id = 347; | |
2966 break; | |
2967 case 548: | |
2968 item_id = 348; | |
2969 break; | |
2970 case 550: | |
2971 item_id = 350; | |
2972 break; | |
2973 } | |
2974 if ( !shoulder ) | |
2975 return sprintf(pOut, "item%3.3dv%d", item_id, index); | |
2976 return sprintf(pOut, "item%3.3dv%da1", item_id, index); | |
2977 } | |
2978 if ( item_id == 521 ) | |
2979 return sprintf(pOut, "item%3.3dv%d", 239, index); | |
2980 if ( item_id == 522 ) | |
2981 return sprintf(pOut, "item%3.3dv%d", 240, index); | |
2982 if ( item_id == 523 ) | |
2983 return sprintf(pOut, "item%3.3dv%d", 241, index); | |
2984 if ( item_id != 532 ) | |
2985 { | |
2986 if ( item_id == 544 ) | |
2987 item_id = 344; | |
2988 return sprintf(pOut, "item%3.3dv%d", item_id, index); | |
2989 } | |
2990 return sprintf(pOut, "item%3.3dv%d", 93, index); | |
2991 } | |
2992 if ( item_id == 524 ) | |
2993 return sprintf(pOut, "item%3.3dv%d", 324, index); | |
2994 if ( item_id == 535 ) | |
2995 item_id = 104; | |
2996 return sprintf(pOut, "item%3.3dv%d", item_id, index); | |
2997 } | |
2998 } | |
2999 if ( item_id != 516 ) | |
3000 { | |
3001 switch ( item_id ) | |
3002 { | |
3003 case 504: | |
3004 item_id = 235; | |
3005 break; | |
3006 case 505: | |
3007 item_id = 236; | |
3008 break; | |
3009 case 533: | |
3010 item_id = 73; | |
3011 break; | |
3012 } | |
3013 if ( !shoulder ) | |
3014 return sprintf(pOut, "item%3.3dv%d", item_id, index); | |
3015 if ( shoulder == 1 ) | |
3016 return sprintf(pOut, "item%3.3dv%da1", item_id, index); | |
3017 if ( shoulder == 2 ) | |
3018 return sprintf(pOut, "item%3.3dv%da2", item_id, index); | |
3019 } | |
3020 if ( !shoulder ) | |
3021 return sprintf(pOut, "item%3.3dv%d", 234, index); | |
3022 if ( shoulder == 1 ) | |
3023 return sprintf(pOut, "item%3.3dv%da1", 234, index); | |
3024 if ( shoulder == 2 ) | |
3025 return sprintf(pOut, "item%3.3dv%da2", 234, index); | |
3026 } | |
3027 result = item_id - 504; | |
3028 return result; | |
3029 } | |
475 | 3030 |