comparison Items.h @ 2495:7b076fe64f23

GetItemTextureFilename fix
author Ritor1
date Wed, 17 Sep 2014 17:35:13 +0600
parents 104fdbea0386
children
comparison
equal deleted inserted replaced
2494:de8c5c223e9c 2495:7b076fe64f23
24 enum ITEM_FLAGS :unsigned int 24 enum ITEM_FLAGS :unsigned int
25 { 25 {
26 ITEM_IDENTIFIED = 0x1, 26 ITEM_IDENTIFIED = 0x1,
27 ITEM_BROKEN = 0x2, 27 ITEM_BROKEN = 0x2,
28 ITEM_TEMP_BONUS = 0x8, 28 ITEM_TEMP_BONUS = 0x8,
29 ITEM_AURA_EFFECT_RED = 0x10,//16 29 ITEM_AURA_EFFECT_RED = 0x10,
30 ITEM_AURA_EFFECT_BLUE = 0x20,//32 30 ITEM_AURA_EFFECT_BLUE = 0x20,
31 ITEM_AURA_EFFECT_GREEN = 0x40,//64 31 ITEM_AURA_EFFECT_GREEN = 0x40,
32 ITEM_AURA_EFFECT_PURPLE = 0x80,//128 32 ITEM_AURA_EFFECT_PURPLE = 0x80,
33 ITEM_ENCHANT_ANIMATION = 0xF0,//240 33 ITEM_ENCHANT_ANIMATION = 0xF0,
34 ITEM_STOLEN = 0x100, 34 ITEM_STOLEN = 0x100,
35 ITEM_HARDENED = 0x200, 35 ITEM_HARDENED = 0x200,
36 }; 36 };
37 37
38 38
225 static void PopulateSpecialBonusMap(); 225 static void PopulateSpecialBonusMap();
226 static void PopulateRegularBonusMap(); 226 static void PopulateRegularBonusMap();
227 static void PopulateArtifactBonusMap(); 227 static void PopulateArtifactBonusMap();
228 static void ClearItemBonusMaps(); 228 static void ClearItemBonusMaps();
229 229
230 inline void ResetEnchantAnimation(){uAttributes &= 0xFFFFFF0F;}
231 inline bool ItemEnchanted()const {return(uAttributes & ITEM_ENCHANT_ANIMATION) != 0;}
232 inline bool AuraEffectRed()const {return(uAttributes & ITEM_ENCHANT_ANIMATION) == ITEM_AURA_EFFECT_RED;}
233 inline bool AuraEffectBlue()const {return(uAttributes & ITEM_ENCHANT_ANIMATION) == ITEM_AURA_EFFECT_BLUE;}
234 inline bool AuraEffectGreen()const {return(uAttributes & ITEM_ENCHANT_ANIMATION) == ITEM_AURA_EFFECT_GREEN;}
235 inline bool AuraEffectPurple()const {return(uAttributes & ITEM_ENCHANT_ANIMATION) == ITEM_AURA_EFFECT_PURPLE;}
236
230 void GetItemBonusSpecialEnchantment(Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* additiveBonus, int* halfSkillBonus); 237 void GetItemBonusSpecialEnchantment(Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* additiveBonus, int* halfSkillBonus);
231 void GetItemBonusArtifact(Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* bonusSum); 238 void GetItemBonusArtifact(Player* owner, CHARACTER_ATTRIBUTE_TYPE attrToGet, int* bonusSum);
232 bool IsRegularEnchanmentForAttribute(CHARACTER_ATTRIBUTE_TYPE attrToGet); 239 bool IsRegularEnchanmentForAttribute(CHARACTER_ATTRIBUTE_TYPE attrToGet);
233 240
234 inline bool IsBroken() {return (uAttributes & ITEM_BROKEN) != 0;} 241 inline bool IsBroken() {return (uAttributes & ITEM_BROKEN) != 0;}