Skip to content

Commit

Permalink
[hellfire] SpawnQuestItem bin exact
Browse files Browse the repository at this point in the history
  • Loading branch information
qndel authored and AJenbo committed Sep 15, 2019
1 parent 19d7286 commit d720e45
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion Source/items.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2509,6 +2509,9 @@ void SpawnQuestItem(int itemid, int x, int y, int randarea, int selflag)
BOOL failed;
int i, j, tries;

#ifdef HELLFIRE
int curlv = items_get_currlevel();
#endif
if (randarea) {
tries = 0;
while (1) {
Expand All @@ -2535,13 +2538,17 @@ void SpawnQuestItem(int itemid, int x, int y, int randarea, int selflag)
item[i]._ix = x;
item[i]._iy = y;
dItem[x][y] = i + 1;
#ifdef HELLFIRE
GetItemAttrs(i, itemid, curlv);
#else
GetItemAttrs(i, itemid, currlevel);
#endif
SetupItem(i);
item[i]._iPostDraw = TRUE;
if (selflag) {
item[i]._iAnimFlag = FALSE;
item[i]._iSelFlag = selflag;
item[i]._iAnimFrame = item[i]._iAnimLen;
item[i]._iAnimFlag = FALSE;
}
numitems++;
}
Expand Down

0 comments on commit d720e45

Please sign in to comment.