Stop botting if other players are in range

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Stop botting if other players are in range

#1 Post by Ego95 » Tue Oct 16, 2012 5:51 pm

Hey rock,

I'm using your "wait until it's less crowded" code you posted in the CountMobs userfunction topic. I tried to change something but it seems not to work:

Code: Select all

	function playerDetect()
		if Count_Players == true then
			if CountPlayers(nil, true) > 0 then
				player:cast("ROGUE_HIDE");
				print("1 or more players found. Don't bot. Wait")
				repeat
					yrest(20000)
				until 1 > CountPlayers(nil, true)
			elseif player:findNearestNameOrId("mobID") then
				sendMacro('TargetNearestEnemy("mobID")')
				player:fight()
			end
		end
	end
What it should do is stop killing mobs, but only if it can find one specific mob it should kill it.
What am I doing wrong?

Already thanks for your answer :)

Edit: I totally forgot to set it to true in the onload :D But it gives an error now.

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

Re: Stop botting if other players are in range

#2 Post by rock5 » Tue Oct 16, 2012 10:41 pm

Think about the error. Fix it in your mind. *Rock5 tries to read AlterEgo95s mind*

Concentrate, damn it!

. . . . .

Nope, I'm not getting anything. Either my mind reading skills, which are considerable, are on the fritz today or your not concentrating hard enough.

So I'm afraid you'll have to describe your error in a post and I'll have to read it instead. :(
  • 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: Stop botting if other players are in range

#3 Post by lisa » Wed Oct 17, 2012 12:34 am

rock5 wrote:Think about the error. Fix it in your mind. *Rock5 tries to read AlterEgo95s mind*

Concentrate, damn it!

. . . . .

Nope, I'm not getting anything. Either my mind reading skills, which are considerable, are on the fritz today or your not concentrating hard enough.

So I'm afraid you'll have to describe your error in a post and I'll have to read it instead. :(
and I thought your mind reading skills were of legend, I am sure I read about it on a wiki somewhere lol
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: Stop botting if other players are in range

#4 Post by rock5 » Wed Oct 17, 2012 12:41 am

Lisa is going to say
"and I thought your mind reading skills were of legend, I am sure I read about it on a wiki somewhere lol".

Oh you bet me to it. :)
  • 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: Stop botting if other players are in range

#5 Post by lisa » Wed Oct 17, 2012 1:05 am

yes because my typing skills are of legend ;)
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
botje
Posts: 656
Joined: Wed Oct 27, 2010 7:17 am

Re: Stop botting if other players are in range

#6 Post by botje » Wed Oct 17, 2012 5:11 am

lol guys, that made me laugh in real life xd

now my wife looks at me as if im weird, thanx :lol:

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: Stop botting if other players are in range

#7 Post by Ego95 » Thu Oct 18, 2012 4:14 pm

Think about the error. Fix it in your mind. *Rock5 tries to read AlterEgo95s mind*
And I thought you have mind reading skills! :(

LOL, sorry rock
Yes, would be helpful to post what kind of error it is :D

But I think I found the error today. There was only an "end" too much under the "player:fight()".
I'll see if it works when the mob spawns and an other person is next to me.

Anyway thanks for you funny dialog rock and lisa :D

BillDoorNZ
Posts: 446
Joined: Wed Aug 03, 2011 7:37 pm

Re: Stop botting if other players are in range

#8 Post by BillDoorNZ » Thu Oct 18, 2012 6:54 pm

Code: Select all

function playerDetect()
	if Count_Players == true then
		while (CountPlayers(nil, true) > 0) do
            player:cast("ROGUE_HIDE");
            print("1 or more players found. Don't bot. Wait")
			yrest(20000);
		end;
	end
	
	local enemy = player:findNearestNameOrId("mobID");
	if (enemy) then
		player:target(enemy);
		player:fight()
	end
end

BillDoorNZ
Posts: 446
Joined: Wed Aug 03, 2011 7:37 pm

Re: Stop botting if other players are in range

#9 Post by BillDoorNZ » Thu Oct 18, 2012 6:55 pm

or

Code: Select all

function playerDetect()
	while ((Count_Players) and (CountPlayers(nil, true) > 0)) do
		player:cast("ROGUE_HIDE");
		print("1 or more players found. Don't bot. Wait")
		yrest(20000);
	end;
	
	local enemy = player:findNearestNameOrId("mobID");
	if (enemy) then
		player:target(enemy);
		player:fight()
	end
end

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

Re: Stop botting if other players are in range

#10 Post by NyTr0g3n3 » Thu Apr 04, 2013 12:53 pm

Hi everybody,

I was wondering if there was a way to add a "player exception" to this count player function.
I level up a secondary char with my main char and I want to stop botting if other players come too close but if I use this function I will stop botting because of my secondary char. It's why I want to add a "player exception".

Thanks ^^

Best Regards,

NyTr0g3n3

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

Re: Stop botting if other players are in range

#11 Post by rock5 » Thu Apr 04, 2013 2:39 pm

Yes, the CountPlayers function has an option to ignore 'friends'. Check this page for the userfunction file and usage.
http://www.solarstrike.net/phpBB3/viewt ... 781#p36781
  • 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

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

Re: Stop botting if other players are in range

#12 Post by NyTr0g3n3 » Fri Apr 05, 2013 2:32 am

Hi rock5,

Thanks for your answer but it doesn't work for me. I think i'm doing something wrong.

Here is the code:

Code: Select all

	function playerdetect()
		if CountPlayers(600, true, true) > 0 then
			player:cast("ROGUE_HIDE");
   	   		print("Waiting till it's less crowded")
   	   			repeat
      			yrest(15000)
  	   		until 1 > CountPlayers(600, true, true) 
		end
	end
The bot still stops if my alt is in range however my alt is set as friend in my profile.

Do you see what's the problem ?

Thanks.

NyTr0g3n3

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

Re: Stop botting if other players are in range

#13 Post by rock5 » Fri Apr 05, 2013 5:17 am

Are you using the latest version of CountMobs?
  • 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

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

Re: Stop botting if other players are in range

#14 Post by NyTr0g3n3 » Fri Apr 05, 2013 1:43 pm

I use the last you put on the link you gave me.

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

Re: Stop botting if other players are in range

#15 Post by rock5 » Fri Apr 05, 2013 2:09 pm

What does it print? Does it print the alts name?
  • 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

vo2male
Posts: 122
Joined: Mon Aug 27, 2012 6:41 am

Re: Stop botting if other players are in range

#16 Post by vo2male » Fri Apr 05, 2013 3:42 pm

use Lisa's changeprofile userfunction --> http://www.solarstrike.net/phpBB3/viewt ... =27&t=3626
and add your list of exceptions to your onload like this.. make sure you only use this function when adding friends or mobs..

Code: Select all

changeOptionFriendMob("friend", "Alt-Name", "Add")
if you have a code similar to this in your waypoint

Code: Select all

settings.profile.friends = {"mobname"}
remove it or else it will make conflict to the above userfunction

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

Re: Stop botting if other players are in range

#17 Post by NyTr0g3n3 » Sat Apr 06, 2013 12:53 pm

Thanks rock, I'm not home today so I'll try as soon as possible and let you know if it works.

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

Re: Stop botting if other players are in range

#18 Post by NyTr0g3n3 » Mon Apr 08, 2013 12:50 pm

Alright, it seems to work ! Thanks a lot !

Post Reply

Who is online

Users browsing this forum: No registered users and 37 guests