Code: Select all
itemCount = inventory:getItemCount(204833);
printf ("We have %d tools\n", itemCount );
Any ideas?scripts\rom\inv.lua:37: bad argument #1 to 'printf' (got nil)
Code: Select all
itemCount = inventory:getItemCount(204833);
printf ("We have %d tools\n", itemCount );
Any ideas?scripts\rom\inv.lua:37: bad argument #1 to 'printf' (got nil)
Code: Select all
inventory = CInventory();
while(true) do
if( keyPressedLocal(key.VK_SPACE) ) then
break;
end
itemCount = inventory:getItemCount(204833);
printf ("We have %d tools\n", itemCount );
yrest(100);
end
end
Code: Select all
RoMScript("GetBagItemCount("..itemId..")");
Code: Select all
itemTotalCount(itemNameOrId)
Code: Select all
inventory:getItemCount(204833)
as i said,S3v3n11 wrote:That does not seem to work either. Anyone have an example of
that works?Code: Select all
inventory:getItemCount(204833)
Or some other way I can get inventory item counts?
Thanks!
Code: Select all
inventory:update();
local count = inventory:getItemTotalCount(204833);
At which time or coding place are you doing that item count?S3v3n11 wrote:That does not seem to work either. Anyone have an example of
that works?Code: Select all
inventory:getItemCount(204833)
Or some other way I can get inventory item counts?
Thanks!
Code: Select all
<onLoad>
-- Additional Lua code to execute after loading the profile
-- and before the bot starts. e.g. You could overwrite profile settings here
-- like: changeProfileOption("HP_REST", 60);
printf("TEST: %s\n", inventory:getItemCount(454545) );
</onLoad>
Users browsing this forum: Bing [Bot], Google [Bot] and 0 guests