everything without any filtering in your container/ground search
this is basically it. * isn't really a parameter, it's just a modifier for finditem when you don't want to define what you're searching for, but do want to define where you are searching,
Example:
finditem c_ , #backpackid
finditem assumes that is parameter 1 i.e. what to search for, and it will find your backpack on your paperdoll #findcnt = 1 #bagid = #charid
using the * mods finditem so that the first parameter in the call is where to search.
so for your example, you could have done something like:
;run this with an "empty" backpack... no bods, no extra stuff
finditem * c_ , #backpackid
for #findindex 1 #findcnt
ignoreitem #findid
or made a list and added an if_not check in your finditem_check_for_craft
these are not necessarily better options... just other options, but in that last example finditem would return everything that is in your backpack.
as to your other point about keeping track of %sbodindex/cnt. I usually index at mnimum #findid as well, and just put everything in a big for loop, that way I don't have to finditem again every time I want to open a BOD.
for #findindex 1 #findcnt
set %sbodid . #findindex #findid
set %sbodcnt #findcnt
;then you just use your counter or a for() to set the id every cycle
if %sbod_index > %sbod_count
break
else
set %current_sbod %sbodid . %sbod_index
what's the command for that EUO code output?
added: I'm actually working on a finditem sub for storing multiple finditem arrays with chosen #findresults to parse against, but all of a sudden it's started "eating" one of my passed values in the middle of the sub and I can't figure out why, yet.
edit. just wanted to add about my previous post. I sort of knew how * worked, but I've never tried to describe it before, and on top of that I haven't touched a script or talked to anyone abut scripting for about 3 years. out of practice, and a bit out of touch lol. sorry if I confused you or seemed like an idiot before.