my game crashes when i collect Mysterious Bags after a while

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
abron1
Posts: 162
Joined: Wed Feb 22, 2012 12:43 am

my game crashes when i collect Mysterious Bags after a while

#1 Post by abron1 » Tue Mar 26, 2013 9:16 pm

Code: Select all

if player:findNearestNameOrId("Mysterious Bag") then
        player:target_Object("Mysterious Bag")
        yrest(2000) -- If not enough time to pick up bag, increase it.
	end
this is where the code is being used

Code: Select all

<onLeaveCombat><![CDATA[
		-- Additional Lua code to execute after killing an enemy
   	if player:findNearestNameOrId("Mysterious Bag") then
        player:target_Object("Mysterious Bag")
        yrest(2000) -- If not enough time to pick up bag, increase it.
	end
	useGoodie("speed");
   	useGoodie("luck");
   	useGoodie("patt3");
	useGoodie("defense");
	useGoodie("agro"); 
	useGoodie("casting");
	catchCavy()
   	
    	]]></onLeaveCombat>
not sure why it crashes after a few hours or running but if i bot without the code it runs all night

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: my game crashes when i collect Mysterious Bags after a w

#2 Post by rock5 » Tue Mar 26, 2013 10:33 pm

Maybe after the bot 'sees' the bag and starts walking towards it, someone comes along and takes the bag before you so that when you get to the bag it's already gone. Is that possible? If so, you could go to the bag and then check if it exists again before taking it.

Code: Select all

local bag = player:findNearestNameOrId("Mysterious Bag")
if bag then
   player:moveTo(bag,true)
   bag:update() -- If bag no longer exists, Id will become 0.
   if bag.Id ~= 0 then 
      player:target_Object("Mysterious Bag")
      yrest(2000) -- If not enough time to pick up bag, increase it.
   end
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: my game crashes when i collect Mysterious Bags after a w

#3 Post by lisa » Tue Mar 26, 2013 10:38 pm

If you are in a party any char can "loot" the bag but only one can actually get loot from the bag, after a short time the loot becomes available to anyone but it dissappears very shortly after that.
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

abron1
Posts: 162
Joined: Wed Feb 22, 2012 12:43 am

Re: my game crashes when i collect Mysterious Bags after a w

#4 Post by abron1 » Wed Mar 27, 2013 12:36 am

nah no one takes the bag before me but maybe i need to have to much in the on leave or not enough yeast times inbetween commands

Code: Select all

We found Mysterious Bag and will harvest it.
We didn't move to the loot!? Root buff? Missing 'click to move' option?
10:52pm - ...rs/User/Desktop/micromacro/scripts/rom/functions.lua:321: bad argum
ent #1 to 'memoryWriteBytePtr' ((null))
i guess i should have posted the error lol

NyTr0g3n3
Posts: 34
Joined: Sun Oct 21, 2012 11:32 am

Re: my game crashes when i collect Mysterious Bags after a w

#5 Post by NyTr0g3n3 » Wed Mar 27, 2013 1:44 pm

Hi everybody,

You're not the only one. I have exactly the same problem when my char try to take the Bag and I have no idea of what it could be.

abron1
Posts: 162
Joined: Wed Feb 22, 2012 12:43 am

Re: my game crashes when i collect Mysterious Bags after a w

#6 Post by abron1 » Wed Mar 27, 2013 4:07 pm

its only the bags in Merdhin Tundra for me not sure if the bags are different or what.

Buster99
Posts: 69
Joined: Fri Nov 25, 2011 9:27 am

Re: my game crashes when i collect Mysterious Bags after a w

#7 Post by Buster99 » Wed Jun 19, 2013 11:59 am

My game is constantly crashing while trying to loot Mysterious bags. Never had problem before last patch. I also recently updated to MM 1.03 and latest RoM revision. It happens after about 30-60 minutes of farming in new zone. Error is always same:

We found Mysterious Bag and will harvest it.
We didn't move to the loot!? Root buff? Missing 'click to move' option?
...micromacro/script/rom/functions.lua:756: bad argument #1 to 'memoryReadByte' <<null>>

Any ideas?

User avatar
grande
Posts: 261
Joined: Tue Jun 28, 2011 4:46 pm

Re: my game crashes when i collect Mysterious Bags after a w

#8 Post by grande » Wed Jun 19, 2013 6:24 pm

I had a lot of code in my onLeaveCombat part of the profile. I eliminated much of the extra code and experienced less crashing but so far it still seems to happen and still seems to be related to something in the onLeaveCombat. I made some recent additional slimdown to my onLeaveCombat section but haven't had time to see if it helped any.

To me, it seems like it's related to the memory issues RoM has. My observation is that extra code in onLeaveCombat eventually contributes to RoM's poor memory processing and a crash. just my S.W.A.Guess though.

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: my game crashes when i collect Mysterious Bags after a w

#9 Post by lisa » Wed Jun 19, 2013 6:45 pm

Buster99 wrote:micromacro/script/rom/functions.lua:756: bad argument #1 to 'memoryReadByte' <<null>>
Same error you posted in the GM detect and saying it happens when someone is detected as following you?


I think maybe there is an underlying issue that you might need to narrow down the actual error.

Like grande said though it could simply be an issue with RoM's very well known issue with memory.

As I did say in response to your other post though that error is because MM can't find the game process anymore (basically the game crashed). MM isn't causing the game to crash but it is telling you that the game did crash.
So you need to work out why the game itself is crashing.
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
grande
Posts: 261
Joined: Tue Jun 28, 2011 4:46 pm

Re: my game crashes when i collect Mysterious Bags after a w

#10 Post by grande » Wed Jun 19, 2013 9:11 pm

It finally dawned on me that the only time I was really crashing consistently was indeed when running waypoints that pick up the "Mysterious Bag". I'm impatient so I'll just post what I changed below. It's been running for nearly an hour with no crash so if that keeps up I won't post again and assume this change worked. I changed the onleavecombat a little. instead of two target objects it now targets the object and then does player:loot() like so:

Code: Select all

if player:findNearestNameOrId("Mysterious Bag") and inventory:itemTotalCount(0) ~= 0 then
player:target_Object("Mysterious Bag")
yrest(800)	 
player:loot()
yrest(900)
end
You may need to change the yrest values to be optimal for your lag situation. Also, here's what my code actually looks like... I added a bit because I was having troubles getting it to go sell at various points which this seems to have resolved:

Code: Select all

if player:findNearestNameOrId("Mysterious Bag") and inventory:itemTotalCount(0) ~= 0 then
player:target_Object("Mysterious Bag")
yrest(800)	 
player:loot()
yrest(900)
elseif inventory:itemTotalCount(0) == 0 then
	__WPL:setWaypointIndex(__WPL:findWaypointTag("sell"));
end
I was just getting frustrated with it constantly trying to loot the friggin bag when the bags were full instead of going off to sell like it should.

User avatar
grande
Posts: 261
Joined: Tue Jun 28, 2011 4:46 pm

Re: my game crashes when i collect Mysterious Bags after a w

#11 Post by grande » Thu Jun 20, 2013 6:14 am

Works a lot better now, no crashes since changing in the "player:loot" part

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest