Skip to content

Commit 83b3c9c

Browse files
committed
Implement suggested changes
1 parent b709ffd commit 83b3c9c

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

Source/items.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3513,7 +3513,7 @@ void RecreateItem(const Player &player, Item &item, _item_indexes idx, uint16_t
35133513
{
35143514
bool tmpIsHellfire = gbIsHellfire;
35153515
item.dwBuff = dwBuff;
3516-
gbIsHellfire = item.dwBuff & CF_HELLFIRE;
3516+
gbIsHellfire = (item.dwBuff & CF_HELLFIRE) != 0;
35173517

35183518
if (idx == IDI_GOLD) {
35193519
InitializeItem(item, IDI_GOLD);

Source/pack.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ void UnPackItem(const ItemPack &packedItem, const Player &player, Item &item, bo
334334
item = {};
335335
// Item generation logic will assign CF_HELLFIRE based on isHellfire
336336
// so if we carry it over from packedItem, it may be incorrect
337-
const uint32_t dwBuff = (SDL_SwapLE32(packedItem.dwBuff) & ~CF_HELLFIRE) | (isHellfire ? CF_HELLFIRE : 0);
337+
const uint32_t dwBuff = SDL_SwapLE32(packedItem.dwBuff) | (isHellfire ? CF_HELLFIRE : 0);
338338
RecreateItem(player, item, idx, SDL_SwapLE16(packedItem.iCreateInfo), SDL_SwapLE32(packedItem.iSeed), SDL_SwapLE16(packedItem.wValue), dwBuff);
339339
item._iIdentified = (packedItem.bId & 1) != 0;
340340
item._iMaxDur = packedItem.bMDur;

0 commit comments

Comments
 (0)