Skip to content

Commit

Permalink
CheckRemoveItem: just ignore any item with no lower bits set
Browse files Browse the repository at this point in the history
better forward compatibility
  • Loading branch information
lynxlynxlynx committed Jan 11, 2014
1 parent f3ef5d7 commit c4eb819
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions gemrb/plugins/GUIScript/GUIScript.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7481,9 +7481,10 @@ int CheckRemoveItem(Actor *actor, CREItem *si, int action)
} else continue;
break;
//the named actor cannot remove it except when initiating a swap (used for plain inventory slots)
// and make sure not to treat earrings improperly (add other flags as they come)
// and make sure not to treat earrings improperly
case CRI_REMOVEFORSWAP:
if ((UsedItems[i].flags&1 && UsedItems[i].flags&4) || UsedItems[i].flags&16) {
int flags = UsedItems[i].flags;
if ((flags&1 && flags&4) || !(flags&15)) {
continue;
} // no continue
break;
Expand Down

0 comments on commit c4eb819

Please sign in to comment.