Re: SVN r544 for game version 3.0.7.2322
Posted: Sun Dec 19, 2010 3:55 pm
When I start the bot, there is no inventory scan anymore, i.e. the %-count. Also, selling still does not work for me 

MicroMacro home
https://www.solarstrike.net/phpBB3/
Yes I did. I turned off Server-side safe, deleted macro bsd. Bot works fine, runs around, kills stuff, i get my equipment repaired, but I can't sell stuff.jduartedj wrote:Have you updated to latest SVN version? r548?
Wasn't this deprecated? doesn't the bot assumed INV_MAX_SLOTS=180 always?Alkaiser wrote:Argh... I've set INV_MAX_SLOTS back to 60, as leaving sell slots to 31 - 60 still sells from bag2. I'm still confused, but it works.
Could you post your autosell options? both in settings and profile.Sumdumguy wrote:Yes I did. I turned off Server-side safe, deleted macro bsd. Bot works fine, runs around, kills stuff, i get my equipment repaired, but I can't sell stuff.jduartedj wrote:Have you updated to latest SVN version? r548?
Maybe I'm missing some settings? but since I don't get the inventory scan, I don't think the problem are my profile.xml or the settings.lua.
Code: Select all
inventory:itemTotalCount(0,"bags")
thank you. i´ll try that one.Petzzz wrote:try inventory:itemTotalCount(0,"bags")
Code: Select all
local first, last;
if range == nil then
first , last = 61, 240 -- default, search only bags
else
first, last = getInventoryRange(range) -- get bag slot range
end
Same thing takes the same second argument.Rickster wrote:thank you. i´ll try that one.Petzzz wrote:try inventory:itemTotalCount(0,"bags")
next issue, when using
inventory:useItem(xxx);
it returns the same error:
"/micromacro/scripts/rom/classes/inventory.lua:799: bad argument #1 to
'lower' (string expected, got nil)"
Code: Select all
function getInventoryRange(range)
local rangeLower = string.lower(range)
if rangeLower == "all" then
return 1, 240
elseif rangeLower == "itemshop" then
return 1, 50
elseif rangeLower == "magicbox" then
return 51, 60
elseif rangeLower == "bag1" then
return 61, 90
elseif rangeLower == "bag2" then
return 91, 120
elseif rangeLower == "bag3" then
return 121, 150
elseif rangeLower == "bag4" then
return 151, 180
elseif rangeLower == "bag5" then
return 181, 210
elseif rangeLower == "bag6" then
return 211, 240
end
end
But All I did was update the code my self so that the supposedly "bags" is default by using the code I just posted before.SVN update r548 wrote:Changed: inventory:itemTotalCount can now specify a 2nd argument which bag ("all","itemshop","magicbox","bags","bag1","bag2", etc) defaults to "bags".
Settings.lua:jduartedj wrote: Could you post your autosell options? both in settings and profile.
Code: Select all
-- expert inventar
INV_MAX_SLOTS = 120, -- maximal slots to update in the inventory:update()
INV_UPDATE_INTERVAL = 300, -- full inventory update every x seconds (only used indirect atm)
INV_AUTOSELL_ENABLE = true, -- autosell items at merchant true|false
INV_AUTOSELL_FROMSLOT = 31, -- autosell from slot #
INV_AUTOSELL_TOSLOT = 120, -- autosell to slot #
INV_AUTOSELL_QUALITY = "white, green, blue", -- itemcolors to sell
INV_AUTOSELL_IGNORE = nil, -- itemnames never so sell
INV_AUTOSELL_NOSELL_DURA = 0, -- durability > x will not sell, 0=sell all
INV_AUTOSELL_STATS_NOSELL = nil, -- stats (text search at right tooltip side) that will not be selled
INV_AUTOSELL_STATS_SELL = nil, -- stats (text search at right tooltip side) that will be selled, even if in nosell
Code: Select all
<!-- Shopping options, how many of what do you want to keep in your inventory -->
<option name="HEALING_POTION" value="10" />
<option name="MANA_POTION" value="0" />
<option name="ARROW_QUIVER" value="0" />
<option name="THROWN_BAG" value="0" />
<option name="POISON" value="0" />
[/quote][/quote]Not getting the inv. scan only means that it has been cached and no longer needs to be loaded, only updated.
Try turning autosell debug on and report what happens when you try to sell.
Rickster wrote:thanks jduartedj!
but, while
inventory:itemTotalCount(0,"bags")
works fine
inventory:useItem(mount,"bags");
doesn´t.
(-- mount set to "Infernalisches Albtraum-Reittier (30 Tage)" in another place)
does it work on your side?
Code: Select all
local item = self:findItem(itemNameOrId)
Code: Select all
local item = self:findItem(itemNameOrId,"all")
Code: Select all
function CInventory:useItem(itemNameOrId)
First of all I recommend that you don't alter ANYTHING in settings.lua, since these are profile options you can set them in your profile using:Sumdumguy wrote: how do I do that?
Code: Select all
<option name="INV_AUTOSELL_ENABLE" value="true" />
Code: Select all
<option name="DEBUG_AUTOSELL" value="true" />
Code: Select all
The macro is currently not running. Press the start key (ENTF) to begin.
You may use (ENDE) key to stop/pause the script.
Resumed.
OPENING LOCAL SKILLS DB!
RoM windows size is 1680x1028, upper left corner at 0,22
MACRO Test: ok
Ranged skill found: SCOUT_SHOT
[DEBUG] CPU Frequency 2642.402
Loaded waypoint path test.xml
No return path with default naming test_return.xml found.
We use the normal waypoint path test.xml now.
Clearing target.
Equipment update took: 2
Moving to waypoint #1, (1398, 23289)
Use 6: KNIGHT_ENHANCED_ARMO=> <UNKNOWN> (1000/1000)
Use 5: KNIGHT_HOLY_SEAL => <UNKNOWN> (1000/1000)
Equipment update took: 2
Moving to waypoint #2, (1439, 23281)
We try to find NPC Bartai: Shopping..........
Clearing target.
Equipment update took: 3
Moving to waypoint #3, (1460, 23256)
Equipment update took: 2
Moving to waypoint #4, (1619, 23082)
Stopping execution.
Please enter the script name to run.
Type in 'exit' (without quotes) to exit.
Script>
Code: Select all
Equipment update took: 2