My guess is that there is a ghost item in your backpack.
The script issues a finditem for all BOD types in your backpack and the first one receives the #findcol value, which is 0. This doesn't look like the case because you do not seem to have a random scroll (of the same type as a BOD - there are others that share this type) in your backpack.
Now it passes that #findcol value to figure out what type it is among valid BODs and produces the error.
What is interesting is your first video manages to fill the initial large except for the lacking SBOD. Then it is the second attempt to fill a large of the same types that fails. At this point several of the SBods would have been combined into the LBod, so the ghost item seems likely. I am not sure I tested filling several LBods of the exact same specifications, so I think your error is valid.
You should prove it by displaying a little more information before making a fix. How would I do that? Adjust the s7FindSBod routine to display the information and give me a chance to examine what my variables are at the point of the error.
Test it with the following alteration to this routine:
;///////////////////////////////////;
; s7FindSBod
; finds a filled sbod in backpack by name, quantity, and quality
;///////////////////////////////////;
sub s7FindSBod
set %FSBProp %2
set %FSBcnt %1
finditem EYM C_ , #backpackid
set %FSBfindcnt #findcnt
; Insert test code here
if #findcol = 0
{
display ok script paused because #findcol = 0 - verify the #find... variables
pause
}
; End test code
gosub SetBodType #findcol
set %s7BFSbodType #result
for %FSBfindI 1 %FSBfindcnt
{
finditem EYM %FSBfindI C_ , #backpackid
gosub s7GetProperty #findid A , #spc , Bulk , #spc , Order , #spc , Deed$
if %FSBProp in #property && large , #spc , bulk notin #property && ( ( %s7BFLbodExceptional && exceptional in #property ) || ( ! %s7BFLbodExceptional && exceptional notin #property ) )
{
gosub s7GetBodAmountMade
gosub GetBodMaterial #Property %s7BFSbodType
set %s7BFSBodMaterial #result
if %s7BFBodAmountMade = %FSBCnt && _ , %s7BFSBodMaterial , _ in _ , %s7BFLBodMaterial , _
return #true
}
}
return #false