PDA

View Full Version : TReflectBankItem.GetQuantity and .GetSlot returning -1/0



Twinki
09-16-2015, 03:16 PM
I already talked to elfy about this, figured i'd go ahead and document it for other Reflection Devs to see, and to hopefully get it fixed a bit faster :p

https://i.gyazo.com/a43cfc204530036405d7921fb54ee835.png


procedure test;
Var
bankItem: TReflectBankItem;
begin
bankItem.Find('Bronze bar');
WriteLn('bankItem._Id '+toStr(bankItem._Id));
WriteLn('bankItem._Slot '+toStr(bankItem._Slot));
WriteLn('bankItem.GetGroundActions '+toStr(bankItem.GetGroundActions));
WriteLn('bankItem.GetHighAlchValue '+toStr(bankItem.GetHighAlchValue));
WriteLn('bankItem.GetId '+toStr(bankItem.GetId));
WriteLn('bankItem.GetInvActions '+toStr(bankItem.GetInvActions));
WriteLn('bankItem.GetName '+toStr(bankItem.GetName));
WriteLn('bankItem.GetQuantity '+toStr(bankItem.GetQuantity));
WriteLn('bankItem.GetSlot '+toStr(bankItem.GetSlot));
WriteLn('bankItem.Reference '+toStr(bankItem.Reference));
end;


It returns:
bankItem._Id 2349
bankItem._Slot 0
bankItem.GetGroundActions [null, null, Take, null, null]
bankItem.GetHighAlchValue 8
bankItem.GetId 2349
bankItem.GetInvActions [null, null, null, null, Drop]
bankItem.GetName Bronze bar
bankItem.GetQuantity -1
bankItem.GetSlot 0
bankItem.Reference 369813520

TReflectInvItem.GetQuantity seems to work perfectly fine.

Fitta
09-16-2015, 07:54 PM
At work @ Will look into and fix this tomorrow morning :)


Edit:

Fixed
https://github.com/FittaVillavu/OSR-Reflection/commit/19e7780fc2717d623b298005e492819ef68c37d0