Party Bot (questions/answers)

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Party Bot (questions/answers)

#121 Post by lisa » Mon Feb 11, 2013 8:53 am

rock5 wrote:Lisa you didn't mention there were other changes in this file that needed to be committed
nothing unusual there, I just forgot I had even done it.
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: Party Bot (questions/answers)

#122 Post by abron1 » Mon Feb 11, 2013 3:19 pm

hey lisa i read that there is a way to tell different party members to do different things

i am not sure how to do this because i want the melee character to fight with me but i want to tell the healer not to follow

i use all the functions and it works perfect but if i can tell party member 3 to no follow no loot then me and my other geared melee character fight the trash and them i can call the healer.. and can you give me a example on how to make them a skill from the leader bot

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

Re: Party Bot (questions/answers)

#123 Post by lisa » Mon Feb 11, 2013 8:07 pm

I did post this somewhere when someone asked about using whispers.

Code: Select all

code"if player.Class1 == CLASS_PRIEST then 
--do stuff
 end"
if you really want then you can also use character names

Code: Select all

code"if player.Name == "Scoobydoo" then
 --do stuff 
end"

You could also add functions to the profile for the healer so that what you use in game is easier.

example
profile onload

Code: Select all

function stop() 
changeProfileOption("LOOT", false) 
end
then in party chat do

Code: Select all

code"if stop then stop() end"
I just realised I used a local value in party.lua to stop the following, I think I should make it into a function so it can be called from other places. I should probably do more functions in party.lua so people don't need to write up the code in party chat for things that will be done regularly.
I'll have a think on it.
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: Party Bot (questions/answers)

#124 Post by rock5 » Tue Feb 12, 2013 12:48 pm

Party.lua is now fully updated in rev 751 will changes from here.
  • 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

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

Re: Party Bot (questions/answers)

#125 Post by abron1 » Thu Feb 14, 2013 4:17 am

hey lisa is there a way for the leader to say a use skill comand and the party member does it like if it was in a waypoint?

example: leader says in party chat

Code: Select all

player:cast("PRIEST_GROUP_HEAL")
then the priest wil cast group heal if its in his profile. reason i am asking is because i party with a warden and pet and run instances solo, and the only way my pet can get fully healed is if i resummon go to the other screen and use the group heal manually. and there are times when i don't have the time to resummon or switch screens. if its possible

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

Re: Party Bot (questions/answers)

#126 Post by lisa » Thu Feb 14, 2013 4:22 am

Code: Select all

code"player:cast("PRIEST_GROUP_HEAL")"
the code"" will make the party member's micromacro do any sort of code MM could normally do, any userfunctions, set any variables, anything at all you can do in a function or waypoint.
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: Party Bot (questions/answers)

#127 Post by abron1 » Thu Feb 14, 2013 5:06 am

wow ok thanks.. as i get a better understanding how this works its now easy for me to solo instances with a team of my characters now

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

Re: Party Bot (questions/answers)

#128 Post by lisa » Thu Feb 14, 2013 5:15 am

abron1 wrote:wow ok thanks.. as i get a better understanding how this works its now easy for me to solo instances with a team of my characters now
that was the plan ;)
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: Party Bot (questions/answers)

#129 Post by abron1 » Fri Feb 15, 2013 12:06 am

well lisa we have another issue lol.

when i use the comand for the priest to group heal the melee character that doesn't have that skill errors and the bot stops

Code: Select all

code"player:cast("PRIEST_GROUP_HEAL")"

Code: Select all

Unknown profile skill PRIEST_GROUP_HEAL. Check your manual castings (e.g. in the
 events or waypoint files). Be sure the skill is in the skills section of your p
rofile.
Did not find any crashed game clients.
8:55pm - ...er/Desktop/micromacro/scripts/rom/classes/player.lua:936: attempt to
 compare number with nil
and i tried to use a key press

Code: Select all

code"keyboardPress("key.VK_0")"
instead but the priest errored (melee characters was already stopped)

Code: Select all

Unknown profile skill PRIEST_GROUP_HEAL. Check your manual castings (e.g. in the
 events or waypoint files). Be sure the skill is in the skills section of your p
rofile.
Did not find any crashed game clients.
8:55pm - ...er/Desktop/micromacro/scripts/rom/classes/player.lua:936: attempt to
 compare number with nil
so my idea have the bot ignor commands for skills it don't have so it don't error

oh and the party members are not using pets for some reason

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

Re: Party Bot (questions/answers)

#130 Post by lisa » Fri Feb 15, 2013 4:15 am

This is like 4 or 5 posts ago.
lisa wrote:

Code: Select all

code"if player.Class1 == CLASS_PRIEST then 
--do stuff
 end"
abron1 wrote:oh and the party members are not using pets for some reason
You are right I forgot to add in pet usage, shouldn't be hard to add, might add in some other stuff too, maybe some userfunctions to make it all easier aswell.
Not sure when I will have time for it, I'll see how I go.
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
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Party Bot (questions/answers)

#131 Post by lisa » Fri Feb 15, 2013 7:16 pm

--== removed as newer file posted later ===--
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: Party Bot (questions/answers)

#132 Post by abron1 » Sat Feb 16, 2013 1:19 am

maybe do it like you did the old pet heal for warden where you had the warden target the pet and heal with recover if it was a wd/d. i forget where you put that pieces of code.

Code: Select all

 <onLeaveCombat>
      runicthorn2()
           player:update()
      if 25 > (player.Pet.HP/player.Pet.MaxHP * 100) then
         player:target( player.Pet )
         player:cast("WARDEN_SUMMON_CHIRON_THE_CENTAUR")
         yrest(1000)
      end
      if not player:hasBuff("Protection of Nature") then
         player:cast("WARDEN_SUMMON_NATURE_CRYSTAL");
         player:cast("WARDEN_PROTECTION_OF_NATURE");
         player:cast("WARDEN_SUMMON_CHIRON_THE_CENTAUR");
      end
         if player:findNearestNameOrId(102102) then
            local Evelyn = player:findNearestNameOrId(102102)
            player:target(Evelyn)
            player:fight()
            end
   </onLeaveCombat>
old code you had from warden post not sure if it will help

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

Re: Party Bot (questions/answers)

#133 Post by lisa » Sat Feb 16, 2013 1:31 am

seems adding the warden pet to partymemberpawn is causing issues, for some reason it seems to think it is buffing pet when it is buffing itself, still won't heal the pet.

Might have to do some more specific code for warden pet's, I might get time to work on it at some stage this weekend.
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
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Party Bot (questions/answers)

#134 Post by lisa » Sat Feb 16, 2013 1:49 am

ok this seems to be working well, I set it to 80% and it only uses urgent heal or recover to heal pet.

Code: Select all

Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5607/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5685/7061)
Use MACRO: PRIEST_WAVE_ARMOR   =>   Spirit of the Oak (5549/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5628/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5698/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5611/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5611/7061)
Use MACRO: PRIEST_URGENT_HEAL  =>   Spirit of the Oak (5689/7061)
It just does the 1 heal each main loop, so it's priority is always going to be players.

Give it a test and see how it goes.

--=== Added ===--

Had a look at druid skills a bit closer, I am thinking restore life is probably a good skills to use, as level of only 6 and does a good once off heal with no heal over time, so I am thinking something like this.

Code: Select all

					for k,v in pairs(petmemberpawn) do
						-- no repeat loop so just 1 heal and will heal again next time round, keeps players as priority.
						if v.HP/v.MaxHP*100 > 10 and 80 > v.HP/v.MaxHP*100 then -- Alive and under 80% hp
							player:target(v)
							if 30 > v.HP/v.MaxHP*100 then -- extra heal if HP is really low
								if player.Class1 == CLASS_PRIEST then
									player:cast("PRIEST_URGENT_HEAL")
								elseif player.Class1 == CLASS_DRUID then
									player:cast("DRUID_RESTORE_LIFE")
								end
							end
							if player.Class1 == CLASS_PRIEST then
								player:cast("PRIEST_URGENT_HEAL")
							elseif player.Class1 == CLASS_DRUID then
								player:cast("DRUID_RECOVER")
							end
						end
					end
After more testing it always does a double heal anyway, seems it casts skill and then continues on in loop and so it comes back to decide to heal again before the last skill has been cast.

Could add in a yrest I guess but I think I will just leave it as a double heal and change it to like 60% hp and no additional code for lower hp
Attachments
party.lua
(17.14 KiB) Downloaded 305 times
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: Party Bot (questions/answers)

#135 Post by abron1 » Sat Feb 16, 2013 6:53 am

it did target pet and healed it but the it aslo crashed the game

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

Re: Party Bot (questions/answers)

#136 Post by lisa » Sat Feb 16, 2013 7:13 am

abron1 wrote:it did target pet and healed it but the it aslo crashed the game
crashed how?

Mine works fine.
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: Party Bot (questions/answers)

#137 Post by abron1 » Sat Feb 16, 2013 10:34 am

for some reason i can't copy from mm window but ill run it again and try to copy the error message

Code: Select all

Use MACRO: PRIEST_URGENT_HEAL  =>   Chiron the Centaur (20360/55448)
Engaging enemy [Sugon Armored Beast] in combat.
Use MACRO: PRIEST_URGENT_HEAL  =>   Chiron the Centaur (39536/55448)
Use MACRO: PRIEST_HEALING_SALVE=>   My Warden (68850/68850)
Use MACRO: PRIEST_WAVE_ARMOR   =>   My Warden (68850/68850)
Engaging enemy [Sugon Armored Beast] in combat.
Use MACRO: MAGE_LIGHTNING      =>   Sugon Armored Beast (161266/202275)
Use MACRO: MAGE_FIREBALL       =>   Sugon Armored Beast (143136/202275)
Use MACRO: PRIEST_BONE_CHILL   =>   Sugon Armored Beast (114133/202275)
Use MACRO: PRIEST_ICEWIND_BLADE=>   Sugon Armored Beast (78175/202275)
7:47am - ...rs/User/Desktop/micromacro/scripts/rom/functions.lua:321: bad argume
nt #1 to 'memoryWriteBytePtr' ((null))
it works perfectly but after three fights it crashes everytime
Last edited by abron1 on Sat Feb 16, 2013 4:02 pm, edited 4 times in total.

User avatar
ellisdee
Posts: 24
Joined: Mon Sep 26, 2011 3:03 pm

Re: Party Bot (questions/answers)

#138 Post by ellisdee » Sat Feb 16, 2013 2:58 pm

to copy from MM window, Right click your mouse on the top-most area (title bar), Hover over "Edit".
then you should see what to do from there. If for some reason you cant copy and paste text from that to Notepad++ or a normal Text file, its feasible you have another issue with your computer in general
functions.lua:321: bad argument #1 to 'memoryWriteBytePtr' ((null)
I think this is just a return from Rombot when the client crashes. Not exactly the root of why it crashes

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

Re: Party Bot (questions/answers)

#139 Post by lisa » Sat Feb 16, 2013 7:36 pm

ellisdee wrote:I think this is just a return from Rombot when the client crashes. Not exactly the root of why it crashes
correct, the game iteself must have crashed and that is why that error.

--=== removed ===--
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: Party Bot (questions/answers)

#140 Post by abron1 » Sat Feb 16, 2013 8:41 pm

got this error

Code: Select all

Enter the number of the path you want to use and press Enter > 49
You chose 49
Loaded waypoint path partyhealer.xml
No return path with default naming partyhealer_return.xml found.
We use the normal waypoint path partyhealer.xml now.
GM detection started
Party Monitor started.
Party member 1 has the name of my warden
Use MACRO: PRIEST_HEALING_SALVE=>   Chiron the Centaur (29725/50700)
Did not find any crashed game clients.
5:39pm - ...ser/Desktop/micromacro/scripts/rom/classes/party.lua:98: attempt to
call local 'heal' (a boolean value)


Please enter the script name to run.
Type in 'exit' (without quotes) to exit.
Script>
didn't evern get to the first fight

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest