Skip to content

Commit

Permalink
Ear cleanup #2 (diasurgical#2100)
Browse files Browse the repository at this point in the history
  • Loading branch information
qndel authored Oct 11, 2020
1 parent 613fe07 commit b014263
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Source/items.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3063,7 +3063,7 @@ void RecreateEar(int ii, WORD ic, int iseed, int Id, int dur, int mdur, int ch,
tempstr[15] = ibuff & 0x7F;
tempstr[16] = '\0';
sprintf(item[ii]._iName, "Ear of %s", tempstr);
item[ii]._iCurs = ((ivalue >> 6) & 3) + 19;
item[ii]._iCurs = ((ivalue >> 6) & 3) + ICURS_EAR_SORCEROR;
item[ii]._ivalue = ivalue & 0x3F;
item[ii]._iCreateInfo = ic;
item[ii]._iSeed = iseed;
Expand Down
6 changes: 3 additions & 3 deletions Source/msg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,7 @@ void NetSendCmdGItem(BOOL bHiPri, BYTE bCmd, BYTE mast, BYTE pnum, BYTE ii)
cmd.bMDur = item[ii]._iName[15];
cmd.bCh = item[ii]._iName[16];
cmd.bMCh = item[ii]._iName[17];
cmd.wValue = item[ii]._ivalue | (item[ii]._iName[18] << 8) | ((item[ii]._iCurs - 19) << 6);
cmd.wValue = item[ii]._ivalue | (item[ii]._iName[18] << 8) | ((item[ii]._iCurs - ICURS_EAR_SORCEROR) << 6);
cmd.dwBuff = item[ii]._iName[22] | ((item[ii]._iName[21] | ((item[ii]._iName[20] | (item[ii]._iName[19] << 8)) << 8)) << 8);
} else {
cmd.wCI = item[ii]._iCreateInfo;
Expand Down Expand Up @@ -863,7 +863,7 @@ void NetSendCmdPItem(BOOL bHiPri, BYTE bCmd, BYTE x, BYTE y)
cmd.bMDur = plr[myplr].HoldItem._iName[15];
cmd.bCh = plr[myplr].HoldItem._iName[16];
cmd.bMCh = plr[myplr].HoldItem._iName[17];
cmd.wValue = plr[myplr].HoldItem._ivalue | (plr[myplr].HoldItem._iName[18] << 8) | ((plr[myplr].HoldItem._iCurs - 19) << 6);
cmd.wValue = plr[myplr].HoldItem._ivalue | (plr[myplr].HoldItem._iName[18] << 8) | ((plr[myplr].HoldItem._iCurs - ICURS_EAR_SORCEROR) << 6);
cmd.dwBuff = plr[myplr].HoldItem._iName[22] | ((plr[myplr].HoldItem._iName[21] | ((plr[myplr].HoldItem._iName[20] | (plr[myplr].HoldItem._iName[19] << 8)) << 8)) << 8);
} else {
cmd.wCI = plr[myplr].HoldItem._iCreateInfo;
Expand Down Expand Up @@ -928,7 +928,7 @@ void NetSendCmdDItem(BOOL bHiPri, int ii)
cmd.bMDur = item[ii]._iName[15];
cmd.bCh = item[ii]._iName[16];
cmd.bMCh = item[ii]._iName[17];
cmd.wValue = item[ii]._ivalue | (item[ii]._iName[18] << 8) | ((item[ii]._iCurs - 19) << 6);
cmd.wValue = item[ii]._ivalue | (item[ii]._iName[18] << 8) | ((item[ii]._iCurs - ICURS_EAR_SORCEROR) << 6);
cmd.dwBuff = item[ii]._iName[22] | ((item[ii]._iName[21] | ((item[ii]._iName[20] | (item[ii]._iName[19] << 8)) << 8)) << 8);
} else {
cmd.wCI = item[ii]._iCreateInfo;
Expand Down
2 changes: 1 addition & 1 deletion Source/pack.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ void PackItem(PkItemStruct *id, ItemStruct *is)
id->bMDur = is->_iName[15];
id->bCh = is->_iName[16];
id->bMCh = is->_iName[17];
id->wValue = is->_ivalue | (is->_iName[18] << 8) | ((is->_iCurs - 19) << 6);
id->wValue = is->_ivalue | (is->_iName[18] << 8) | ((is->_iCurs - ICURS_EAR_SORCEROR) << 6);
id->dwBuff = is->_iName[22] | ((is->_iName[21] | ((is->_iName[20] | (is->_iName[19] << 8)) << 8)) << 8);
} else {
id->iSeed = is->_iSeed;
Expand Down

0 comments on commit b014263

Please sign in to comment.