Looting problem

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
kanta
Posts: 424
Joined: Thu Nov 11, 2010 4:08 pm

Looting problem

#1 Post by kanta »

Sometimes the bot doesn't loot some bodies. This isn't a major issue, but it bothers me a little bit. It seems to happen mainly when I use a skill that hits multiple enemies and kills them all with one shot. Typically the non targeted mobs that are killed do not get looted. Here's my loot options:

Code: Select all

		<!-- Loot settings -->
		<option name="LOOT"               value="true" />
		<option name="LOOT_ALL"           value="true" />  <!-- Loot all nearby dead mobs after combat -->
		<option name="LOOT_IN_COMBAT"     value="false" />
		<option name="LOOT_DISTANCE"      value="225" />
		<option name="LOOT_PAUSE_AFTER"   value="0" />		<!-- probability in % for a short rest -->
		<option name="LOOT_AGAIN"			value="1000" />
Scout/Knight/Rogue 70/66/66
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#2 Post by lisa »

I have noticed this also a couple of times myself.

What I noticed is that if your target dies but you still have agro and the other mob/mobs die from the last aoe then it has a point where it thinks the target is dead but you are still in combat but then you are out of combat before it can get a new target. So it skips the looting part of the code altogether.

I haven't had a chance to loot into improving it as yet, working on a lot of other stuff atm
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Looting problem

#3 Post by rock5 »

lisa wrote:I haven't had a chance to loot into improving it as yet
This made me laugh because the spelling mistake is related to the subject. :D
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#4 Post by lisa »

lol yeah I do that a bit, pretty sure there is some heriditory mind thing where we all go senile sooner then we should.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
kanta
Posts: 424
Joined: Thu Nov 11, 2010 4:08 pm

Re: Looting problem

#5 Post by kanta »

No rush :) Was just wondering if it was happening because of a wrong setting.
Scout/Knight/Rogue 70/66/66
Mushroomstamp
Posts: 210
Joined: Wed Oct 27, 2010 11:34 am

Re: Looting problem

#6 Post by Mushroomstamp »

Good to hear others having the same problem. It seems also that the un-looted bodies are often later recognized, (i.e. when character is in another room of an instance), because I get a lot of errors for unlooted monster being > max target distance, even when there aren't any un-looted monsters in sight.
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#7 Post by lisa »

hmm I couldn't say off the top of my head how the loot code works but it seems to me it only tries to loot after it thinks it has killed something. It then looks around for other bodies aswell. So maybe do the loot check on leave combat instead of after it thinks the mob is dead.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Mushroomstamp
Posts: 210
Joined: Wed Oct 27, 2010 11:34 am

Re: Looting problem

#8 Post by Mushroomstamp »

lisa wrote:maybe do the loot check on leave combat
That was the first thing I tried... now that I think of it, I wonder if that is what's causing all my self.TargetPtr == 0 errors.
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Looting problem

#9 Post by rock5 »

The looting works in 2 parts.

The first part is the original looting and basically hasn't changed. It loots the monster you just killed and relys on it still being the target. The LOOT_IN_COMBAT option affects this looting.

The second part is the loot all looting. It looks for lootable bodies nearby after combat has ended. You enable/disable it with the LOOT_ALL option.

Both checks are done after the onLeaveCombat code so it is possible that something you added to the onLeaveCombat section could interfer with the looting. In particular, if something changes the target then the first looting wont work. I'm not sure what would interfer with the loot all function.

If you are having strange loot behaviour, try removing the code you've added in the onLeaveCombat section.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#10 Post by lisa »

I don't have any onleavecombat code.

What I see is happening is the target is killed and with an aoe most of the time, it is still in combat hence the not looting straight away. It then clears target hoping to get the target of what is attacking it but the aoe killed it. The in combat goes away and it has no target and therefore doesn't loot.

I was working along the lines of instead of clearing target after it's dead just use findenemy and see how that affects it. if there is no enemy to find then loot.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Looting problem

#11 Post by rock5 »

If it enters the "fight" then the only way it can exit without looting is if it is still in combat. So what it must do is check that you are still battling then exit the fighting function without looting. Then when it gets back to the bot.lua main loop, it finds that it has lost aggro so it continues.

The only way I can see to fix it is to add an extra loot check somewhere in bot.lua which is not the best solution. I'll have another look at the loot functions to see if I can tweak them a bit.

Just 1 question: you aren't in a party when you get the loot problems are you?
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#12 Post by lisa »

technically yes I have been in party, instance running, wouldn't be an agro issue though as other party member is elsewhere.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Looting problem

#13 Post by rock5 »

It's possible that when you use the aoe the mobs all die but the battling flag takes too long to clear. If so then the following should help.

Around line 1277 of player.lua you will see,

Code: Select all

	if not self.Battling then
		self:lootAll()
	end
Change to

Code: Select all

	if not self.Battling or not self:findEnemy(true,nil,evalTargetDefault) then
		self:lootAll()
	end
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#14 Post by lisa »

The loot has become more reliable while using aoe with this code, it does however cause a pause after leaving combat for 0.5 -1 second which is probably because it is looking for mobs to kill.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: Looting problem

#15 Post by rock5 »

lisa wrote:it does however cause a pause after leaving combat for 0.5 -1 second which is probably because it is looking for mobs to kill.
I'd say it can't be helped. At least it should only add that pause after aoe when having this problem. Regular battles should end with self.Battling equaling false so it wont do the search.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Looting problem

#16 Post by lisa »

yup absolutely correct, if normal single target botting loot works as usual, it's only when aoe botting is there a pause =)
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Post Reply