Page 1 of 1

Priest Follower for RoMBot

Posted: Thu Jun 04, 2009 9:48 am
by Bobert
I'm working on a follow buff/heal bot to be used with RoM Bot.
What I was planning, is taking the existing code and editing it to work for a priest.

What I was thinking is that I could use UberFlex in combination with F2 and \.
While partied, sending F2 and \ Follows you're party member.
Any ideas on how to check if the main is in combat/walking away?
After that I need to resume following.

Code: Select all

			if( v.CastTime > 0 ) then
				local startTime = os.time();
				while( not self.Casting ) do
					yrest(50);		
		keyboardHold(VK_F2);
		keyboardRelease(VK_F2);
		keyboardHold(VK_\);
		keyboardRelease(VK_\);
					self:update();
					if( os.difftime(os.time(), startTime) > v.CastTime ) then
						self.Casting = true; -- force it.
						break;
					end
				end;

				while(self.Casting) do
					-- Waiting for casting to finish...
					yrest(10);
					self:update();
				end
Something like that?

Basically, when NOT casting, it's following.

I think this would be really simple with RoM Bot.

Re: Priest Follower for RoMBot

Posted: Thu Jun 04, 2009 11:05 am
by 3cmSailorfuku
Actually you could solve this pretty easy but im going to throw in that someone should use the Network functions to communicate between two clients :)

http://www.solarstrike.net/wiki/index.p ... _Functions

Re: Priest Follower for RoMBot

Posted: Thu Jun 04, 2009 12:37 pm
by Administrator
Network functions could be used, but you can also rely on your client side flags. Whenever a party member is in combat (and you are nearby), you should also enter combat. The problem here is you won't be able to tell the difference between the healer being attacked verses your main character.

For not moving while casting, just steal the code from the bot I made. You'll find it near the top of classes/player.lua. The general idea is to yrest (wait) for the duration of the skill, and then check to see if you are still casting or not. If you don't exit the casting state soon enough, it automatically breaks out early.

Also, VK_\ is not valid. Use VK_BACKSLASH.

Re: Priest Follower for RoMBot

Posted: Mon Jun 08, 2009 3:21 pm
by wallofchaos
Logitech G-15 Keyboard for the win :)

yes alot more expensive than a few burnt up brain cells.

Great idea. i've also wanted to do this, but I just ended up using
AutoM8. which is unreliable.

good luck.