crashed game clients

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
WhiteTiger
Posts: 84
Joined: Tue Jun 22, 2010 8:06 am

crashed game clients

#1 Post by WhiteTiger » Fri Nov 11, 2011 8:31 pm

Noticed that the bot says "Did not find any crashed game clients".
Just curious, what happens if it finds one?

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

Re: crashed game clients

#2 Post by rock5 » Fri Nov 11, 2011 10:12 pm

It's a recent update from Administrator. It's supposed to force close the game if your script ends because of the game crashing. This is neccessary because often when the game crashes and doesn't close properly, the server thinks you are still logged on and if your character is in a dangerous area it will die. Forcing the game to close completely, completely logs you off.
  • 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

WhiteTiger
Posts: 84
Joined: Tue Jun 22, 2010 8:06 am

Re: crashed game clients

#3 Post by WhiteTiger » Fri Nov 11, 2011 10:15 pm

Oh. Is it any way to turn it off?

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

Re: crashed game clients

#4 Post by rock5 » Fri Nov 11, 2011 10:17 pm

Why do you want to turn it off?
  • 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

WhiteTiger
Posts: 84
Joined: Tue Jun 22, 2010 8:06 am

Re: crashed game clients

#5 Post by WhiteTiger » Fri Nov 11, 2011 10:18 pm

Got a program that restarts my bot and rom if it crashes. it would kinda interfere with that.

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

Re: crashed game clients

#6 Post by rock5 » Fri Nov 11, 2011 11:48 pm

Here is the total of what was changed in that update. It was a function added to "functions.lua"

Code: Select all

function errorCallback(script, line, message)
	local crashwin = findWindow("Crash Report", "#32770");

	if( crashwin ~= 0 and crashwin ~= nil ) then
		-- Looks like the paired game client crashed. Kill it off and exit.
		local pid = findProcessByWindow(crashwin);
		os.execute("TASKKILL /PID " .. pid .. " /F");

		warning(script .. ":" .. line .. ": " .. message);

		printf("Found a crashed game client and killed it. (PID %d)\n", pid);
		printf("This instance of MicroMacro will automatically terminate in 30 seconds.\n");
		printf("Press ENTER to end the script and prevent termination.\n");

		local starttime = os.time();
		while( os.time() - starttime < 30 ) do
			yrest(10);

			if( keyPressed(key.VK_ENTER) or keyPressed(key.VK_ESCAPE) ) then
				return;
			end
		end

		-- Terminate this copy of MicroMacro.
		os.exit();
	else
		printf("Did not find any crashed game clients.\n");
	end
end
atError(errorCallback);
You could just delete that. Actually you could just delete the last line so the function doesn't get used.

If you don't want to edit the bot, you could probably change the "atError" action by declaring your own atError function within your own scipts.

I'm not sure if this will work but you could try adding the following into your onload section.

Code: Select all

atError(function() 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

ichmagbotsyay
Posts: 70
Joined: Tue Aug 09, 2011 7:43 am

Re: crashed game clients

#7 Post by ichmagbotsyay » Sat Nov 12, 2011 3:01 am

WhiteTiger wrote:Got a program that restarts my bot and rom if it crashes. it would kinda interfere with that.
is there any way you could upload this program and post it here or in a pm? because i've been looking all over for something like that :D

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 2 guests